Querying (and appending) only new records?

NewShoes

Registered User.
Local time
Today, 05:28
Joined
Aug 1, 2009
Messages
223
Hey all,

I am wondering is there is an easy(ish) way to query a seperate database and then compare it with my database, then only append records that are not already in my database?

I'll try an explain this a little better:

Database A has records: a b c d
My database has records: a b c

...is there a way I can append 'd' from Database A into one of my database tables?

Thanks,
NS
 
As long as you have a primary key set I don't see why you can't just do a straight forward append as any duplicates will be excluded anyway???
 
As long as you have a primary key set I don't see why you can't just do a straight forward append as any duplicates will be excluded anyway???

Humm..you might be right! However, is this the correct way to go about it? I'm thinking about how long it would take to do that every time the database is opened!

Thanks,
-NS
 
How many times do you need to run the append each day and how many records are we talking about each time?
 
It would be best to run the append a couple of times a day. The number of records in total would be in the region of 2600...however, the new records may only be around 5-10 at a time (when the append query is ran).

Thanks,
-NS
 
Then you won't have a problem doig it the way I suggested. Simply link the table to your DB, set up your append query and maybe attach it to a command button so you can turn the warning messages off.

I've just tested on one of my Databases with 8000 records and it took seconds so you wont be taking a big performance hit!!
 
Thanks!

The only issue that might crop up is that i'll be getting the data from an external source database via ODBC links. Will this cause a problem?
 
I don't think so, surely its along the same lines as using Access as a front end for the Database so should be fine.
 

Users who are viewing this thread

Back
Top Bottom