Hi ,
I want to use this for archives...What is the easiest way to do this ?
Is the DELETE from the source and ADDNEW to the new table is the way to do
it ? It must have a easiest way.
Tks...
Well... add first, THEN delete! Otherwise you're throwing away the
record before you add it!
I'd suggest an Append query to add the new record, followed by a
Delete query to delete it. Wrap both in a Transaction to ensure that
the delete only happens if the addition succeeds (see "Transaction" in
the online help).
Unless your table is many hundreds of thousands of records, and you
have demonstrated performance problems, you may want to instead just
add an indexed yes/no field Archived to the table. Base your form on a
query displaying only the records where this is False (or of course
True to see only archived records). Just checking the checkbox will
"archive" the record with no code, no queries, and no effort.
John W. Vinson[MVP]