-1

which is much better, multiple tables join with one main table, or each table join with one another.

example: 5 tables join with one main table

main table == 0

table 5 join table 0, table 4 join table 0, table 3 join table 0, table 2 join table 0, table 1 join table 0

each id's of 5 tables is in main table 0

OR

table 5 join table 4, table 4 join table 3, table 3 join table 2, table 2 join table 1, and table 1 join main table 0.

Mike Sherrill 'Cat Recall'
  • 91,602
  • 17
  • 122
  • 185
  • It's not depend on the join you want to use.. it is depend on your desired output. – Vijunav Vastivch May 16 '17 at 01:16
  • well..the output is the same.. just a little confused on which one is much better for me to use. – kaizoku himura May 16 '17 at 01:36
  • Are you saying that you have the tables and a query result specification, and you just want to know the order to join them in? (Then it depends on how your DBMS optimizes query expressions, your table statistics and your particular query result specification.) – philipxy May 17 '17 at 05:28

1 Answers1

0

over all you cant say which one is the better version. The more you normalize, the more you have to join at some point it could lead into performance issues. If you need those joins often, i would prefere less normalization ;)

SmokedMeat
  • 48
  • 5