Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Updating the changed records

Status
Not open for further replies.

flaviooooo

Programmer
Feb 24, 2003
496
FR
Hi,

I'm in need of your opinion. I have a table with customers, that contains about 30 columns.
Every week I need to import all of our customer records into access, and then update the table so that we have the latest data for every customer.

To append the new customers is easy, just an append query of records where the keyfields don't match.

But how can I run a query that will update all changed customer data? The only solution I can think about is just running an update query on ALL customers, but this can become quite time consuming in time I guess.
Since the table has about 30 columns, it's not very easy to write a query that will check all the fields for changes (and every column might contain a change)

Any thoughts?
 
I think running an update on all records is probably going to be faster than trying to test each record (and 30 columns within each record) prior to updating.

In similar situations, I've either used that (without any performance testing, though, so I can't say for sure), unless I've had the possibility of setting a flag on each changed record in the system I've imported from (in Access, using for instance the before update event of a form to alter a flag when a record is changed).

Roy-Vidar
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top