什么会导致以以下开头的错误 1175:You are using safe update mode and you tried to update a table without a WHERE that uses a KEY column...
。我的问题是我确实包含了一个WHERE
带有键列的子句:WHERE a.a_id = b.b_id
a_id
并且b_id
是各自表中唯一的键列。
START TRANSACTION;
UPDATE table_a a, table_b b
SET a.update_me = b.update_from_me
WHERE a.a_id = b.b_id;
SELECT * FROM a;
Run Code Online (Sandbox Code Playgroud)
我错过了什么?