Multiple database connections

Results 1 to 3 of 3

Thread: Multiple database connections

  1. #1
    Paul Farnell Guest

    Default Multiple database connections

    I need to insert all the records from one Access database into another, but if I try and open both connections at once and then run a loop to Insert each record from the first database into the second I get an &#039;Internal Server Error&#039;. All of my coding is being done using ASP, connecting to two ODBC sources (Access databases) using ADO.<BR><BR>Does anyone have any solutions to this, or a different way I could do this? Please tell me a VBScript command which does this automatically!<BR><BR>Any ideas would be most useful.<BR><BR>Paul.

  2. #2
    Tim Snyder Guest

    Default RE: Multiple database connections

    Open first connection<BR> Store data in variable<BR>Close connection<BR>Open Second Connection<BR> Put data in table<BR>Close connection

  3. #3
    Join Date
    Dec 1969

    Default RE: Multiple database connections

    One approach might be to attach the table(s) from the old database to the new one and then...<BR><BR>sql = "INSERT INTO NEWTABLE SELECT * FROM OLDTABLE"<BR>cn.Execute sql<BR><BR>Repeat this for each table that you need to populate.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts