CtronX (cyclotron) wrote in mysql,
CtronX
cyclotron
mysql

Updating multiple rows

I need to update several rows. Each row has a date column with data like "2004-03-02". I want to change the year to 2007 for all the rows in my data base without changing the month and the day.

Basically change a date like "2004-03-02" to "2007-03-02"

Is there a way to do this do this all in one update query?
Subscribe
  • Post a new comment

    Error

    default userpic
    When you submit the form an invisible reCAPTCHA check will be performed.
    You must follow the Privacy Policy and Google Terms of use.
  • 9 comments