32-bit asp.net app on 64-bit machine
-
OK.. so I have an application built on the .NET 2.0 framework with a MySQL database which needs to run on a 64-bit Windows 2008 Server (with service Pack 1) After installing it, in order to get it to run, I have to go to the application pools in IIS, find the relevant one, click on Advanced Settings, and set "Enable 32-bit applications" to True. That works - otherwise I get a "Server Error in '/' Application. ... is not a valid Win32 application" page. Trouble is though, as soon as I do set this, while simple pages display al;right, as soon as I get to one that requires database access I get this error:
ERROR [IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
If I set "Enable 32-bit applications" to False, I can run a simple test page that access tha database (uncompiled, with inline server code) and this works fine - so the connector is working adn the connectionstring correct. All of which kind of leaves me between a rock and hard place. Any ideas gratefully received!
-
OK.. so I have an application built on the .NET 2.0 framework with a MySQL database which needs to run on a 64-bit Windows 2008 Server (with service Pack 1) After installing it, in order to get it to run, I have to go to the application pools in IIS, find the relevant one, click on Advanced Settings, and set "Enable 32-bit applications" to True. That works - otherwise I get a "Server Error in '/' Application. ... is not a valid Win32 application" page. Trouble is though, as soon as I do set this, while simple pages display al;right, as soon as I get to one that requires database access I get this error:
ERROR [IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
If I set "Enable 32-bit applications" to False, I can run a simple test page that access tha database (uncompiled, with inline server code) and this works fine - so the connector is working adn the connectionstring correct. All of which kind of leaves me between a rock and hard place. Any ideas gratefully received!
You've created an ODBC data source using the 64-bit version of the ODBC Administrator tool. You need to create it in the 32-bit version of the tool, which is located at:
%SystemRoot%\SysWOW64\odbcad32.exe
Data Source Names and 64-Bit Operating Systems[^]
"These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer
-
You've created an ODBC data source using the 64-bit version of the ODBC Administrator tool. You need to create it in the 32-bit version of the tool, which is located at:
%SystemRoot%\SysWOW64\odbcad32.exe
Data Source Names and 64-Bit Operating Systems[^]
"These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer
I have no idea how to even do that... I ahve never "created an ODBC data source" in my life. All I do is add some code to create it in my asp.net code behind, then assign it a connectionstring
"Provider=MSDASQL;Driver={MySQL ODBC 5.1 Driver};server=localhost;database=xxx;uid=xxx;pwd=xxx"