Automatically Updating Fields based on values in another table.

S

Strugglin'

We have several dbases, with tables making references
to "Inventory Numbers". We have now gone with a new
numbering scheme in our facility, and all these inventory
numbers need to be changed. I have an Excel spreadsheet
with two columns: Old Inventory Number and New Inventory
Number. If I were to import this table into the existing
databases, how can I automate the process of updating the
related fields on the other tables?
 
P

Pieter Wijnen

Pretty Simple if you don't have foreign keys connected to the inventory
number
Query (replace tables & Fields as required):

UPDATE INVENTORY A INNER JOIN NEWINVENTORY B ON A.INVENTORYID = B.OLDNUM SET
A.INVENTORYID = B.NEWNUM

HTH

Pieter
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top