Jump to content

Archived

This topic is now archived and is closed to further replies.

extrovertive

What's the most tables you have joined?

Recommended Posts

Only two or three, and that is typically something like users and groups or forums, topics and posts.

Share this post


Link to post
Share on other sites
Only five or so. [u]Full[/u] normalization doesn't become that usefull untill you have tables that can potentially get huge, creating a huge amount of repeated data. So on a database that isn't likely to become that big, out of pure lazyness  :P, I use it with moderation.

Share this post


Link to post
Share on other sites
[quote author=448191 link=topic=107987.msg434026#msg434026 date=1158223441]
Only five or so. [u]Full[/u] normalization doesn't become that usefull untill you have tables that can potentially get huge, creating a huge amount of repeated data. So on a database that isn't likely to become that big, out of pure lazyness  :P, I use it with moderation.
[/quote]

Moderation? Like in a forum system?

I have a cache table containing things like group information, moderators, settings etc. so I can read from a lot of tables with only one query. The cached information is updated each time it's edited by an admin or so.

Share this post


Link to post
Share on other sites
If you are joining double figure tables, and repeating the process (i.e. not just a one off query) you [i]definitely[/i] need to look into using VIEW's.

JOIN's can be inefficient compared to VIEW's, in both computing power and maintenance (by developers)

Whenever I find I need to make more than 3 joins, I make views.

Share this post


Link to post
Share on other sites
[quote author=Daniel0 link=topic=107987.msg436372#msg436372 date=1158560347]
Moderation? Like in a forum system?
[/quote]

LOL, and English isn't even my native language...  :P

[quote=wikipedia]Moderation is the process of eliminating or lessening extremes. It is used to ensure normality throughout the medium on which it is being conducted. [/quote]
[quote=http://www.thefreedictionary.com]
mod·er·ate Pronunciation (mdr-t)
adj.
1. Being within reasonable limits; not excessive or extreme: a moderate price.[/quote]

Share this post


Link to post
Share on other sites
[quote author=Jenk link=topic=107987.msg436439#msg436439 date=1158579591]
If you are joining double figure tables, and repeating the process (i.e. not just a one off query) you [i]definitely[/i] need to look into using VIEW's.

JOIN's can be inefficient compared to VIEW's, in both computing power and maintenance (by developers)

Whenever I find I need to make more than 3 joins, I make views.
[/quote]

agreed. i've had one application where i ended up joining 12+ tables, so i ended up writing up about 4 different views that i could query from, so in the completed app, i never had more than 4 joins... very useful

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.