Hello Robert, it happened to be my error in reasoning.
Thank you! Jan On 28 Mrz., 18:26, Robert Rudduck <[email protected]> wrote: > Not sure I see where the composite-key is? > > WorkflowNodes has Id (which I assume is unique), and Workflow has an Id > (which I assume is unique) so you would just map them both individually with > Id tags, no need for a composite id. > > The join between WorkFlow and WorkFlowNodes would be: > > <bag name="WorkflowNodes" table="WorkflowNodes" inverse="true"> > <key column="WorkflowId" /> > <one-to-many class="WorkflowNodes" /> > </bag> > > Hope that helps. > > - Robert > > On Sun, Mar 28, 2010 at 11:11 AM, Jan Apel <[email protected]> wrote: > > Hello everyone, > > > I've got two tables: > > > [WorkflowNodes]: > > Id, int > > WorkflowId, int > > Type, string > > Implementation, string > > > and [Workflow]: > > Id, int > > Name, string > > Description, string > > CreationDate, datetime > > > I would like to create a List collection of these objects but I don't > > know how to write the mapping for the composite key WorkflowId: > > ... > > <id name="Id" column="Id" type="Int32"> > > <generator class="assigned" /> > > </id> > > > <property name="Name" column="Name" type="string"/> > > <property name="Description" column="Description" type="string"/> > > <property name="CreationDate" column="CreationDate" > > type="DateTime" /> > > <list ...> > > ??? > > </list> > > ... > > > How do I write the mapping for the composite-key "WorkflowId" from the > > WorkflowNodes table and get a collection of type list? > > > Many thanks in advance, > > > Jan Apel > > > -- > > 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]<nhusers%[email protected]> > > . > > For more options, visit this group at > >http://groups.google.com/group/nhusers?hl=en. -- 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.
