-----Original Message-----
From: Les Hazlewood [mailto:[EMAIL PROTECTED]
Sent: Thursday, September 18, 2003 4:39 AM
To: Snively, Paul (SMCI); [EMAIL PROTECTED]
Cc: Beckman, Sam; Venegas, Frank; Wu, Feng
Subject: RE: [Hibernate] Multiple Collections of Same Entity?Can a Bar in the "bars" set also be in the "otherBars" set? Or are the sets mutually exclusive?
Les
> -----Original Message-----
> From: Snively, Paul (SMCI) [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, September 16, 2003 7:18 PM
> To: [EMAIL PROTECTED]
> Cc: Beckman, Sam; Venegas, Frank; Wu, Feng
> Subject: [Hibernate] Multiple Collections of Same Entity?
>
>
> Folks,
>
> We're pondering an entity class that has two collections,
> both of which we'd like to contain instances of some other
> entity class:
>
> class Foo
> {
> Integer id;
> private Set bars; // Association to class Bar
> private Set otherBars; // Association to class Bar
> }
>
> From the documentation, it would seem that I would need two
> foreign key columns in Bar: one for each Set. First of all,
> is this correct, and secondly, are there any risks to this
> that I'm overlooking? I should add that I can assume that Bar
> is a lifecycle object of Foo, if that helps.
>
> Many thanks and best regards,
> Paul Snively
>
>
>
> **************************************************************
> *********
> This e-mail and any files transmitted with it are intended
> solely for the use of the addressee. This e-mail may
> contain confidential and/or legally privileged information.
> Any review, transmission, disclosure, copying, or any action
> taken or not taken, by other than the intended recipient, in
> reliance on the information, is prohibited. If you received
> this e-mail in error, notify the sender and delete this e-mail
> (and any accompanying material) from your computer and
> network. In addition, please be advised that 21st Century
> Insurance Group reserves the right to monitor, access and
> review all messages, data and images transmitted through
> our electronic mail system. By using our e-mail system, you
> consent to this monitoring.
> **************************************************************
> *********
>
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> hibernate-devel mailing list [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/hibernate-devel
>
Title: RE: [Hibernate] Multiple Collections of Same Entity?
Hi
Les!
The
sets can definitely contain the same elements; in fact, "bars" is a proper
subset of "otherBars."
Thanks
for the help!
Paul
- [Hibernate] Multiple Collections of Same Entity? Snively, Paul (SMCI)
- RE: [Hibernate] Multiple Collections of Same Ent... Les Hazlewood
- RE: [Hibernate] Multiple Collections of Same Ent... Snively, Paul (SMCI)
- RE: [Hibernate] Multiple Collections of Same Ent... Les Hazlewood