salix/db/versions/.archive/10748-navyRose/01-SecondScript.sql

8 lines
139 B
SQL

UPDATE vn.ticket t
JOIN (
SELECT id, ticketFk__
FROM vn.cmr
WHERE ticketFk__
) sub ON sub.ticketFk__ = t.id
SET cmrFk = sub.id;