Nhibernate 3.0 Complex queries

200 Views Asked by At

I need to perform queries that can be very complex, and I wanna make sure linq/queryOver can handle it.

what's the limitations and abilities I can't get with linq and can get with sql/hql ?

2

There are 2 best solutions below

0
On BEST ANSWER

There isn't a list of limitations, other than the list of open bugs in Jira.

if you are performing complex queries, HQL is usually the best way to go.

0
On

However complex the query is you cna ultimately convert it toa QueryOver it might just get a little difficult and hard to read, but then you have a very strongly typed API.

Having said that you can always use HQL on your object model to achieve the same.

 Session.CreateQuery("").List<>();

if that is difficult then there is always SQL to do the same.

 Session.CreateSqlQuery("").ExecuteUpdate<>();
 Session.CreateSqlQuery("").List<>();