And the query plan cache keeps growing in 2.0.1. We ran into this problem,
as described by RasmusKL here (
http://www.rasmuskl.dk/post/A-WinDbg-Debugging-Journey-NHibernate-Memory-Leak.aspx).
We couldn't move to a newer version yet, so in the meantime my hack was to
recycle the session factory every hour, which seems to have resolved the
issue, but of course the better solution is to get a newer version of
NHibernate.

On Thu, May 28, 2009 at 8:13 AM, Tuna Toksoz <[email protected]> wrote:

> string queryStr = string.Format("from Member m,
> VirtualCard v where v.IpCode = m.IpCode and  v.LoyaltyIdNumber =
> '{0}'", loyaltyIDNumber);
>
> If you use this like this, you'll have different cached query execution
> plans for different ids. Try using parameters instead
>
>
> v.LoyaltyIdNumber=:loyaltyIdNumber
>
> and
>
> .SetParameter("loyaltyIdNumber",33)
>
>
>
> This might be one reason.
>
> Tuna Toksöz
> Eternal sunshine of the open source mind.
>
> http://devlicio.us/blogs/tuna_toksoz
> http://tunatoksoz.com
> http://twitter.com/tehlike
>
>
>
>
> On Thu, May 28, 2009 at 3:10 PM, Waqar Sadiq <[email protected]>wrote:
>
>> string queryStr = string.Format("from Member m,
>> VirtualCard v where v.IpCode = m.IpCode and  v.LoyaltyIdNumber =
>> '{0}'", loyaltyIDNumber);
>>
>
>
>  >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to