sqlite數據庫的update多表關(guān)聯(lián)更新語(yǔ)句,和其他數據庫有點(diǎn)小不一樣
update table1
set num1 = t2.num2
FROM table1 t1 INNER JOIN table2 t2
ON t1.id=t2.pid;
update table1
set num1 = (select num2 from table2 where table2.pid=table1.id)
where...
update table1
set num = 99
where table1.id=(select pid from table2 where table2.pid=table1.id)
聯(lián)系客服