Use the following process to configure the DataDirect Driver Manager on Solaris:
-
Find the DataDirect Driver Manager configuration files under the extracted directory:
$ cd stage/clients-odbc-<your_client_os>/DataDirect/setup
-
Copy the odbcinst.ini, odbc.ini, and aster.ini files from the /setup directory to your home directory:
$ cp -p * ~
-
Change to your home directory:
$ cd
-
Make backups of the files you moved and rename aster.ini to .aster.ini:
$ cp -p aster.ini aster.ini.backup $ mv aster.ini .aster.ini $ cp -p odbc.ini odbc.ini.backup $ cp -p odbcinst.ini odbcinst.ini.backup
-
Make the following edits to .aster.ini:
- Set DriverManagerEncoding to UTF-8.
-
Set ODBCInstLib to <InstallDir>/DataDirect/lib/libodbcinst.so, replacing <InstallDir> with the folder where the driver is installed. For example:
[driver] DriverManagerEncoding=UTF-8 ODBCInstLib=<InstallDir>/DataDirect/lib/libodbcinst.so DriverLocale=en-US LogLevel=0 ErrorMessagesPath=<InstallDir>/ErrorMessages
-
Modify odbc.ini as follows:
-
Change the DSN configuration parameters SERVER, UID, PWD, DATABASE and PORT.
[ODBC Data Sources] ... ... asterdsn=AsterDriver [ODBC] ... ... [asterdsn] Driver=<InstallDir>/DataDirect/lib/libAsterDriver.so SERVER=192.206.82.100 PORT=2406 DATABASE=beehive UID=beehive PWD=beehive
-
Add this line to the [ODBC] section of odbc.ini:
InstallDir=<InstallDir>/DataDirect
-
To support multi-byte characters, add this line to the [ODBC] section of odbc.ini:
IANAAppCodePage=106
-
Change the DSN configuration parameters SERVER, UID, PWD, DATABASE and PORT.
-
Add the <InstallDir>/DataDirect/lib to:
LD_LIBRARY_PATH
-
Export the following values, where <directory_path> is the path to the directory where the files odbc.ini and odbcinst.ini reside:
export ODBCINI=<directory_path>/odbc.ini export ODBCINST=<directory_path>/odbcinst.ini export ODBCINSYSINI=<directory_path>
-
Edit the odbcinst.ini file, as shown in this example:
[ODBC Drivers] ... ... AsterDriver=Installed [ODBC Translators] OEM to ANSI=Installed [ODBC] #This section must contain values for DSN-less connections #if no odbc.ini file exists. If an odbc.ini file exists, #the values from that [ODBC] section are used. [AsterDriver] Driver=<InstallDir>/DataDirect/lib/libAsterDriver.so IconvEncoding=UCS-4LE