You’d think that moving from our old servers (Windows 2008) to our new servers (Windows 2003) would be pretty simple, seeing as our code is so old-school. But oh now, Microsoft don’t ship the database drivers for 64bit Windows by default. Joy.
So here’s what you have to do to get MySQL 5.1 working with classic ASP under Windows Server 2003 64bit:
- Install the 64bit version of mySQL Server (Windows x64)
- Install the 64bit version of mySQL Connector 5.1 (Windows x64)
- Now the funky bit. Go download: 64-Bit OLEDB Provider for ODBC (MSDASQL)
- Install the Provider
- Reboot the server
- Set-up your ODBC datasource as per usual
- Modify your ASP connection string to explicitly use the new driver:
e.g.:
PROVIDER=MSDASQL; DRIVER={MySQL ODBC 5.1 Driver}; SERVER=myserver; DATABASE=mydatabase; USER=mydbuser; PASSWORD=mydbpass; OPTION=3;
You should now be good to go. If you googled and saw posts about getting IIS to run in 32bit mode as a solution… don’t. It’s a world of pain, and when we tried it made our server really unstable.