I wanted to know the overhead in creating a new table. What i mean is, is it better to have more tables or redundant columns in a single table.
overhead in creating a new table
Collapse
X
-
The create table statement itself has almost no overhead - there cannot be simply said if it is better to have one big table or three small - it depends on what you would like to do with the data ... if you will expect a lot of operations dedicated to columns, then it will be better to create more tables with less column count and then you can e.g. propagate it to users as "view" -
Hi,
a rule of thumb is: if there's lots of redundant data, there's something wrong with the design. Avoid redundant data whereever possible.
Maybe in smaller projects it makes sense to keep the data in less tables and to have the same data more than once, just to keep thing simple and to get it running in short time. But the bigger the project, the better you keep the data in different tables and work with foreign keys, indexes and views. This usually results in a higher complexity, that's true, but in an improved performance also.
Regards,
BerndComment
Comment