Hi, in /usr/share/doc/r-cran-rodbc/README.gz
I found this example: ============== [testpg] Description = testpg Driver = PostgreSQL Trace = No TraceFile = ServerName = localhost UserName = ripley Port = 5432 Socket = Database = testdb ReadOnly = 0 ============== I changed it for me to: ============== [rtest] Description = rtest Driver = PostgreSQL Trace = No TraceFile = ServerName = localhost UserName = oliver Port = 5432 Socket = Database = rtest ReadOnly = 0 ============== With your hint on the Driver-value: ============== [rtest] Description = rtest Driver = /usr/lib/odbc/libodbcpsqlS.so Trace = No TraceFile = ServerName = localhost UserName = oliver Port = 5432 Socket = Database = rtest ReadOnly = 0 ============== Maybe I should give different names for the section and the database?! ============== [rtestdb] Description = rtest Driver = /usr/lib/odbc/libodbcpsqlS.so Trace = No TraceFile = ServerName = localhost UserName = oliver Port = 5432 Socket = Database = rtest ReadOnly = 0 ============== x > channel <- odbcConnect("rtestdb", "rtest") x Warning messages: x 1: In odbcDriverConnect(st, ...) : x [RODBC] ERROR: state IM004, code 0, message [unixODBC][Driver x x Manager]Driver's SQLAllocHandle on SQL_HANDLE_HENV failed x 2: In odbcDriverConnect(st, ...) : ODBC connection failed So this is not working correctly. Here my settings for the ENV-vars: oli...@siouxsie:~$ echo $ODBCINI /etc/odbc.ini oli...@siouxsie:~$ echo $ODBCSYSINI /etc/ oli...@siouxsie:~$ echo $LD_LIBRARY_PATH /usr/lib/odbc/libodbcpsqlS.so oli...@siouxsie:~$ I have no clue what's the problem now. Oliver ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.