Toto je typická věc MySQL a lze ji obvykle obejít výběrem z tabulky odvozené, tj. namísto
FROM manager AS m2
použití
FROM (select * from manager) AS m2
Úplné prohlášení:
UPDATE manager
SET status = 'Y'
WHERE branch_id IN
(
select branch_id
FROM (select * from manager) AS m2
WHERE (branch_id, year) IN
(
SELECT branch_id, year
FROM branch_master
WHERE type = 'finance'
)
);