nhibernate/nhibernate-core — pull request #120 by hazzik (2012-06-08 20:20:41+00:00)
Title: NH-3184: Linq - add ability to use ToFutureValue with aggregating queries

Add ability to use ToFutureValue with aggregating queiries such as Count, Sum, etc.

Proposed syntax:

var futurePerson = session.Query()
.Where(x => x.Id == personId)
.ToFutureValue(x=>x.Count());

Discussions:

http://stackoverflow.com/questions/4955685/getting-count-with-nhibernate-linq-future

http://sessionfactory.blogspot.com/2011/02/getting-row-count-with-future-linq.html

JIRA: https://nhibernate.jira.com/browse/NH-3184