Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VB + Multiple Access Databases = Nightmare?
Message
From
24/07/2001 13:09:55
Jason Dalio
Northern Interior Regional Health Board
Prince George, British Columbia, Canada
 
 
To
24/07/2001 10:35:54
General information
Forum:
Visual Basic
Category:
Database DAO/RDO/ODBC/ADO
Miscellaneous
Thread ID:
00533754
Message ID:
00534511
Views:
12
Efficeincy is funny that way. I'm going to mention the way that I would do what you are trying to accomplish and then maybe someone will chime in and tell us both if their is a better way.

1st Example: (modification of the first code I sent you)
rst1.open "SELECT tbl1.ID, tbl1.SomeField FROM tbl1;"
with rst1
do wile not .eof
conConnection.execute "INSERT INTO tbl2 (tbl2.ID, tbl2.DataField) VALUES " _
& "(" & rst1("tbl1.ID") & ", '" & rst1("tbl1.SomeField") & "');"
.movenext
loop
end with
rst1.close
set rst1 = nothing

So you can see they we just open the first recordset, move through it one by one and each time issues an INSERT into our second recordset (note the conConnection is an ADODB.Connection object that points at the database containing the tables you want to export to).
Previous
Reply
Map
View

Click here to load this message in the networking platform