1

I need to connect an application to my DB2 database. Both application and db are running on the same machine.

I've tried this:


Server=localhost:50000;Database=myDataBase;UID=myUsername;PWD=myPassword;

I'm getting the following error:

CLI0124E Invalid argument value. SQLSTATE=HY009

Am I using the wrong connection string?

Edit I've also tried the following format:


Provider=IBMDADB2;Database=urDataBase;Hostname=urServerAddress;Protocol=TCPIP;Port=50000;
Uid=urUsername;Pwd=urPassword;

Same result.

asked Sep 9, 2013 at 14:34
1
  • are you connecting with JDBC? ODBC? Commented Sep 9, 2013 at 15:14

2 Answers 2

0

Not sure where you got those connection strings. According to the documentation, the provider you use needs three keywords: DSN, UID, and PWD. DSN refers to the Windows data source, which you define as usual after installing the DB2 Data Server Client software.

answered Sep 9, 2013 at 15:50
0

The application was asking for a connection string, when all it really wanted was the Database name. I'm not sure why the field is named Connection String...

answered Sep 10, 2013 at 14:54

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.