Date Concat?
| From: | Rankin, Randy | Date: | Fri, 20 Sep 2002 12:07:19 +0000 |
| Subject: | Date Concat? | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-21866@lists.php.net to get a copy of this message | ||
I have two fields of type date in a MySQL table called training:
start_date
end_date
I can format the date using a select, for example
SELECT
DATE_FORMAT(start_date, '%M %d, %Y') as start_date,
DATE_FORMAT(end_date, '%M %d, %Y') as end_date
FROM training
This produces the following:
start_date: September 16, 2002
end_date: Sepetember 20, 2001
Based on the above, I would like to echo out something like this:
You will be in training September 16 - 20, 2002.
Is this possible?
Thanks,
Randy Rankin
-------------------------------------------
Randy Rankin, MCSE
Network Management Professional
IBM Global Services
randy.rankin@smith-blair.com
Phone:(870) 773-5148
Fax: (870) 773-5211