Link to home
Start Free TrialLog in
Avatar of Aleks
AleksFlag for United States of America

asked on

Syntax for query to update table

I am trying to update the value of table a.EID of that of table b.id, below is the query with the join, but I seem to have a syntax error, any help is appreciated.

UPDATE dbo.Users a
SET a.EAD = b.id
INNER JOIN addresses AS b ON b.userid = a.userid 
WHERE b.UserType = 'employer' AND description = '12'

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of Ryan Chong
Ryan Chong
Flag of Singapore image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Aleks

ASKER

It worked, thanks!