Hi,
today I started with using NHibernate and I get into trouble during inserting data into the database. I get an error that the insert command is incorrect, but I do not know how to get the SQL output. I have tried to set the show_sql to "true" but I get no output. Here is my config file:
Code:
<?xml version="1.0" encoding="utf-8" ?>
<hibernate-configuration xmlns="urn:nhibernate-configuration-2.0" >
<session-factory name="NHibernate.Test">
<!-- properties -->
<property name="connection.provider">NHibernate.Connection.DriverConnectionProvider</property>
<property name="connection.driver_class">NHibernate.Driver.OleDbDriver</property>
<property name="dialect">NHibernate.Dialect.MsSql2000Dialect</property>
<property name="connection.connection_string">
Provider=Microsoft.Jet.OLEDB.4.0;
User ID=Admin;
Data Source=C:\test.mdb;
Mode=Share Deny None;
Extended Properties=;
Locale Identifier=1031;
Jet OLEDB:Registry Path=;
Jet OLEDB:Database Password=;
Jet OLEDB:Engine Type=5;
Jet OLEDB:Database Locking Mode=1;
Jet OLEDB:Global Partial Bulk Ops=2;
Jet OLEDB:Global Bulk Transactions=1;
Jet OLEDB:New Database Password=geheim;
Jet OLEDB:Create System Database=False;
Jet OLEDB:Encrypt Database=True;
Jet OLEDB:Don't Copy Locale on Compact=False;
Jet OLEDB:Compact Without Replica Repair=False;
Jet OLEDB:SFP=False;
</property>
<property name="show_sql">true</property>
<property name="use_outer_join">true</property>
<property name="query.substitutions">true 1, false 0, yes 'Y', no 'N'</property>
<!-- mapping files -->
<mapping file="Test.hbm.xml" />
</session-factory>
</hibernate-configuration>
I am trying to connect to a .mdb file and calling a select statement works, but insert and update fails. I do not know what is the problem. How can I enable internal logging or what is wrong in my config file?