Hi,

There is a "Delete" method on ISession which can accept query. But
unfortunately, it is slow because it is actually equivalent to

foreach(var o in s.Delete("from Entity e")) s.Delete(o);

Eg. it first loads all objects into the memory and then deletes them
one-by-one.

We could, potentially, delegate the implementation to just
CreateQuery("delete from Entity e").ExecuteUpdate();

The difference between this approach that the second one does not trigger
cascade deletes.

What do you think?

Best Regards,
Alexander

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"nhibernate-development" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to nhibernate-development+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to