database design - Which approach is better - comment attribute in each table vs one comment table -
currently, have bunch of tables in system need store 1 comment per row (not content type or else - simple 1 comment per row , no history tracking). there advantage creating comment table , having fk other tables need comments opposed directly creating comment column in each of tables?
is there advantage on physical db side - in terms of database performance these 2 approaches?
it's impossible comment (cough) meaningfully on performance without testing. you're 1 in reasonable position that.
at logical level, comment data in row should stored row.
some dbms move wide columns internally secondary storage area. speeds access rows when don't select comment column (fewer physical reads), slows down access when select comment column (reads different part of internal data structures). might not notice difference unless you're selecting many thousands of rows out of millions of rows. (but, again, testing . . .)
Comments
Post a Comment