[unixODBC-support] Can I have 2 driver manager running at the same time?
Martin J. Evans
bohica at ntlworld.com
Tue May 31 08:55:23 BST 2011
On 30 May 2011 23:22, Eugenia Moreno <eugemz at hotmail.com> wrote:
> Hi Nick,
> Thanks for all your help.
> I was able to install both Driver Manger, one compiled with SQLLEN and the
> other default. Just to be sure that they are connecting to the right driver
> manager, I have separated odbc.ini and odbcinst.ini, that will not be a
> The DSNs are working fine, if I use the isql of each installation (going to
> folder bin directory), it connects OK.
> However, I still do not know how to tell the application to use any of the
> driver manager. I just need this to work, I though perl because I know it
> better, but it could be Python or other language. You mention to set the the
> search path library, do you mean the to LD_Library_path? I try that but it
> didn't work. I am new in Linux, so I am lost too..
> Thanks in advance.. Eugenia
> Date: Fri, 27 May 2011 22:37:51 +0100
> From: nick at lurcher.org
> To: unixodbc-support at mailman.unixodbc.org
> Subject: Re: [unixODBC-support] Can I have 2 driver manager running at the
> same time?
> On 27/05/2011 21:30, Eugenia Moreno wrote:
> I am just planning to do a perl scrip that needs to connect to Vertica
> using the driver compiled with the BUILD_LEGACY_64_BIT_MODE option.
> There are other applications that already connect to the unix_odbc 2.2.14
> with 8 bytes so I am not sure if I compile the new lib in other folder how I
> will tell my perl script to choose the correct driver manager. Having two
> sets of libs in the system, means also have 2 sets of ODBC.ini and
> You can use the same ini files if you have seperate entries for the two
> drivers. A bigger problem is that Perl (assuming you are using DBD::ODBC)
> needs to know the size of SQLLEN (32 or 64 bit).
> _______________________________________________ unixODBC-support mailing
> list unixODBC-support at mailman.unixodbc.org
> unixODBC-support mailing list
> unixODBC-support at mailman.unixodbc.org
Bare in mind that if you have two applications which link to two different
ODBC Driver managers you need to build the applications differently because
the header files from the 2 different driver managers will be used
For instance, for Perl. Usually DBD::ODBC looks for the odbc_config program
which it runs with --cflags to obtain the compiler flags needed to build a
compatible app with that driver manager. I've not followed what you real aim
was but lets say you had a 64 bit machine and 32 bit Perl and 64 bit Perl
installed in /home/me/perl32 and /home/me/perl64. Let say you installed
unixODBC in /home/me/unixodbc32 and /home/me/unixodbc64. You need to do
something like the following:
then for DBD::ODBC:
# check if finds odbc_config in the unixodbc32 dir by watching output
now repeat above changing all 32 to 64.
To run the 32 bit Perl apps you will need to LD_LIBRARY_PATH as above. To
run the 64 bit Perl apps you will need LD_LIBRARY_PATH =
DBD::ODBC knows nothing about odbc_config's --ulen and if you have changed
the size of a SQLULEN then odbc_config --cflags should output the correct
compiler flags to match unixODBC - I've never checked that.
Martin J. Evans
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the unixODBC-support