I am getting an exception while running my spring boot application, it say unable to create bean of datasource and caused of this exception is that it unable to detect my Dr
You are trying to load the wrong driver. The driver with name com.microsoft.jdbc.sqlserver.SQLServerDriver
is from the very old SQL Server 2000 JDBC driver.
In the SQL Server 2005 JDBC driver, Microsoft changed this to com.microsoft.sqlserver.jdbc.SQLServerDriver
(note the switch of order between sqlserver
and jdbc
.
Side note: you are using an old version of the driver. Microsoft has open sourced the SQL Server JDBC driver and it is available on maven as:
com.microsoft.sqlserver
mssql-jdbc
6.2.2.jre8
See https://github.com/Microsoft/mssql-jdbc for actual latest versions.