"HQL: YEAR(...) in (:years) -> setting int?[] parameter" - means that I want to do this:
Code:
IQuery query = session.CreateQuery(@"from DatabaseObjects.Entry ent
where YEAR(ent.EntryDate) in (:years)");
query.SetInt32("years", intYears);
EntryCollection coll = new EntryCollection(query.List());
Where intYears is declared:
Code:
int?[] intYears = new int?[] { 2004, 2005, 2006 };
How to do this?
Also, this forum is REALLY slow - why not ask around for a forum written with for example NHibernate using badass caching (e.g. output cache 1 min) to speed it up?