I think I know that the answer to this question is likely to be, but I thought that I would continue and ask him anyway.
It seems like in NHibernate, if I do something like this:
IList<Customer> customers = Session.CreateCriteria(typeof(Customer)) .Add(Restrictions.Eq("Name", "Steve") .List<Customer>();
And I want to delete this list of clients. From what I can say, the only way to do this is:
foreach(var customer in customers) { Session.Delete(customer); }
But I am wondering if there is a way I can just go:
Session.Delete(customers);
And delete the entire collection with a single call?
source share