What's wrong with this syntax?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Matt Bradley

    #1

    What's wrong with this syntax?

    Can anybody tell what is wrong with this syntax? I'm trying to move some
    dates from 9 months ago into the present month

    UDPATE tbl_name SET datetime = DATE_ADD(dateti me, INTERVAL 9 MONTH)
    WHERE MONTH(datetime) = '3';


    --
    Matt Bradley
    "Myths which are believed in tend to become true"
    -George Orwell
  • Aggro

    #2
    Re: What's wrong with this syntax?

    Matt Bradley wrote:
    [color=blue]
    > Can anybody tell what is wrong with this syntax? I'm trying to move some
    > dates from 9 months ago into the present month
    >
    > UDPATE tbl_name SET datetime = DATE_ADD(dateti me, INTERVAL 9 MONTH)[/color]

    One error is that you should use UPDATE instead of UDPATE

    Comment

    • Matt Bradley

      #3
      Re: What's wrong with this syntax?

      Aggro wrote:[color=blue]
      > Matt Bradley wrote:
      >[color=green]
      >> Can anybody tell what is wrong with this syntax? I'm trying to move
      >> some dates from 9 months ago into the present month
      >>
      >> UDPATE tbl_name SET datetime = DATE_ADD(dateti me, INTERVAL 9 MONTH)[/color]
      >
      >
      > One error is that you should use UPDATE instead of UDPATE[/color]

      Oh gawd! Cheers.


      --
      Matt Bradley
      "Myths which are believed in tend to become true"
      -George Orwell

      Comment

      Working...