Am I on the right track with taking data from one db and putting it into another

D

Dave

Here is my synatx with the error:

Error Type:
Microsoft JET Database Engine (0x80004005)
Could not find file 'C:\WINNT\system32\NTS.mdb'.
/FPSite/service/LMS/NTS/TestUPload.asp, line 18


<%

set ConnStr1 = Server.CreateObject("ADODB.Connection")
RelativePath = "../fpdb/NTS.mdb"
AbsolutePath = Server.Mappath(RelativePath)
ConnStr1.Provider = "Microsoft.Jet.OLEDB.4.0"
connStr1.Open = "Data Source="&AbsolutePath&""


set rs = Server.CreateObject("ADODB.Recordset")
RelativePath = "../fpdb/LMS.mdb"
AbsolutePath = Server.Mappath(RelativePath)
ConnStr = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source="&AbsolutePath&""
mysql = "SELECT * INTO TBackup IN 'NTS.mdb' FROM ResultsCrit" ---- Line
18
rs.open mysql, ConnStr

%>
 
M

MGFoster

Dave said:
Here is my synatx with the error:

Error Type:
Microsoft JET Database Engine (0x80004005)
Could not find file 'C:\WINNT\system32\NTS.mdb'.
/FPSite/service/LMS/NTS/TestUPload.asp, line 18


<%

set ConnStr1 = Server.CreateObject("ADODB.Connection")
RelativePath = "../fpdb/NTS.mdb"
AbsolutePath = Server.Mappath(RelativePath)
ConnStr1.Provider = "Microsoft.Jet.OLEDB.4.0"
connStr1.Open = "Data Source="&AbsolutePath&""


set rs = Server.CreateObject("ADODB.Recordset")
RelativePath = "../fpdb/LMS.mdb"
AbsolutePath = Server.Mappath(RelativePath)
ConnStr = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source="&AbsolutePath&""
mysql = "SELECT * INTO TBackup IN 'NTS.mdb' FROM ResultsCrit" ---- Line
18
rs.open mysql, ConnStr

%>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Obviously, the relative path is incorrect. Use the complete path to the
..mdb file.

Explanation: This "../fpdb/LMS.mdb" means use the parent directory of
the current working directory. The error shows that the current
directory is C:\WinNT\system32. You need to either change the current
directory (I can't imagine how from an ASP page), or give the complete
path to the db.
--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBQxYQ6oechKqOuFEgEQJ5UACg3EMfelLDQRH0ClA4TxVdC2avqX4AoNjh
nxygI9u/2AWxlFyb6HEfN41r
=ZlDc
-----END PGP SIGNATURE-----
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top