|
 |
access_asp thread: Linked Access Tables with ASP
Message #1 by "dan konigsberg" <dkonigs@e...> on Sun, 3 Mar 2002 23:46:50
|
|
Hi all, I have been unable to find any info about this question
anywhere. Hopefully, someone out there has figured out a way to deal
with this issue.
I am developing an application using a workstation and a development
server. I've come to a point in my application where I'd really like to
be able to split the data among different .mdb databases. In Access
2000, I opened up my database (it's on the server, on my G: drive) and in
that database, I linked to a table in another database on the same hard
drive -- again, to my workstation it is the G: drive, however *to the
server* it is C:. In other words, If I were to sit down at the server,
I'd be able to access both these databases in a directory on the C drive,
but since I am working on a networked machine, to me and to MS Access it
is G:.
Now, that works fine when I'm using the database using the MS Access
front end. I open it up and since I'm using my workstation, it finds the
linked database at G:\Application\database2.mdb. I can open up the
linked table in my current database without a problem. However, if I use
ASP to query the linked table, I get the following error:
'G:\Application\Database2.mdb' 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.
What I think is happening here is that the first db (Database1) has the
path to the second database stored statically. Therefore, when I use my
ASP web-based application to access the linked table, it looks for it in
the stored path (G:\Application\Database2.mdb) instead of on the local
hard drive where it is really located (C:\Application\Database2.mdb)
Now, finally, here is my question. Does anybody know of a way to use
ASP/ADO/ODBC or whatever to tell an access database the path to its
linked tables? Is there code that I could run every time a user logs in
to tell the database where the linked databases are?
If you have an answer to this question, I will love you forever.
Thanks so much,
Dan Konigsberg
Message #2 by "Ken Schaefer" <ken@a...> on Mon, 4 Mar 2002 11:05:59 +1100
|
|
How about using UNC paths?
Tell Access that the linked database is on \\server\share\db1.mdb
That path will be valid no matter which machine you are on.
Cheers
Ken
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
From: "dan konigsberg" <dkonigs@e...>
Subject: [access_asp] Linked Access Tables with ASP
: Hi all, I have been unable to find any info about this question
: anywhere. Hopefully, someone out there has figured out a way to deal
: with this issue.
:
: I am developing an application using a workstation and a development
: server. I've come to a point in my application where I'd really like to
: be able to split the data among different .mdb databases. In Access
: 2000, I opened up my database (it's on the server, on my G: drive) and in
: that database, I linked to a table in another database on the same hard
: drive -- again, to my workstation it is the G: drive, however *to the
: server* it is C:. In other words, If I were to sit down at the server,
: I'd be able to access both these databases in a directory on the C drive,
: but since I am working on a networked machine, to me and to MS Access it
: is G:.
:
: Now, that works fine when I'm using the database using the MS Access
: front end. I open it up and since I'm using my workstation, it finds the
: linked database at G:\Application\database2.mdb. I can open up the
: linked table in my current database without a problem. However, if I use
: ASP to query the linked table, I get the following error:
:
: 'G:\Application\Database2.mdb' 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.
:
: What I think is happening here is that the first db (Database1) has the
: path to the second database stored statically. Therefore, when I use my
: ASP web-based application to access the linked table, it looks for it in
: the stored path (G:\Application\Database2.mdb) instead of on the local
: hard drive where it is really located (C:\Application\Database2.mdb)
:
: Now, finally, here is my question. Does anybody know of a way to use
: ASP/ADO/ODBC or whatever to tell an access database the path to its
: linked tables? Is there code that I could run every time a user logs in
: to tell the database where the linked databases are?
:
: If you have an answer to this question, I will love you forever.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Message #3 by "dan konigsberg" <dkonigs@e...> on Mon, 4 Mar 2002 00:23:19
|
|
I forgot to mention one detail... I develop the application on my server
here, but the application actually runs on a different webhost. I need a
solution that will work on my development network and on the network on
which it actually runs live.
Thanks for your help,
Dan
> How about using UNC paths?
> Tell Access that the linked database is on \\server\share\db1.mdb
> That path will be valid no matter which machine you are on.
>
> Cheers
> Ken
|
|
 |