/ Published in: MySQL
Expand |
Embed | Plain Text
SET @id := 0; UPDATE users SET id = (@id := @id + 1) WHERE id = 0;
You need to login to post a comment.
hlubek on 01/29/09
2 people have marked this snippet as a favorite
SET @id := 0; UPDATE users SET id = (@id := @id + 1) WHERE id = 0;
You need to login to post a comment.