Re: Manage many to many relationship between "N" number of tables

From: EdStevens <quetico_man_at_yahoo.com>
Date: Wed, 2 Jan 2008 17:27:52 -0800 (PST)
Message-ID: <80251ca3-e6e2-4025-9c35-a3acb9a208fa@i12g2000prf.googlegroups.com>


On Jan 2, 5:50 pm, "steven...._at_googlemail.com" <steven...._at_googlemail.com> wrote:
> Hi All,
>
> I need help on database design which can manage many to many
> relationship between "N" number of tables. for last 2 days i'm
> thinking over this but not able to find a solution it will be great if
> someone can help me.
>
> Problem:
>
> Say i have 3 tables A, B & C in my db. They can have Many to Many
> relation ship with each other i.e. A <-> B, A<->C, B <->C. other than
> 3 junction tables how can i establish this relationship in my db?
> i'm asking this because here i have taken 3 tables as example only..if
> tomorrow a new table D is added to this DB (which also requires many
> to many relation with other tables) i want to handle such scenario
> without creating few more junction tables( A <-> D, B <-> D, C <-> D)
> in my DB. i want some generic DB design which can manage many to many
> relationship between any number of tables.
>
> is such design really possible or i'm being crazy?
>
> Cheers !

Perhaps if you gave the specifics of what entities these tables represent and how they relate. With no more than you've given, it strikes me as a design in serious need of re-thinking, Especially when you imply that adding new tables to the mix will be a somewhat regular occurance. Received on Wed Jan 02 2008 - 19:27:52 CST

Original text of this message