Deekshith Shetty Deekshith Shetty - 3 months ago 26
SQL Question

i want to update table multiple row using IN statement

UPDATE domain_information
SET company_name = 'aaa'
where id in (select id from domain_information where company_name = 'bbb')

Answer

Your WHERE condition can be simplified like

UPDATE domain_information
SET company_name = 'aaa'
WHERE company_name = 'bbb';