syntax error date_format

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Johan den Boer

    #1

    syntax error date_format


    Hi,

    What is wrong with this code ?

    SELECT DATE_FORMAT( myfield, GET_FORMAT( TIMESTAMP, 'EUR' ) ) FROM T_TABLE;

    regards

    Johan


  • Aggro

    #2
    Re: syntax error date_format

    Johan den Boer wrote:
    [color=blue]
    > Hi,
    >
    > What is wrong with this code ?
    >
    > SELECT DATE_FORMAT( myfield, GET_FORMAT( TIMESTAMP, 'EUR' ) ) FROM T_TABLE;[/color]

    GET_FORMAT() is available as of MySQL 4.1.1. Perhaps you have older
    version of MySQL?


    Try something like:
    SELECT DATE_FORMAT(myf ield, '%a %M %Y %r') FROM T_TABLE;

    Comment

    • Aggro

      #3
      Re: syntax error date_format

      Johan den Boer wrote:
      [color=blue]
      > Hi,
      >
      > What is wrong with this code ?
      >
      > SELECT DATE_FORMAT( myfield, GET_FORMAT( TIMESTAMP, 'EUR' ) ) FROM T_TABLE;[/color]

      GET_FORMAT() is available as of MySQL 4.1.1. Perhaps you have older
      version of MySQL?


      Try something like:
      SELECT DATE_FORMAT(myf ield, '%a %M %Y %r') FROM T_TABLE;

      Comment

      Working...