Connect to DB2

Senz79
Senz79 used Ask the Experts™
on
Hello All

I want to connect to DB2 using C# application . I have the following information about the DB2 server . How can i write the function


Driver Class : com.ibm.db2.jcc.DB2Driver (v2.11)
Driver URL : jdbc:db2://testDB:60000/TESTDB:currentSchema=USER;
Username and Password

Thanks
Senz
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Rahul Goel ITILSenior Consultant - Deloitte

Commented:
Use this connectionstring
Server=myAddress:myPortNumber;Database=myDataBase;UID=myUsername;PWD=myPassword;Max Pool Size=100;Min Pool Size=10;
Commented:
hi
ConnectionString = @"Provider=IBMDADB2.1;Data Source=WAREHOUS;Uid=XX;Pwd=XXX;Network Address=XXXX"

This worked for me .

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial