Re: calculating datetime

From: Date: Sun, 31 Aug 2003 17:56:27 +0000
Subject: Re: calculating datetime
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-161314@lists.php.net to get a copy of this message
* Thus wrote Ryan A (r@no7.biz): > Hi, > I have a datetime field in my table, i want to enter a datetime 1 day,1 hour > and 10 mins into the future from today/the present, how do i calculate that? Your using mysql right? Just use mysql's date_add function: date_add(now(), interval '1 1:10:0' DAY_SECOND) Couldn't get any simpler :) http://www.mysql.com/doc/en/Date_and_time_functions.html Curt -- "I used to think I was indecisive, but now I'm not so sure."

« previous php.general (#161314) next »