2009/8/14 Stefan Steinegger <[email protected]>:
>
> The index of a list is no property. It is just a column to allow NH to
> read it in the same order back as it has been stored.
>
> Not every column is a property. Foreign keys aren't, list indexes are
> also no properties.
>
> With a list of composite-elements your Property would only look like
> this:
>
> public class Property
> {
>    public virtual string Name { get; set; }
> }
>
> And the table would have this columns:
>
>  ProductId (foreign key to product)
>  SortOrder
>  Name
>


And if your Property is really just a string, you can even make
Product simply have a IList<string> thus avoding the need for the
Property class, with the same three columns as above in the Property
table.

/Oskar

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to