Can NHibernate linq/lambda expressions be compiled so they aren’t reevaluate on every use?
Can NHibernate linq/lambda expressions be compiled so they aren’t reevaluate on every use?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Compiling them (into delegates) would make them execute in memory, which is something you definitely do NOT want.
They must stay as expression trees in order to be parsed into Criteria expressions (2.x contrib provider) or HQL trees (3.x provider), and then into SQL.