Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Save $650 on Qlik Connect, Dec 1 - 7, our lowest price of the year. Register with code CYBERWEEK: Register
cancel
Showing results for 
Search instead for 
Did you mean: 
Croix
Creator
Creator

Can You See a JDBC String a Data Source Uses to Connect?

Is there a way that I can see the JDBC connection that a data source uses to connect? In some cases I want to check it to see if it is sending the correct connection string. 

Labels (1)
2 Replies
Anonymous
Not applicable

You can do this using a bit of Java if you are using a Connection component. Let's say you are using a tMSSqlConnection component called tMSSqlConnection_1. You cab use a tJava with the code below to interrogate the connection and get the URL. To use the code below for other DBs simply change the connection component name section of the code.

 

java.sql.Connection conn_tMSSqlConnection_1 = (java.sql.Connection)globalMap.get("conn_tMSSqlConnection_1");

System.out.println(conn_tMSSqlConnection_1.getMetaData().getURL());
Anonymous
Not applicable

You can do this using a bit of Java if you are using a Connection component. Let's say you are using a tMSSqlConnection component called tMSSqlConnection_1. You cab use a tJava with the code below to interrogate the connection and get the URL. To use the code below for other DBs simply change the connection component name section of the code.

 

java.sql.Connection conn_tMSSqlConnection_1 = (java.sql.Connection)globalMap.get("conn_tMSSqlConnection_1");

System.out.println(conn_tMSSqlConnection_1.getMetaData().getURL());