While connecting SQL Server in Data modeler tool using JDBC url, I am getting following error
com.microsoft.sqlserver.jdbc.SQLServerException: "encrypt" property is set to "true" and "trustServerCertificate" property is set to "false" but the driver could not establish a secure connection to SQL Server by using Secure Sockets Layer (SSL) encryption: Error: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target.
I have followed following steps, so let me know if I am missing any steps:
- Downloaded JDBC driver 12.6 from https://go.microsoft.com/fwlink/?linkid=2272555
- In Data modeler, Add new JDBC driver; **Tools>Preferences>Data Modler>Third Party JDBC Drivers>Clicking + Icon ** and browse .jar file
“C:\Program Files\Microsoft JDBC DRIVER 12.6 for SQL Server\sqljdbc_12.6\enu\jars\mssql-jdbc-12.6.2.jre11.jar”
- Now I go to File>Import> Data Dictionary>Add connection>Select Database Type:JDBC
Add all details which are required in form
- JDBC URL = jdbc:sqlserver://;serverName=MyServerName;databaseName=MyDatabase;trustServerCertificate=true
- Driver Class = com.microsoft.sqlserver.jdbc.SQLServerDriver
- Database Type = SQL Sever
After adding all details, Click on Test Connection.
Is there any issue configuring JDBC driver? or is there any issue in version of SQL Server and JDBC?