MySQL Forums
Forum List  »  Newbie

Re: Duplicate records plus update at the same time
Posted by: Rick James
Date: November 06, 2014 09:24AM

What? Are you trying to shift the IDs? That is not kosher.

BEGIN;
UPDATE tbl SET id = id + 1; -- UGH.
INSERT .. SELECT ..;
COMMIT;

Options: ReplyQuote


Subject
Written By
Posted
Re: Duplicate records plus update at the same time
November 06, 2014 09:24AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.