The steps would be

  1. copy the record to temp table
  2. modify the column you would like to
  3. copy back to the original table
CREATE TEMPORARY TABLE tmp SELECT * FROM table_1 WHERE column_1 = 111; 
UPDATE tmp SET column_1 =1 WHERE column_1 = 111; 
INSERT INTO table_1 SELECT * FROM tmp WHERE column_1 = 1;

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes:

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>