I have a ton of products in the products table. Each product has a product_specification. I need to update all the product_specification.document_type_id's to the value of '2'. Here's what I came up with while perusing SO:
update product_specifications
set product_specifications.document_type_id = 2
inner join products
on products.product_specification_id = product_specifications.id
where products.id in (
select p.id from products as p
inner join product_specifications as ps
on p.product_specification_id = ps.id
where p.store_front_id = 71
and ps.document_type_id = 1)
But this doesn't work...