I just downloaded the Linq provider for NHibernate, and I'm just a little excited. But I do not know the Linq syntax very well.
I can return whole objects from a query like this:
var query = from foo in session.Linq<Kctc.BusinessLayer.Domain.Case>()
where foo.CaseNumber > 0
select foo;
And I can select one property similar to this:
var query = from foo in session.Linq<Kctc.BusinessLayer.Domain.Case>()
where foo.CaseNumber > 0
select foo.Id;
But how to choose two properties, for example. foo.Id and foo.Bar? Or is it impossible?
thank
David
David source
share