in reply to Re: Perl and MySQL update question
in thread Perl and MySQL update question

MySQL is implied by the title. Moreover, you're assuming that the date field is a textual one, which could not be the case, and the OP is asking for an int field. andreas1234567's approach seems more robust.

Flavio
perl -ple'$_=reverse' <<<ti.xittelop@oivalf

Io ho capito... ma tu che hai detto?

Replies are listed 'Best First'.
Re^3: Perl and MySQL update question
by sids (Acolyte) on Nov 19, 2007 at 14:06 UTC
    Missed the (obvious) MySQL reference in the title, sorry.
    The data in the date field is in the format dd:mm:yyyy, which indicates that it is _not_ a datetime field (so it must be a text field). In this case andreas1234567's approach would not work.

    --
    Ignorance killed the cat, curiosity was framed.
      I was referring to the fact that the target was asked to be of integer type, but I see your point about the source. Probably a merge between your solution and andreas1234567's would do.

      Flavio
      perl -ple'$_=reverse' <<<ti.xittelop@oivalf

      Io ho capito... ma tu che hai detto?