cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Help us improve the PTC Community by taking this short Community Survey! X

Need help with connection to MS SQL extension

jgu12
4-Participant

Need help with connection to MS SQL extension

Imported "MSSQLConnector_Extension" and copy the file "sqljdbc42.jar" into the folder ...\Tomcat 8.5\lib.

 

For the configuration of Database Thing based on the ThingTemplate from the JDBC extension 

JDBC Driver Class Name: com.microsoft.sqlserver.jdbc.SQLServerDriver
JDBC Connection String: jdbc:sqlserver://localhost:1433;databaseName=thingworx01;applicationName=Thingworx
connectionValidationString: SELECT GETDATA();

 

Ensure the admin and password is valid.

When testing service "GetAllRecords: select * from table01", failed. "Unable to Invoke Service GetAllRecords on MSSQLDatabase : null"

 

ACCEPTED SOLUTION

Accepted Solutions
posipova
20-Turquoise
(To:jgu12)

Are you referring to this extnsion? https://marketplace.ptc.com/apps/195356/jdbc-connector-extension#!overview

If so, please note it's not supported and provided in as-is condition. I'd recommend obtaining a needed driver and creating your own extension per instructions I provided here  https://community.ptc.com/t5/ThingWorx-Developers/Using-a-third-party-Jar-file-for-Database-connection/m-p/514861?author_id=269584&collapse_discussion=true&filter=authorId&q=jdbc&search_type=thread

View solution in original post

2 REPLIES 2
posipova
20-Turquoise
(To:jgu12)

Are you referring to this extnsion? https://marketplace.ptc.com/apps/195356/jdbc-connector-extension#!overview

If so, please note it's not supported and provided in as-is condition. I'd recommend obtaining a needed driver and creating your own extension per instructions I provided here  https://community.ptc.com/t5/ThingWorx-Developers/Using-a-third-party-Jar-file-for-Database-connection/m-p/514861?author_id=269584&collapse_discussion=true&filter=authorId&q=jdbc&search_type=thread

jgu12
4-Participant
(To:posipova)

change the connectionValidationString from SELECT GETDATA() to SELECT 1, then it works successfully.

Announcements


Top Tags