I have a domain object called Product, that has a many to many
collection of type Category.
I want to retrieve just the categories that belong to a specific
Product.
var result = Session.CreateCriteria<Product>()
.Add(Restrictions.Eq("Name", "Television"))
.CreateCriteria("Categories")
.List<Category>();
This returns an "unable to perform sql" error.
Am I supposed to be doing a projection instead? I assumed an extra
"CreateCriteria" would be enough.
Andy
--
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.