Reputation: 1021
I need to restrict a one-to-many collection by a date column with a value specified on the parent element. The 'where' attribute on set or bag looks perfect for this.
NHibernate documentation describes the 'where' attribute as being for arbitrary SQL, so am I correct in assuming that I cannot use values from the parent class here as I would in HQL and must implement my own IUserCollection instead?
Upvotes: 0
Views: 832
Reputation: 1038810
IMHO using a filter would be better because you could write the restriction in database agnostic HQL.
Upvotes: 1