Re: Updating Date
| From: | (Richard Lynch) | Date: | Fri, 10 Nov 2000 00:25:55 +0000 |
| Subject: | Re: Updating Date | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-24590@lists.php.net to get a copy of this message | ||
In article <B6306FF5.D97%chris@create4u.com>, chris@create4u.com
(Christopher King) wrote:
> I have a date field in all the records in a table. How do I advance the date
> one day in every record in one fell swoop.
In PostgreSQL:
update TABLE set somefield = somefield + '@ 1 day'
You'll have to find out how to express '@ 1 day' in MySQL or whatever
database you are using. Search the MySQL docs for "interval" or mess with
that todays() function maybe.
--
Richard Lynch | If this was worth $$$ to you, buy a CD
US Customer Support Director | from one of the artists listed here:
Zend Technologies USA | http://www.L-I-E.com/artists.htm
http://www.zend.com | (this has nothing to do with Zend,
duh!)