Access a 32-bit Firebird database from a 64-bit app via ODBC

64-bitfirebirdodbc

I'm running Win7 64-bit and Firebird 2.5.2.

Is it possible to access a 32-bit Firebird database via ODBC from a 64-bit C++ application? My initial thought was that I could just install the 64-bit Firebird ODBC driver and it would work. Sure enough, after installing it the 64-bit ODBC control panel app shows the Firebird driver, but the connection fails when trying to point it to an .fdb file created with 32-bit Firebird. I'm picking the client library from the 64-bit firebird install as well (C:\Program Files\Firebird\Firebird_2_5\bin\fbclient.dll).

Any suggestions on accessing a 32-bit Firebird database via ODBC from a 64-bit C++ application?


EDIT:

My bad, looks like its working fine. I must have accidentally mixed some 32- and 64-bit pieces of the config when setting things up. Once I ensured that I was 1) running the 64-bit server, 2) using a 64-bit ODBC data source which 3) referred to the 64-bit client DLL (from the 64-bit Firebird install) my 64-bit C++ app connected with no issue.

I thought I checked those but I must have missed something in going between 32- and 64-bit.

Best Answer

See edit in original post. The problem was mixing some of the 32- and 64-bit pieces in the config. Its working now. You definitely can access the 32-bit database from the 64-bit app once setup properly. Also according to Mark Rotteveel you can run the 32-bit server and use that from the 64-bit app as long as you're using the 64-bit pieces on the app side.

Related Topic