+ 4
which database design is better?
let say I have 3 different user type (eg: user, shop, admin) and all 3 required similar information. option 1 : make 3 different table for each user type or option 2 : use 1 table but add another column to differentiate each user type which one is better or both is okay depending the situation and if so under which circumstances should I use each option? any other suggestion is much appreciated?
2 Antworten
+ 4
If the columns for all 3 are completely different then I would suggest you to go for making 3 separate tables.
But if they all have only a single column that is different then probably you should go for a single table.
This would help you see the output clearly and all at one place by using simple queries.
Whereas for different tables you must use joins to combine the results of the table.
0
1