5 replies
by john_wills
by john_wills
Put the SELECT for the table you want to read in a string and use that string as parameter when opening a RecordSet:
Set ReadTable = CurrentDb().OpenRecordset(ReadSQL)
ReadTable.MoveFirst ' MoveNext the next time
DestTableName = ReadTable.Fields(0) 'I here suppose that the destination table name is in the first column; the columns to be copied to the destination are found in their own field positions.
SQLString="INSERT INTO " & DestTableName & "() VALUES('" & & "','" & ... & ");"
DoCmd SQLString
Make this into a loop.
by johngreer
It's been so long I felt I owe you the points.
Sorry, but I didn't try your answer.
by johngreer
John,
Can you give me an example?
by johngreer
This discussion is closed to new replies.
Trending Software posts
Sort by Trending