Mike Yearwood
Toronto, Ontario, Canada
General information
Category:
Coding, syntax & commands
Environment versions
Network:
Windows 2000 Server
Hi Colin
Is there a product ID or something unique in each record? If so, index the view on that unique ID. You could use that index to update the view with data from the csv. Select the matching records from the CSV, update the view. Then select the unmatching records from the csv, append them into the view. You might even want to delete records from the view that are not in the csv. Then after all of that issue a single tableupdate.
That should result in the table matching the csv. If you need to reduce the number of updates, you could check if something in the csv is different from the view.
select * from csv where csv.ID = view.ID and (csv.price <> view.price OR csv.description <> view.description)
HTH
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only