Reputation: 85
I am trying to update a record in one table that is dependent on a row in another table. Something like this:
UPDATE product_description SET description="" /* Nothing! */
WHERE product.product_id=product_description.product_id AND product.manufacturer_id=1
Upvotes: 0
Views: 59
Reputation: 204784
UPDATE product_description
JOIN product ON product.product_id = product_description.product_id
SET description = "" /* Nothing! */
WHERE product.manufacturer_id = 1
Upvotes: 3