CallumVass
CallumVass

Reputation: 11448

Database error in classic ASP application

I have a classic ASP app which connects to an access database, I receive the following error when I try to access a page which connects to the database:

Microsoft OLE DB Provider for ODBC Drivers error '80004005'

[Microsoft][ODBC Microsoft Access Driver]General error Unable to open registry key 'Temporary (volatile) Jet DSN for process 0x1b48 Thread 0x1970 DBC 0x1948024 Jet'.

/gasket.inc, line 24

Here is my gasket.inc file:

<%
'include file for gasket table database object


'Dimension variables
Dim adoConG         'Database Connection Variable
Dim strConG     'Holds the Database driver and the path and name of the database
Dim rsGasket        'Database Recordset Variable
Dim strAccessDBG    'Holds the Access Database Name
Dim strSQLG         'Database query sring


'Initialise the strAccessDB variable with the name of the Access Database
strAccessDBG = "\\MyServer\databases\gaskets\gaskets.mdb"

'Create a connection object
Set adoConG = Server.CreateObject("ADODB.Connection")

'Database connection info and driver
strConG = "DRIVER={Microsoft Access Driver (*.mdb)};uid=admin;pwd=; DBQ=" & strAccessDBG

'Set an active connection to the Connection object
'adoConG.Open "DSN=Gaskets"
adoConG.Open strConG

'Create a recordset object
Set rsGasket = Server.CreateObject("ADODB.Recordset")


%>

Does that admin user require permission to access the database? Or am I missing something else which is obvious?

Upvotes: 0

Views: 541

Answers (1)

kpcrash
kpcrash

Reputation: 330

If you're using a UID/PWD for this, that would have to match an account that was used to lock the database, or a machine/domain account that will have write to/lock permissions to the db. Also, keep in mind that classic ASP is running under the IUSR_ account by default - sometimes this account must have write access to the directory/file containing the Access db.

Upvotes: 1

Related Questions