I'm encountering problems in my ASP page. This is a login page which checks the user's credentials to the database before it allows access to the main page. I created a debugger page to find out what's the error details and this is the error message:
Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified.
That's the error message I' m encountering on the web server when I'm loging in to the site. The weird thing here is when testing the page locally on my machine (desktop) everything works fine (even with IIS and MSSQL server). I'm also using the same connection string when deploying and testing the page.
Please help, any suggestions or comments will be greatly accepted.
Thanks, Nhoyti
Last year I had this error when trying to connect to MySQL server. Try delete from Your my.ini one line: "skip-name-resolve" (disable name resolving), that don't resolve hostnames, because in this case all hostnames are IP or 'localhost'. OR try change edit yout 'account'@'localhost' to 'account'@'127.0.0.1'
A typical ODBC connection string to connect to SQL Server might look like this.
Go to Control Panel -> Administrave Tools -> Data Sources (ODBC)
Try create a user DSN using the information provided in your connection string and test the ODBC connection from your production server to the SQL Server.
I had a similar but slightly different issue and solution.
I was using Excel 64-bit and needed the 64-bit driver, instead.
In my case, was using a System.Runtime.InteropServices method via C# routine I developed awhile back when using Excel 32-bit -- the routine auto defines a set of ODBC connections at runtime (where was only installing the 32-bit My ODBC driver). The routine opens and edits an Excel spreadsheet (as a template -- then renames it on closing); while open it resets a series of connections, using this driver, for the current target names of DBs the user selected -- the MySQL DBs drive a bunch of pivot tables used for analysis.
I installed a latest version for My ODBC (where I could find both versions (5.3.13)).
With the 64-bit driver installed, no changes needed and the routine started working again. Also tested that can have both versions installed and works on 64-bit OS using either 32-bit or 64-bit MS Excel license.
Thanks for the help on this. I'd be nowhere today without stackoverflow!!.
The problem is probably with the ODBC configuration on the Server itself. In other words the connection string [to the ODBC source] is ok (since tested on other server), but it makes reference to a source that is not configured on this particular server.
To remedy the problem, open the ODBC Data Source Administrator (typically one of the shortcuts in the "Administrative" tools menu), and check if indeed you have a source (typically a "System DSN") with the same name found in the connection string. Such Source is probably inexistant or improperly configured.
Aside from performance considerations, one may consider using more direct Data Providers (such as MS SQL Data Provider or Microsoft.Jet.OLEDB) at the level of the connection string; this avoids the extra configuration point (the ODBC config panel) on the server (but then this may require using two distinct connections strings, one for the test environment and one for the production environment...)
Note that installing version sqlcmd 15.0.1000.34 requires both of these to be installed:
It will complain during installation and at run time and the error messages may not reflect reality.
Thread @ social.technet.microsoft.com
Bug @ feedback.azure.com
I ran into the same problem (while trying to connect to MySQL through Excel VBA) and it took me nearly half a day to resolve. I finally resolved the issue due to a response from fr0mi on VBForums.
fr0mi's answer on VBForums