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

Update column from column in another table

Status
Not open for further replies.

Bell1991

Programmer
Aug 20, 2003
386
US
I have two tables:

TableA
name
source
TableB
name
source

I want to update TableA column source with TableB coulmn source..

Please help!

Thanks
 
Try this:

UPDATE TABLEA SET TableA.source=TableB.source FROM TableB
WHERE TableA.name=TableB.name

-DNG
 
UPDATE TableA INNER JOIN TableB ON TableA.name=TableB.name
SET TableA.source=TableB.source;

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top