Jump to content
rogerio

ADO ODBC .mdb connection

Recommended Posts

I have tried everything under the sun and still cannot connect to Northwind.mdb. I used W3 (http://www.w3schools.com/ado/ado_connect.asp) and set up ODBC with Northwind as the DNS, etc. I took ownership of the database. I am running Win7 64 bit and IE8. I get this error: An error occurred on the server when processing the URL. Please contact the system administrator.If you are the system administrator please click here to find out more about this error.Here is the .asp code:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"><%set conn=Server.CreateObject("ADODB.Connection")conn.Provider="Microsoft.Jet.OLEDB.4.0"conn.Open "G:/inetpub/wwwroot/Northwind.mdb"response.write(conn.State) <!-- Never returns anything -->conn.close%><html>	<head>		<title>Untitled HTML Document</title>	</head>	<body>	</body></html>

Thanks...

Share this post


Link to post
Share on other sites

Make sure "friendly HTTP errors" are disabled in IE's options, or click the link it gives you for information. What you're seeing is a generic error page, not the specific error message.

Share this post


Link to post
Share on other sites

Thanks justsomeguy - Disabled "friendly HTTP errors" and the same generic error shows up. Clicked link and it takes me to the IIS learning page without any specific info. This same error shows up in IE8 and Foxfire 3.I can't believe it, but can a 64 bit OS be creating a problem???

Share this post


Link to post
Share on other sites

Got this error: ADODB.Connection error '800a0e7a'Provider cannot be found. It may not be properly installed./opendb.asp, line 13 What is on line 13: conn.Open "G:/inetpub/wwwroot/Northwind.mdb"Tried downloading MDAC 2.8 and suggestions on this site: http://support.microsoft.com/default.aspx?scid=kb;en-us;894435Still get the same error. Now, I have seen discussions about compiling in 32 bit mode and I cannot find any information on how this is accomplished. Please keep in mind I am running Windows 7 Home Premium with limited abilities.Thanks,

Share this post


Link to post
Share on other sites

Tried you last suggestion and still fails. It looks like Jet is causing the issue, but can't prove it. Have ran across something different:If I run this script, it succeeds: cscript %SYSTEMDRIVE%\inetpub\adminscripts\adsutil.vbs SET W3SVC/AppPools/Enable32bitAppOnWin64 1 to swap to 32 bitor cscript %SYSTEMDRIVE%\inetpub\adminscripts\adsutil.vbs SET W3SVC/AppPools/Enable32bitAppOnWin64 0 to swap to 64 bitI get:ErrNumber: -2147221020 (0x800401E4)Error Trying To Get the Object: W3SVC/AppPoolsThis runs without any problem: %SYSTEMROOT%\Microsoft.NET\Framework64\v2.0.50727\aspnet_regiis.exe -i

Share this post


Link to post
Share on other sites

Why do you think it's a 64-bit issue? I'm not sure how you reached that conclusion. It just sounds to me like the data provider you're trying to use isn't installed.

Share this post


Link to post
Share on other sites

I don't know what it is, I have been grabbing any straw that I can find. I was trying to find out if I am trying to compile under 32 bit or 64 bit. I know that a 64 bit MDAC does not exist, so I have to run the connection under 32 bit and I can't find the answer.

Share this post


Link to post
Share on other sites

IIS7 and IIS7.5 definitely still have a way to connect to an MDB file. It looks like Jet has been deprecated, so I would suggest an alternate provider. That connection strings site points out a couple ways using OLE DB, and Jet itself was superseded by MSDE. Vista calls it Windows DAC instead of MDAC, Windows 7 probably does also. It looks like MDAC has supported a 64-bit platform since 2001 (MDAC 2.7).

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...