Hi
Im wondering if this is possible to get the same result with ICriteria regarding this hql-query.
Code:
select rel from Release rel where rel.Details.CreatedBy = 'James' or
rel in (select elements(pkg.Releases) from Package pkg where pkg.Details.CreatedBy = 'James') or
rel in (select elements(pkg.Releases) from Package pkg left join pkg.Log log where log.CreatedByUser = 'James')
The one thing i could get with ICriteria was how to get or, ive created a couple of detached criterias that was combined but the separator word in the resulting sql where AND instead of OR. Is this type of querys possible with ICriteria? I could find any documentation about the SubQueries.In and i wasnt able to get it working.
Edit
There is relations in the mappings between all of the objects, but from Releases to Package its a many to many. Package.Log is a collection, Releases is also a collection.
Regards