Microsoft Knowledge Base Email Alertz

(166029) - When using Active Server Pages (ASP) to query an Access database, you may encounter the following error message. Microsoft OLE DB Provider for ODBC Drivers error '80004005' [Microsoft][ODBC Microsoft Access 97 Driver] The Microsoft Jet database engine...

Search KbAlertz

Advanced Search

Receive Microsoft Knowledge Base articles by E-Mail?

Every night we scan the Microsoft Knowledge Base. If technologies you're interested in are updated, we'll send you an e-mail. You only get one e-mail a day, and only when new articles are added.

Click here to create a
FREE account
Already have an account?
[Click here to Login]











Microsoft Knowledge Base Article

This article contents is Microsoft Copyrighted material.
©2005-©2007 Microsoft Corporation. All rights reserved. Terms of Use | Trademarks

Article ID: 166029 - Last Review: July 3, 2008 - Revision: 5.0

PRB: Error "Cannot Open File Unknown" Using Access

This article was previously published under Q166029
We strongly recommend that all users upgrade to Microsoft Internet Information Services (IIS) version 7.0 running on Microsoft Windows Server 2008. IIS 7.0 significantly increases Web infrastructure security. For more information about IIS security-related topics, visit the following Microsoft Web site:
http://www.microsoft.com/technet/security/prodtech/IIS.mspx (http://www.microsoft.com/technet/security/prodtech/IIS.mspx)
For more information about IIS 7.0, visit the following Microsoft Web site:
http://www.iis.net/default.aspx?tabid=1 (http://www.iis.net/default.aspx?tabid=1)

SYMPTOMS

When using Active Server Pages (ASP) to query an Access database, you may encounter the following error message.
Microsoft OLE DB Provider for ODBC Drivers error '80004005'

[Microsoft][ODBC Microsoft Access 97 Driver] The Microsoft Jet database engine cannot open the file '(unknown)'. It is already opened exclusively by another user, or you need permission to view its data.

/scripts/somefile.asp, line x

CAUSE

This Error message can be caused by any of the following conditions:
  1. The Access .mdb file is located on another computer than the IIS Server.

    -and-

    IIS Server is configured to use NT Challenge / Response when accessing secured script files.
  2. The Access .mdb file is located on another computer than the computer running IIS.

    -and-

    IIS is configured to use the IUSR_computername account for anonymous access.

    -and-

    The script file being accessed is not secured and permits anonymous access.

    -and-

    The IUSR_computername is a local account and the same account/password does not exist on the remote computer
  3. The Access .mdb file is located on the same computer as the Web server.

    -and-

    The datasource uses a UNC path to point to the .mdb file (for example, DSN=\\servername\share).

    -and-

    NT Challenge/Response is used to authenticate the user.
  4. The Access .mdb file is linked to a table where the table linked to is in an Access database on a network server. In this situation, please refer to the following article in the Knowledge Base for a workaround:
    189408  (http://kbalertz.com/Feedback.aspx?kbNumber=189408/EN-US/ ) PRB: ASP Fails to Access Network Files Under IIS 4.0

RESOLUTION

This behavior is by design.

MORE INFORMATION

When using NT Challenge / Response with IIS, the users credentials are created at the browser. The credentials are then sent to IIS. IIS cannot forward those credentials on to another server.

The connection is attempted, but there is no username specified when connecting to the remote machine, so the connection fails.

REFERENCES

For additional information, click the article numbers below to view the articles in the Microsoft Knowledge Base:
174811  (http://kbalertz.com/Feedback.aspx?kbNumber=174811/EN-US/ ) Authentication and Security White Paper for Internet Developers
253580  (http://kbalertz.com/Feedback.aspx?kbNumber=253580/EN-US/ ) HOWTO: Connect to a Remote Access Database from Active Server Pages

APPLIES TO
  • Microsoft Active Server Pages 4.0
  • Microsoft Internet Information Server 4.0
  • Microsoft Internet Information Services 5.0
Keywords: 
kbdatabase kberrmsg kbmdacnosweep kbprb kbsecurity kbtshoot KB166029
       

Community Feedback System

Very often, it takes hours to solve a problem. Very often, you've looked high and low, and have tried a lot of solutions. When you finally found it, chances are, it was because someone else helped you. Here's your chance to give back. Use our community feedback tool to let others know what worked for you and what didn't.

Please also understand that the community feedback system is not warranted to be correct, it's simply a system that we've built to let people try and help each other. If something in a feedback response doesn't make sense to you, or you're not comfortable making changes that the feedback talks about (like registry edits), please consult a professional.

Thank you for using kbAlertz.com Feedback System.

-- Scott Cate