cancel
Showing results for 
Search instead for 
Did you mean: 

Need help to rectify error "Driver's SQLAllocHandle on SQL_HANDLE_HENV failed" during odbc connectiv

Former Member
12,020

Hi, I have installed sql anywhere 16 in linux machine. Below is the content of my odbc.ini file. I have written the odbc program to access the demo database(which came as part of sql anywhere16 installation). While running the program am getting the error message - "NOTICE: IM004:1:0:[unixODBC][Driver Manager]Driver's SQLAllocHandle on SQL_HANDLE_HENV failed".

[SQL Anywhere 16 Demo]
UID=DBA
PWD=sql
DatabaseFile=/home/vaish/sqlanywhere16/demo.db
ServerName=demodb
Port                = 2638
StartLine=/home/vaish/sqlanywhere16/bin32/dbeng16
Description=SQL Anywhere 16 Sample Database
Driver=/home/vaish/sqlanywhere16/lib32/libdbodbc16.so

Can anyone help me to identify the problem with my settings?

Thanks, Vaish

Accepted Solutions (0)

Answers (1)

Answers (1)

jack_schueler
Product and Topic Expert
Product and Topic Expert

ODBC connection failures

If you do not deploy all the files required for the ODBC driver, you may encounter the following error when attempting to connect to a database.

[IM004][Microsoft][ODBC Driver Manager] Driver's SQLAllocHandle on SQL_HANDLE_ENV failed

Check that you have installed all the files required for the correct operation of the ODBC driver.

jack_schueler
Product and Topic Expert
Product and Topic Expert
0 Kudos

PS. I recently added this to the SQL Anywhere documentation. You'll see it in some new release.