0
查詢時發生此錯誤。我試圖通過ID重新排序表。重新排序表時查詢錯誤
我在想這個問題可能是由於;在查詢中籤
Error: ER_PARSE_ERROR: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'UPDATE users SET id=(@newid:[email protected]+1) ORDER BY id' at line 1
代碼:
SET @newid=0;
UPDATE users
SET id = (@newid:[email protected]+1)
ORDER BY id