oracle数据库配置hibernate成功了,但是sqlserver数据库配置就出错了,请各位大神指教
错误如下:
org.hibernate.service.classloading.spi.ClassLoadingException: Specified JDBC Driver com.microsoft.jdbc.sqlserver.SQLServerDriver could not be loaded
配置文件如下:配置文件的驱动加载及url都是系统自动选择的呢,仅修改了连接地址及用户名信息而已;
<property name="hibernate.connection.driver_class">com.microsoft.jdbc.sqlserver.SQLServerDriver</property>
<property name="hibernate.connection.url">jdbc:sqlserver://localhost:1433;DatabaseName=HRD</property>
<property name="hibernate.connection.username">014892</property>
<property name="hibernate.connection.password">014892</property>
<property name="hibernate.dialect">org.hibernate.dialect.SQLServerDialect</property>
<property name="show_sql">true</property>
<property name="format_sql">true</property>
<property name="hibernate.hbm2ddl.auto">create</property>
<mapping resource="Student.hbm.xml" />