Hi,
I’m trying to get a faster method for Downloading a web based “SQL server” tables data to a local table for backup, currently i’m using:
Sub ConnectDB()
Set oConn = New ADODB.Connection
oConn.Open “Driver={SQL Server};” & _
“Server=www.somewhere.com;” & _
“Address=???.???.???.???,1433;” & _
“Network=DBMSSOCN;” & _
“Database=????????;” & _
“Uid=????????;” & _
“Pwd=??????;”
End Sub
To connect then
SQL1 = “Select * from Remote_Table”
rs123.Open SQL1, oConn
Set rs22 = CurrentDb.OpenRecordset(“Local_Table”)
rs123.MoveFirst
Do While Not rs123.EOF
DoEvents
rs22.AddNew
rs22![Field1] = rs123![Field1]
rs22![field2] = rs123![field2]
etc
rs22.Update
rs123.MoveNext
Loop
This is very slow. In a perfect scenario I just want to Append the [Remote_table] to a preformated blank [Local_table], any suggestions???
At the moment it can take an Hour to Download.
With thanks in Antici Graliv