an ODBC driver?
UniVerse is linked to the unixODBC Driver Manager, which enables it to connect to third-party databases by using an ODBC driver. For example, UniVerse can use unixODBC and a SQL Server ODBC driver to connect to SQL Server. This blog provides an overview of this process, along with a few things to try if you experience difficulties.
Accessing SQL Server from UniVerse involves the following components:
UniVerse -> unixODBC Driver Manager -> SQL Server ODBC Driver -> SQL Server
UniVerse ships with an ODBC Driver Manager. For example, $uvhome/bin/libodbc.sl
. You need to replace this version of the Driver Manager with the one that the SQL Server ODBC driver is installed under. To do this, you:
libodbc.extension
is located on your system. If you're using the Driver Manager that was included in the SQL Server ODBC driver distribution, unixODBC is located in install_dir/unixODBC/lib
. (By default, install_dir
is /usr/local
.)LD_LIBRARY_PATH
, SHLIB_PATH
, LIB_PATH
as appropriate). For example:
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/easysoft/unixODBC/lib:/usr/local/easysoft/lib export LD_LIBRARY_PATH
relink.uvlibs
script:
cd $uvhome/bin relink.uvlibs /usr/local/easysoft/unixODBC/lib
If after having done this, you're unable to connect to SQL Server, try the following:
file $uvhome/bin/libodbc.extension file install_dir/unixODBC/lib/libodbc.extension
Are the libraries the same architecture. If not, you need to use a verson of unixODBC that matches UniVerse's architecture.
ENV
in your UniVerse shell, do you get the Driver Manager directories listed? For example:
ENV SHLIB_PATH=/usr/lib:/usr/local/easysoft/unixODBC/lib:/usr/local/easysoft/lib
pldd 100101 100101: /uv/bin/uvsh /uv/bin/libodbc.sl
This pldd
command extract shows that UniVerse is still using the UniVerse supplied Driver Manager.