>The solution would be similar to the one I showed you. To delete the records in the original tables, you can save the record position, copy 800 records as I showed you, and then go back and write an interior loop to delete the 800 records in the table. Another possibility is to delete with a subquery. Once you have the records in the result, you can:
>
>
>delete from OriginalTable where PrimaryKey in;
> (select PrimaryKey from CopiedRecords)
>
>
>You should use a primary key for each table; in this case, it will help you to detect the records in the original table, and delete them quickly.
Hi Hilmar,
In another thread, which almost exausted me, he told, that he doesn't have PK in his tables, since tables are produced from Excel. So, I'm thinking about
delete from Original where recno() in (select RecNum from CopiedRecords). That's from the top of my head, I hadn't tried. Do you think, it would work? Otherwise he needs a loop, but I do not like this idea.
If it's not broken, fix it until it is.
My Blog