Re: format date field

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



SELECT DATE_FORMAT('open', '%m-%d-%Y') FROM your_table_name;

-- 
itoctopus - http://www.itoctopus.com
""Mike Ryan"" <miker@xxxxxxxxxxxxxx> wrote in message 
news:42.A3.45184.F9F64564@xxxxxxxxxxxxxxx
>I am reading in a date field from a mysql database the field on the screen
> shows up as 2007-05-01  on the screen I would like the field to show
> 05-01-2007  currently I am issueing the following command  print
> $row['open']; how can I format this field???
>
> while I am at it how can I accept the date field as 05-01-2007; 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux