OLE DB Provider for ODBC Drivers Error "80004005'
Asked Answered
W

11

5

I have to move some customer sites from a very old IIS Server to a newer one, and some sites have troubles to work in the correct way. Most of them complain about a failure called:

Microsoft OLE DB Provider for ODBC Drivers error '80004005'

[Microsoft][ODBC Driver Manager]Data source name not found and no default driver specified.

I've read on the internet that this could depend on missing rights given to the user; other sites states that a Temp folder is missing (I can't imagine that this is right)… There are several other "solutions":

Open the rights for everyone on the server (as someone stated) is not an option for me. Also it is very painful to give explicit rights to every customer (there are several customers which needs the rights).

Do you know an easier solution, a similar way, or an alternative?

Wrangle answered 11/1, 2013 at 14:47 Comment(0)
P
4

I have got the similar issue while working with classic asp and with IBM DB2 ODBC Driver. I do have two websites configured in my local IIS 7.5, Connection.Open is working fine with default web site whereas it does not with the second website, after several configuration changes as per my knowledge and as per sugesions from stackoverflow did not helped me in this case.

What worked for me is to enable (Set to True) the 32bit applications Advanced setting of ASP.NET V4.0 Classic Application Pool.

Application Pools-->ASP.NET V4.0 Classic-->
           Advanced Settings--> under General Options double click Enable 32-bit Applications to set to True.

This small configuration may help some one who has the same issue.

Phototypy answered 26/7, 2016 at 5:53 Comment(1)
This was the solution for me thank you for posting your suggestionLemos
A
2

That error is nearly always caused by a bad connection string when an ADODB.connection object has its .open() method called.

For example, take the following code:

Dim SqlUsername : SqlUsername = "YOURSQLUSERNAME"
Dim SqlPassword : SqlPassword = "YOURSQLPASSWORD"
Dim ConnectionString : ConnectionString = "DRIVER={SQL Server};SERVER=YOURSERVERNAME;DATABASE=YOURDATABASENAME;UID=" & SqlUsername & ";PWD=" & SqlPassword 
Dim db
Set db = Server.CreateObject("ADODB.Connection")
db.Open ConnectionString , SqlUsername , SqlPassword 

Note how the connection string includes a driver identifier, in this example that is SQL Server.

Somewhere in your application you'll have an adodb.connection.open() method being called with a connection string, you need to find it, determine the driver being used and install it on your server.

Another thing to keep in mind, some data source drivers are 32bit and if your running your website in a 64bit application pool in IIS you'll need to allow 32bit objects - see this related question on that: Uploading picture after migration from IIS 6.0 to IIS 7.5

Autophyte answered 11/1, 2013 at 16:32 Comment(0)
C
2

Your old server has some ODBC DSN (Data Source Names) defined, and this is how your applications are connecting to the databases. You need to define these on your new server. Look in your server's Control Panel.

Chalkboard answered 11/1, 2013 at 22:32 Comment(1)
This is the actual answer .. everyone is trying to write asp connection strings, but they need to create the DSN on the server first.Skaggs
M
1

For sure now you have solved your problem but nevertheless for knowledge purposes here is what can work:

On top of what @webaware said please follow the steps below on your new server machine:

  1. Go to Control Panel
  2. Administrative Tools
  3. Data Sources (ODBC)
  4. Click System DSN tab
  5. Click the Add button
  6. Look for and select the Oracle in Client driver.
  7. Now type in the Data Source Name, Description, TNS Service Name and User ID

Note: Ask your database administrator for the correct TNS Service name and User ID. You will also need the user id for testing your connection.

  1. Click the Test Connection button
  2. Type in your TNS Service name as the Service Name, User ID as the User Name and the password of the User ID
  3. Click the Ok button

Your connection should be successful now.

Mandrill answered 24/5, 2017 at 12:4 Comment(0)
E
1

I had the same problem after update Control Panel Plesk 12.5 to Plesk Onyx 17.5.3 and see updated ODBC Driver to 5.3.

To resolve the problem I changed ( 5.1 ) to ( 5.3 Unicode Driver ) in connection string.

Change this :

Conn.Open "DRIVER={MySQL ODBC 5.1 };SERVER=localhost; DATABASE=psa; UID=admin;PASSWORD=mypassword;Port=8306; OPTION=3"

To :

Conn.Open "DRIVER={MySQL ODBC **5.3 Unicode Driver**};SERVER=localhost; DATABASE=psa; UID=admin;PASSWORD=mypassword;Port=8306; OPTION=3"
Earthlight answered 19/4, 2018 at 18:3 Comment(0)
S
1

Be sure to place the connection code at the top of the page vs bottom. That fixed my issue with this error.

Sowder answered 22/4, 2019 at 4:18 Comment(0)
V
0

The driver is not found because these drivers are not configured or registered in the system, I too got such an error when I run a asp page website in localhost. The same page was running smoothly in the host server. To register, go to Microsoft ODBC Administrator -> SYSTEM DSN tab -> Add your driver by clicking 'configure' button. Hope this helps.

Vaporing answered 25/1, 2017 at 5:19 Comment(0)
S
0

For me it was just a missing ";" after database name in connection string

Studer answered 13/4, 2017 at 14:46 Comment(0)
Q
0

This was not related to permissions. You are may be you defining database connections that explicit referenced a specific version of the mysql ODBC driver.

You will have to Update your connection strings.

Quianaquibble answered 27/10, 2020 at 2:6 Comment(0)
I
0

i have same error when use asp classic script , MySQL and Plesk control Panel (windows)

You can Enable 32-bit applications in Plesk :

Go To Plesk Control Panel => Hosting & DNS => Dedicated IIS Application Pool for Website => Enable 32-bit applications

Immersed answered 2/7, 2022 at 13:58 Comment(0)
W
0

I had the same error with a connection to a SQLServer database on ASP classic website, the problem was the password of the user account in SQL connection mode. Be sure to not use spécific characters like ";"

Wizard answered 2/10, 2024 at 15:44 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.