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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using Update Query to update table values

Status
Not open for further replies.

SHAWTY721

Programmer
Aug 16, 2007
116
US
I have a database that contains some values that I need to be updated if they match old codes that need to be updated. I have the values in two tables. One table contains all the values possible from the imported data. While the other table just includes the 4 digit codes for the old value and the new value.

I am trying to write a Update query that will replace the old values with the new values needed for lookup purposes used on the form.
 

May be
Code:
UPDATE TableOfCodes As N Inner Join TableOfNewAndOldCodes As A On
       N.CodeField = A.OldCodeField
SET N.CodeField = A.NewCodeField;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top