这是我的配置文件。我有一个数据库,名字是贝辛。我的sql server版本是2012 express。另外,我的项目名称是NHibernate_Test
<hibernate-configuration xmlns="urn:nhibernate-configuration-2.2">
<session-factory>
<property name="connection.provider">NHibernate.Connection.DriverConnectionProvider</property>
<property name="dialect">NHibernate.Dialect.MsSql2008Dialect</property>
<propert name="query.substitutions">hqlFunction=SQLFUNC</propert>
<property name="connection.driver_class">NHibernate.Driver.SqlClientDriver</property>
<property name="connection.connection_string">Data Source=(local);Initial Catalog=Basin; Integrated Security=True; </property>
<property name="show_sql">true</property>
<mapping assembly="NHibernate_Test"/>
</session-factory> </hibernate-configuration> </configuration
但是我得到一个错误
错误:解析配置发生异常:命名空间"urn:nhibernate-configuration-2.2"中的元素"session-factory"在命名空间"urn:nhibernate-configuration-2.2"中有无效的子元素"property"。命名空间"urn:nhibernate-configuration-2.2"中可能出现的元素列表:"属性、映射、类缓存、集合缓存、事件、监听器"
在
<propert name="query.substitutions">hqlFunction=SQLFUNC</propert>
与异常
完全相同我们需要. .在命名空间中存在无效的子元素' property ' .
<property...
看到属性与 y 在