Importing records from oue table to another

  • Thread starter Thread starter Rob
  • Start date Start date
R

Rob

Hi, Using Access 2000.

I have lost some records in table within a large database (mdb file),
however I'm lucky enough (I think) to have a back up of the whole database
from a week or so ago.

My problem is that I want to update the working database table with records
from the backup without overwriting the whole database. I would also only
like to add records from the backup to the original table where the records
don't exist (i.e. they weren't lost).

Do I do this with code or can I do via the Table view in the mdb?

Has anyone some sample code or instructions? There are only 8 fields, but
12,000 records.

Thanks, Rob
 
Rob said:
Hi, Using Access 2000.

I have lost some records in table within a large database (mdb file),
however I'm lucky enough (I think) to have a back up of the whole
database from a week or so ago.

My problem is that I want to update the working database table with
records from the backup without overwriting the whole database. I
would also only like to add records from the backup to the original
table where the records don't exist (i.e. they weren't lost).

Do I do this with code or can I do via the Table view in the mdb?

Has anyone some sample code or instructions? There are only 8
fields, but 12,000 records.

Thanks, Rob

If the target table has a primary key you should be able to just link to the
backup table and then use it in an Append query to insert its records into
the target table.

As long as the append query is not set up to use transactions it should only
insert the rows that the target table is missing discarding any duplicates.

I recommend testing such a thing on a copy of your file of course.
 
A Find UnMatched query will help you to see which records are in one table
and not in the other. You have all my sympathy Rob. What a nightmare!
Evi
 
Back
Top