Look in the doc:

http://nhforge.org/doc/nh/en/index.html#querycriteria-detachedqueries

2009/4/27 Kenneth Siewers Møller <[email protected]>

>
> Hi there
>
> I am working on a rather complex query using the Criteria API. My
> problem is that I need to test using having on a subquery projection.
> Is that even possible?
>
> Something like this:
>
> var projections = Projections.ProjectionList()
> .Add(Projections.Property("my.Property", "property"))
> .Add(Projections.SubQuery(DetachedCriteria.For<...>(...), "subQuery");
>
> var criteria = DetachedCriteria.For<...>("my")
> .SetProjection(projections)
> .Add(Restrictions.Eq(Projections.Property("subQuery", 12);
>
> How would I do something like that using the Criteria API?
> >
>

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