Hibernate version:
1.2.0 beta 1
Name and version of the database you are using:
MSSQL 2005
Hi!
Im new at NHibernate to say the least - but i did read a whole lot of documentation. I may be blind but i really cant seem to find what im looking for:
Its a one-to-many relation, but with the foreign-key placed in the parent-table. How does the XML-mapping look for this?
This is my DB-design (simplified):
TField (Parent)
ID {Guid, Identifier, non-null}
Version {Integer, Identifier, non-null}
NameID {Foreign-Key, non-null}
TName (Child)
ID {Guid, Identifier, non-null}
Version {Integer, Identifier, non-null}
Value{varchar(100), non-null}
That is, one TFIeld may reference one or more TName's (each with different version)
The TField C#-class would have a list of TName's, and the TName-class a single property to TField.
|