Errors I am facing
Error creating bean with name 'entityManagerFactory' defined in class path resource \[org/springframework/boot/autoconfigure/orm/jpa/HibernateJpaConfiguration.class\]: Invocation of init method failed; nested exception is org.hibernate.service.spi.ServiceException: Unable to create requested service \[org.hibernate.engine.jdbc.env.spi.JdbcEnvironment\]Unable to create requested service \[org.hibernate.engine.jdbc.env.spi.JdbcEnvironment\]Access to DialectResolutionInfo cannot be null when 'hibernate. dialect' not set
Configurations Spring boot 2.7 Rest API MS SQL Server 11.0(Production) MS SQL Server 15.0(Local)
My application.properties
//my local database where I can connect and perform tasks
#spring.datasource.url=jdbc:sqlserver://SACHINSAVITA\\SQLEXPRESS:1433;encrypt=false;databaseName=employee #spring.datasource.username=root #spring.datasource.password=root #server.port=8090 #server.address=10.6.10.193
Production where I am facing errors
spring.datasource.url=jdbc:sqlserver://10.6.1.165:1433/employee?; spring.datasource.username=root spring.datasource.password=root spring.jpa.show-sql=true spring.jpa.hibernate.ddl-auto=none server.port=8099 server.address=10.6.10.193 spring.jpa.hibernate.dialect=org.hibernate.dialect.SQLServer2008Dialect
Pom.xml file
`
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.7.5</version>
<relativePath /> <!-- lookup parent from repository -->
</parent>
<groupId>com.gcc.biometric.api</groupId>
<artifactId>GccBioMetricApi</artifactId>
<version>0.0.1-SNAPSHOT</version>
<name>GccBioMetricApi</name>
<description>Spring Boot Api</description>
<properties>
<java.version>1.8</java.version>
</properties>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-jpa</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
<scope>runtime</scope>
<optional>true</optional>
</dependency>
<dependency>
<groupId>com.microsoft.sqlserver</groupId>
<artifactId>mssql-jdbc</artifactId>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>
<!--#########################################-->
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-core</artifactId>
</dependency>
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-entitymanager</artifactId>
</dependency>
<!-- https://mvnrepository.com/artifact/org.json/json -->
<dependency>
<groupId>org.json</groupId>
<artifactId>json</artifactId>
<version>20171018</version>
</dependency>
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
</dependency> <!--$NO-MVN-MAN-VER$-->
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
</project>
`
I tried with different dialects but not able to understand whats the problem, please help!