我遇到了越來越NHibernate的發揮好與SQLite的問題:NHibernate和SQLite的愁楚
<NHibernate>
<hibernate xmlns="urn:nhibernate-configuration-2.2">
<session-factory>
<property name="connection.driver_class">NHibernate.Driver.SQLite20Driver</property>
<property name="connection.provider">NHibernate.Connection.DriverConnectionProvider</property>
<property name="connection.connection_string">Data Source=test.db;New=True;</property>
<property name="show_sql">false</property>
<property name="dialect">NHibernate.Dialect.SQLiteDialect</property>
<property name="use_outer_join">true</property>
<property name="show_sql">false</property>
<property name="proxyfactory.factory_class">NHibernate.ByteCode.LinFu.ProxyFactoryFactory, NHibernate.ByteCode.LinFu</property>
<mapping assembly="SimpleGallery" />
</session-factory>
</hibernate>
</NHibernate>
我在Windows 7 64位運行:
我的NHibernate的配置。我已經嘗試將x86和64位版本的system.data.sqlite.dll複製到輸出目錄以及引用它們並將它們設置爲複製本地但無濟於事。 VS解決方案已被設置爲編譯到任何/ x86/64位,但我仍然得到例外:
「{」無法找到程序集System.Data.SQLite中的IDbCommand和IDbConnection實現。確保程序集System.Data.SQLite位於應用程序目錄或全局程序集緩存中。如果程序集位於GAC中,則使用應用程序配置文件中的元素指定程序集的全名。「}」
我缺少什麼?
不知道是否有幫助,但你可以嘗試下載尖銳建築項目,它有它配置SQL精簡版。 – Sly 2010-07-05 09:05:47