My configuration looks like this:
<hibernate-configuration xmlns="urn:nhibernate-configuration-2.2" >
<session-factory name="kvws.kist.suche.dbadapter.nhentities">
<!-- Driver -->
<property name="connection.driver_class">NHibernate.Driver.SqlClientDriver</property>
<property name="dialect">NHibernate.Dialect.MsSql2005Dialect</property>
<!-- DB-Connection settings -->
<property name="connection.connection_string">
...
</property>
<property name="adonet.batch_size">10</property>
<property name="show_sql">true</property>
<property name="format_sql">true</property>
<property name="prepare_sql">true</property>
<property name="command_timeout">0</property>
<!-- other settings -->
<!-- using a proxy is mandantory, LinFu is easiest to setup (no setup...) -->
<property name="proxyfactory.factory_class">NHibernate.ByteCode.LinFu.ProxyFactoryFactory, NHibernate.ByteCode.LinFu</property>
</session-factory>
</hibernate-configuration>
I was under the impression that the setting of prepare_sql
ensured the use of prepared statements in NHibernate. However, It does not "feel" that way.
How can I test/see if "prepared statements" are used?
Is the above the correct setting for use of "prepared statements"?
Could other settings interfere with the execution?