in reply to Class::DBI has_a relationships
I doubt this will fix the error, but shouldn't your Sessions_Metadata cross reference table have two primary keys?
Hope this helps ...__PACKAGE__->columns(Primary => qw/session_id username/); __PACKAGE__->columns(Others => qw/create_date expire query_id/);
UPDATE:
Ahhh ... i see the problem now. You are not setting up your Users and Sessions classes
to be able to 'have many' Sessions_Metadata. Here is how you might set up Users (untested).
I am not sure how your tables really relate, so you may or may not need to do something
similar in Sessions. Here goes:
You might need to explain more to us about how these tables relate to one another in order to find the solution.__PACKAGE__->has_many( sessions => [EP::Common::DBI::Sessions_Metadata => 'id'] => 'session_id' );
jeffa
L-LL-L--L-LL-L--L-LL-L-- -R--R-RR-R--R-RR-R--R-RR B--B--B--B--B--B--B--B-- H---H---H---H---H---H--- (the triplet paradiddle with high-hat)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Class::DBI has_a relationships
by drewbie (Chaplain) on May 19, 2004 at 03:12 UTC | |
|
Re: Re: Class::DBI has_a relationships
by CassJ (Sexton) on May 18, 2004 at 17:01 UTC | |
by jeffa (Bishop) on May 18, 2004 at 17:07 UTC | |
by CassJ (Sexton) on May 18, 2004 at 17:30 UTC | |
by jeffa (Bishop) on May 18, 2004 at 17:44 UTC | |
by CassJ (Sexton) on May 18, 2004 at 18:03 UTC |