472,357 Members | 2,009 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,357 software developers and data experts.

Issue accessing MS Access database on another server

I have searched this forum, and the web, and I have not been able to find a solution to my issue. I may not have used the right search information to find the answer, but I found a lot of issues close to mine, but nothing has helped.

We are running Apache/2.2.4 (Win32) PHP/5.2.3.

I am trying to use the odbc_connect to connect to an MS Access database that is on another server. I have tried to use both a system DSN, as well as putting the connection information into php. For example...

$con=odbc_connect("mysystemdsn","","") or die("didn't work");

$con = odbc_connect("DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" ."\\myotherserver\d$\mydb.mdb","","") or die("didn't work");

I have also tried mapping a network drive so I did...

$con = odbc_connect("DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" ."z:\mydb.mdb","","") or die("didn't work");

When not using the system DSN, I get...

Warning: odbc_connect() [function.odbc-connect]: SQL error: [Microsoft][ODBC Microsoft Access Driver] '(unknown)' is not a valid path. Make sure that the path name is spelled correctly and that you are connected to the server on which the file resides., SQL state S1009 in SQLConnect in C:\antoxrpt\index.php on line 7
didn't work

When using the system DSN, I get...

Warning: odbc_connect() [function.odbc-connect]: SQL error: [Microsoft][ODBC Microsoft Access 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., SQL state S1000 in SQLConnect in C:\antoxrpt\index.php on line 4
didn't work

The above errors were received when I was going through a web page. If I went to the machine and ran my file through batch PHP (i.e. c:\php\php.exe myfile.php), it would successfully connect to the database and give me the expected results.

I am assuming that it is a security issue, but I just can figure out what access is need for what user. I have seen articles about IUSR_servername user, but most of them say it is for IIS. I have tried it anyway without any success. I have tried both IUSR_ and IUSER_, since I have seen references to both.

One other thing, I copied the MS Access database to the local server and it worked fine that way too. The only issue is that the database is part of a vendor application and I need realtime access to it so I can't move it. I also can't install a web server on the other machine.

Any help would be greatly appreciated.

Feb 15 '08 #1
1 3609
5,821 Expert 4TB
Heya, VB Ace (VB/PHP Ace?).

I have recommended that a moderator move this thread to the Access forum. They may know what's going on here.
Jun 27 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

by: prodirect | last post by:
Hi all, I hope someone can help me. I've recently created a database and wanted to put it up on an ftp sight so that multiple people could access the same tables at the same time from different...
by: darcykahle | last post by:
I have stumbled upon an interesting issue with regard to compaction of an access frontend database which resides on a DFS target that utilizes FRS to mirror the sharepoint, and I was wondering if...
by: Russell Read [MSFT] | last post by:
Hi all, I am using VB script in ASP to access a MS Access database. This works fine until I want to access the same db placed on a file share. The code I am using is... 'create connection...
by: sonu | last post by:
I have following client side code which i have used in my asp.net project SummaryFeatured Resources from the IBM Business Values Solution Center WHITEPAPER : CRM Done Right Improve the...
by: Materialised | last post by:
I have written the following code as a test, (yes I know it is a resource hog). Basically it pulls all images out of a MySQL table. <?php $conn = mysql_connect(host, user, pass);...
by: samadams_2006 | last post by:
I'm having a problem in accessing a Microsoft Access Database in a VB.NET Web Application. It's so straight forward, I thought I'd walk you through all the details here: 1) I have a .NET Web...
by: Mike | last post by:
I'm having trouble accessing SQL2005 Standard Edition as a second instance of SQL Server where the first instance is SQL 2000 Enterprise Edition. I installed SQL 2005 as a named instance...
by: crombinator | last post by:
So here is the not so simple situation. In our work environment one entity controls access to servers. In our own webspace they have setup a user to access a mysql database. We brought in a...
by: le0 | last post by:
guys, this is my first time to deploy website to the server, but every time i access the page this error always appears. ...
by: Naresh1 | last post by:
What is WebLogic Admin Training? WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge required to effectively administer and manage Oracle...
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was proposed, which integrated multiple engines and...
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it so the python app could use a http request to get...
by: Arjunsri | last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and credentials and received a successful connection...
by: WisdomUfot | last post by:
It's an interesting question you've got about how Gmail hides the HTTP referrer when a link in an email is clicked. While I don't have the specific technical details, Gmail likely implements measures...
by: Matthew3360 | last post by:
Hi, I have been trying to connect to a local host using php curl. But I am finding it hard to do this. I am doing the curl get request from my web server and have made sure to enable curl. I get a...
by: Oralloy | last post by:
Hello Folks, I am trying to hook up a CPU which I designed using SystemC to I/O pins on an FPGA. My problem (spelled failure) is with the synthesis of my design into a bitstream, not the C++...
by: Carina712 | last post by:
Setting background colors for Excel documents can help to improve the visual appeal of the document and make it easier to read and understand. Background colors can be used to highlight important...
by: Ricardo de Mila | last post by:
Dear people, good afternoon... I have a form in msAccess with lots of controls and a specific routine must be triggered if the mouse_down event happens in any control. Than I need to discover what...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.