
May 2nd, 2012, 10:54 PM
|
 |
For POny!
|
|
Join Date: Apr 2012
Location: Amsterdam
|
|
|
DB structure
Hi guys,
Say I would like to track hits on products or articles
Would you create an extra table to store these hits (with articleID as foreign key), or just put them in the article table itself?
Something tells me the last option makes most sense,
since an article can have only 1 sort of hits and in that way its a one to one relationship. Hmm typing this I am almost certain this is correct  anyone wanna agree or disagree?
Code:
article table
------------
articleID
hits
VS
article table hits table
------------ + ----------
articleID articleID
hits
|