Update sql with multiple tables not working

I am trying to execute the following query within a SQL server 2005 express database:

update
   orders,
   prices
set
   orders.UnitPriceLessTax=prices.RRPLessTax
where
   orders.itemrefid=prices.itemrefid
   AND orders.itemrefid=27705

Unfortunately I get a syntax error near the comma.

Help!
mike99cAsked:
Who is Participating?
 
Patrick MatthewsCommented:
UPDATE orders
SET orders.UnitPriceLessTax=prices.RRPLessTax
FROM orders, prices
WHERE orders.itemrefid = prices.itemrefid AND orders.itemrefid = 27705
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.