Help for this page

Select Code to Download


  1. or download this
    SET @a:=10;
    UPDATE 
        table
    ...
        table.ID=@a:=@a+1
    WHERE
        table.ID=5
    
  2. or download this
    #!/usr/bin/perl --
    use strict;
    ...
    [[1, "bar"], [2, "bar"], [10, "FEE"], [11, "FII"], [5, "FOO"]]
    { rowsaffected => 1 }
    [[1, "bar"], [2, "bar"], [10, "FEE"], [11, "FII"], [12, "FOO"]]