dbTalk Databases Forums  

ODBC connection from Linux to DB2

comp.databases.ibm-db2 comp.databases.ibm-db2


Discuss ODBC connection from Linux to DB2 in the comp.databases.ibm-db2 forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
newtilus
 
Posts: n/a

Default ODBC connection from Linux to DB2 - 12-08-2011 , 12:33 PM






Hi!

I have a problem defining ODBC connection to DB2 from CentOS 6 (Linux
based on Redhat). I'm almost sure that I've done everything as it
should be, but can you, please, try to find some gaps in my
understanding? Below are the steps:


[root@localhost etc]# cat /etc/odbc.ini
[ODBC]
Trace = yes
Tracefile = /root/odbc_trace.log

[ODBC Data Sources]
UA_SYSTEM_TABLES = IBM DB2 ODBC DRIVER

[UA_SYSTEM_TABLES]
Driver = DB2
Description = UA_SYSTEM_TABLES Data Source
Database = TEST

[root@localhost etc]# cat /etc/odbcinst.ini
[DB2]
Description = DB2 Driver
Driver = /opt/ibm/db2/V9.7/lib32/libdb2.so
DontDLCLose = 1
FileUsage = 1

[root@localhost etc]# odbcinst -i -d -f /etc/odbcinst.ini
odbcinst: Driver installed. Usage count increased to 2.
Target directory is /etc

[root@localhost etc]# odbcinst -i -s -f /etc/odbc.ini

[root@localhost etc]# isql -v UA_SYSTEM_TABLES
[S1009][unixODBC][IBM][CLI Driver] CLI0124E Invalid argument value.
SQLSTATE=S1009
[ISQL]ERROR: Could not SQLConnect

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.