ClassNotFoundException - com.microsoft.jdbc.sqlserver.SQLServerDriver

前端 未结 4 1522
别那么骄傲
别那么骄傲 2020-12-20 12:50

I have a web development project using local install of Tomcat 7. I am trying to connect to SQL Server 2012 using Microsoft\'s driver for jdbc (

4条回答
  •  时光说笑
    2020-12-20 13:30

    I think you need to be registered on the dialect class: org.hibernate.dialect.SQLServer2012Dialect

    if it were spring project, it is connected to a file application.properties:

    spring.datasource.driver-class-name=com.microsoft.sqlserver.jdbc.SQLServerDriver
        spring.jpa.database-platform=org.hibernate.dialect.SQLServer2012Dialect
        spring.datasource.url=jdbc:sqlserver:database;user=sa;password=password;
        spring.datasource.username=sa
        spring.datasource.password=password
    

    but here it will be exactly like I do not remember

提交回复
热议问题