0
votes

I have a VB6 legacy application that uses 32-bit ADO drivers to make a database connection using ODBC.

Now the customer has installed the 64-bit version of the database, and I am getting an error:

[Microsoft][ODBC Driver Manager] The specified DSN contains an architecture mismatch between the Driver and Application

Error Source: Microsoft OLE DB Provider for ODBC Drivers

I checked the net but could not find 64-bit OLEDB drivers for Windows Server 2012. There was a link for Windows Server 2003.

Can someone confirm whether the drivers exist and post the link to download them? Thanks.

EDIT 1: This question is different from: Migrating VB6 code to use 64-bit ODBC DSN

This question is more about download the 64 bit ODBC driver, whereas that question is about code changes.

EDIT 2: Even if I find 64-bit drivers, my VB6 application is 32-bit. Can a 32-bit application use 64-bit drivers at all? Note that installing the 32-bit version of database is ruled out.

1

1 Answers

1
votes

Your legacy VB6 application is a 32-bit OLE DB consumer. It therefore requires a 32-bit OLE DB Provider for ODBC Data Sources, and a 32-bit ODBC Driver, such as those from my employer or various other sources.

The VB6 app loads some libraries into shared memory, and all of these much match bitness -- the VB6 app, the OLE DB Provider it loads, and in this case, the ODBC driver that loads, and in some cases, other libraries that loads.

Communications then happen over (typically) the TCP/IP stack or other networking layers -- which don't have to agree in bitness -- between the client-side libraries (i.e., ODBC driver) and the server-side (i.e., DBMS).

It does not matter that the target DBMS nor that the application's host OS is now 64-bit.