in reply to Class::DBI and a self-referencing many-to-many
In my opinion though, it would be better to just add a single parent_id column to your person table and use a simple tree structure. Adding a separate table complicates some things.Person->has_many(children => [ Person::Relationship => child ], 'paren +t'); Person->has_many(parents => [ Person::Relationship => parent ], 'child +');
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Class::DBI and a self-referencing many-to-many
by jgallagher (Pilgrim) on Sep 14, 2005 at 18:45 UTC | |
by perrin (Chancellor) on Sep 14, 2005 at 20:50 UTC | |
by jgallagher (Pilgrim) on Sep 14, 2005 at 21:20 UTC | |
by perrin (Chancellor) on Sep 14, 2005 at 21:28 UTC |