Re: Date_Format Question

From: Date: Thu, 30 Aug 2001 04:18:47 +0000
Subject: Re: Date_Format Question
References: 1 2  Groups: php.db 
Request: Send a blank email to php-db+get-11977@lists.php.net to get a copy of this message
----- Original Message ----- From: boclair <boclair@bigpond.net.au> To: <jeff@webdesigns1.com>; PHP-DB <php-db@lists.php.net> Sent: Thursday, August 30, 2001 1:09 PM Subject: Re: [PHP-DB] Date_Format Question > > ----- Original Message ----- > From: Jeff Oien <jeff@webdesigns1.com> > To: PHP-DB <php-db@lists.php.net> > Sent: Thursday, August 30, 2001 11:07 AM > Subject: [PHP-DB] Date_Format Question > > > > I have a date like this in date format in MySQL > > 2001-08-29 > > > > and I want it to say > > August 29, 2001 > > > > I tried this and it didn't work. > > select date_format('creation_date', '%b %D, %Y') from Chart_Users; > > Perhaps > > $result= "SELECT date_format(creation_date,'%b%D,%y') AS created FROM > db.Chart_Users"; > > Then from the array $myrow['created'] instead of > $myrow['creation_date'] The formatting you need is %M %d, %Y. Careless of me. Tim Morris

« previous php.db (#11977) next »