Suppose I have a table Articles. An article can have only one topic attached to it. But it is also possible that article has no topic.
-
Should I make
topica new column inArticlestable? OR -
Should I create a table
topics2articlesand map together atopicwitharticle?
(In this case I do not have to add extra column forArticlestable.
I don’t like the 1st solution because then some rows will have NULL in them? Or is this reasonable to have NULL in this case?
What do you think?
Thanks, Boda Cydo.
I don’t see any reason for you to make a new table just to avoid having rows with
NULLin them.It would make sense to add it to the article table, and probably make it easier to maintain since you wouldn’t have to join against another table.