I have two ADODB recordsets set up connected to two different databases one is Access 97 the other SQl Server 6.5.
How can I transfer data from one recordset to the other, mainly SQL 6.5 to Access 97 using VB6 Code.
Printable View
I have two ADODB recordsets set up connected to two different databases one is Access 97 the other SQl Server 6.5.
How can I transfer data from one recordset to the other, mainly SQL 6.5 to Access 97 using VB6 Code.
Logic:
rsAxs = recordset of access data
cnSQL = connection to SQL server
do until rsAxs.eof = true
cnSQL.execute "Insert into mytable (field1, field2) Values (" & rsAxs.Fields("Field1").value & ", " & rsAxs.fields("Field2").value & ")"
rsAxs.movenext
loop