|
From: NHibernate J. <nh...@gm...> - 2008-09-30 12:33:40
|
[ http://jira.nhibernate.org/browse/NH-519?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Fabio Maulo updated NH-519:
---------------------------
Fix Version/s: (was: 2.1.0.Alpha1)
> Cache and reuse prepared statements
> -----------------------------------
>
> Key: NH-519
> URL: http://jira.nhibernate.org/browse/NH-519
> Project: NHibernate
> Issue Type: Improvement
> Components: Core
> Affects Versions: 1.0.1
> Reporter: Geert Verbakel
> Priority: Minor
> Attachments: prepared statements.txt
>
>
> Same bug as NH-140 (reintroduced in 1.0.1.0)
> The same statement (for eagerly loading many-to-one objects) is prepared everytime it is executed.
> In 0.6.0.0, a statement would be prepared once and reused:
> * declare @P1 int
> set @P1=443
> exec sp_prepexec @P1 output, N'@p0 uniqueidentifier', N'SELECT ..... WHERE Id= @p0', @p0 = '611475FC-FC66-4C3A-8C2D-0BB27AF8BDCA'
> * exec sp_execute 443, @p0 = '23BBE372-74E7-4EFB-B605-9DDA90E02462'
> (multiple times)
> In 1.0.1.0, this is no longer the case. It is always sp_prepexec
> I have set hibernate.prepare_sql to true, which result in statements being prepared, but not cached...
> See attached file for Query analyzer details
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.nhibernate.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
|