Tag Archives: 64 bit windows and mysql connection

Connect 32 bit Classic ASP Page on 64 bit Windows Server to Remote MYSQL Database

In my company, for our windows machines, we have started to ditch 32 bit OS in favour of 64 bit systems, purely because 64 bit is more scaleable in terms of RAM and CPU for the hungry .asp and .net sites.

One issue I came across today was a customer asking how he can connect his classic asp pages to a remote mysql database.

Despite the server being 64 bit Windows 2008 R2 his site is running in 32 bit mode so we needed to install 32 bit drivers.

So here is what I did and it worked great.

1. installed the 32 bit version of the  mysql odbc connector from http://www.mysql.com/downloads/connector/odbc/#downloads
2. in windows explorer, navigated to the syswow64 folder at c:/windows/syswow64/ (this is where all the 32 bit applications are installed)
3. scrolled down to odbcad32.exe and executed it
4. the 32 bit odbc manager popped up and I set up the connection as a dsn

I then created a test classic asp page on the server using dsn connection and it connected without any fuss.

The confusion I had initially was I was trying to configure the 32 bit connection via the 64 bit odbc manager, it was just not working at all, its only when I set the dsn up via the 32 bit odbc manager, everything purred perfectly.