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

Announcements
Discover how organizations are unlocking new revenue streams: Watch here
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

DB connection error

Hi! I'm trying to use tContextLoad to dynamically change the credentials of the input table but i always end up getting this error...
THANKS! 0683p000009MACn.png
0683p000009MEcY.jpg
Labels (2)
7 Replies
Anonymous
Not applicable
Author

Hi,
Please refer to component reference about tContextLoad with related scenario.
Best regards
Sabrina
Anonymous
Not applicable
Author

Hi,
Please refer to component reference about tContextLoad with related scenario.
Best regards
Sabrina

Hi! It's exactly the same reference guide I referred in to. I actually followed each and every step and I had problems connecting to sql server. Pls see the error msg. Thanks!
Anonymous
Not applicable
Author

Hi
From the error message, i am sure there must be something wrong in the DB parameters settings, it seems some value are null or empty. Print the value of context variables on the console to see if the context variables are loaded correctly. For example:
tFileList--iterete--tFileInputDelimited--main--tContextLoad--oncomponentok--tJava--oncomponentok--tmssqlInput---main--tLogRow
on tJava: print the value of context variable,
System.out.println(context.host);
...
Shong
Anonymous
Not applicable
Author

Hi,

In addition, here are some articles about Setting up a DB connection
See my pic(the SqlServer DB connection is success in talend open studio for Data Integration 5.3.0)
Best regards
Sabrina
0683p000009MEnw.png
Anonymous
Not applicable
Author

Hi
From the error message, i am sure there must be something wrong in the DB parameters settings, it seems some value are null or empty. Print the value of context variables on the console to see if the context variables are loaded correctly. For example:
tFileList--iterete--tFileInputDelimited--main--tContextLoad--oncomponentok--tJava--oncomponentok--tmssqlInput---main--tLogRow
on tJava: print the value of context variable,
System.out.println(context.host);
...
Shong

Hi Shong! I tried it and all context variables were loaded correctly. Unfortunately, I still get this error in tMSSqlInput:
Exception in component tMSSqlInput_1
java.sql.SQLException: The syntax of the connection URL 'jdbc:jtds:sqlserver://;appName=JM;' is invalid.
at net.sourceforge.jtds.jdbc.Driver.setupConnectProperties(Driver.java:245)
at net.sourceforge.jtds.jdbc.Driver.connect(Driver.java:181)
at java.sql.DriverManager.getConnection(DriverManager.java:579)
at java.sql.DriverManager.getConnection(DriverManager.java:221)
at jm.dummy_0_1.dummy.tMSSqlInput_1Process(dummy.java:1706)
at jm.dummy_0_1.dummy.tJava_1Process(dummy.java:1078)
at jm.dummy_0_1.dummy.tFileList_1Process(dummy.java:972)
at jm.dummy_0_1.dummy.runJobInTOS(dummy.java:2758)
at jm.dummy_0_1.dummy.main(dummy.java:2602)
0683p000009MPcz.png
Thanks!
Anonymous
Not applicable
Author

Hi,
Out of context, did you set your mssql DB connection successfully in a usual DB connection? Is your DB in local or server?
Best regards
Sabrina
Anonymous
Not applicable
Author

Hi,
Out of context, did you set your mssql DB connection successfully in a usual DB connection? Is your DB in local or server?
Best regards
Sabrina

Server. Yes I checked in the usual DB connection set up and it was successful. I just don't get it why I'm having errors in tMSSqlLInput. 😕