1. 在 configuration / configSections 节中加入对 nHibernate 框架的支持

<configSections>
在 Web.Config 中部署 nHibernate     
<section name="nhibernate" type="System.Configuration.NameValueSectionHandler, System, Version=1.0.5000.0,Culture=neutral, PublicKeyToken=b77a5c561934e089" />
</configSections>

2. 在 configuration 根节中添加 nhibernate 节,其内容如下:

支持 Microsoft Access 的写法:

在 Web.Config 中部署 nHibernate<nhibernate> 
在 Web.Config 中部署 nHibernate     
<add key="hibernate.connection.provider" value="NHibernate.Connection.DriverConnectionProvider" /> 
在 Web.Config 中部署 nHibernate     
<add key="hibernate.dialect" value="NHibernate.JetDriver.JetDialect, NHibernate.JetDriver" /> 
在 Web.Config 中部署 nHibernate     
<add key="hibernate.connection.driver_class" value="NHibernate.JetDriver.JetDriver, NHibernate.JetDriver" /> 
在 Web.Config 中部署 nHibernate     
<add key="hibernate.connection.connection_string" value="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=hibtest.mdb" /> 
在 Web.Config 中部署 nHibernate
</nhibernate> 


支持 Microsoft SQL Server 2000 的写法:


支持 Oracle 的写法:

相关文章:

  • 2021-09-16
  • 2022-12-23
  • 2022-03-08
  • 2021-12-27
  • 2022-12-23
  • 2021-08-21
  • 2021-09-23
  • 2021-04-10
猜你喜欢
  • 2021-06-17
  • 2021-06-07
  • 2021-06-17
  • 2021-09-18
  • 2021-12-14
  • 2021-08-17
  • 2022-02-05
相关资源
相似解决方案