Hi!
Have you tried this?
<class name="User" .. >
...
<bag name="LookupUserGroups" inverse="true" lazy="true" cascade="all-
delete-orphan">
<key column="UserID"/>
<one-to-many class="LookupUserGroup" column="LookupUserGroupID"/
>
</bag>
</class>
<class name="LookupUserGroup" .. >
...
<bag name="Users" lazy="true" cascade="all-delete-orphan">
<key column="LookupUserGroupID"/>
<one-to-many class="User" column="UserID"/>
</bag>
</class>
You could post some code that doesn't work.
Check this out:
http://nhforge.org/doc/nh/en/index.html#collections-bidirectional
On Mar 16, 8:48 am, Kris-I <[email protected]> wrote:
> Hello,
>
> I'm stuck on many-to-many, I tried sevceral sample without succes :(
>
> I have 2 tables : User and LookupUserGroup
>
> I'd like assign User to several LookupUserGroup
>
> Any idea ?
>
> Thanks,
--
You received this message because you are subscribed to the Google Groups
"nhusers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/nhusers?hl=en.