given a query in the form of an ICriteria object, I would like to use NHibernate (by means of a projection?) to find an element\'s order, in a manner equivalent to using
ICriteria has this 2 functions:
SetFirstResult()
and
SetMaxResults()
which transform your SQL statement into using ROW_NUMBER (in sql server) or limit in MySql.
So if you want 25 records on the third page you could use:
.SetFirstResult(2*25) .SetMaxResults(25)