RE: [PHP-DB] Date Subtraction

2002-08-21 Thread Ryan Jameson (USA)
PM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: Re: [PHP-DB] Date Subtraction hi, hey you are bang on target. It did solve my problem. Thanks a lot, Manoj On Wed, 21 Aug 2002 [EMAIL PROTECTED] wrote : > >if you really just want yesterday, i use date("Y-m-d", time() -

Re: Re: [PHP-DB] Date Subtraction

2002-08-21 Thread Manoj Japher
hi, hey you are bang on target. It did solve my problem. Thanks a lot, Manoj On Wed, 21 Aug 2002 [EMAIL PROTECTED] wrote : > >if you really just want yesterday, i use date("Y-m-d", time() - 86400); > >that way you'll get the correct info, no matter if it spans >weeks, months, >years etc

RE: [PHP-DB] Date Subtraction

2002-08-21 Thread Hutchins, Richard
Oh, in MySQL, there's also DATE_SUB(). Forgot to mention that one. Rich -Original Message- From: Hutchins, Richard [mailto:[EMAIL PROTECTED]] Sent: Wednesday, August 21, 2002 2:40 PM To: 'Manoj Japher'; [EMAIL PROTECTED] Subject: RE: [PHP-DB] Date Subtraction Manoj, J

Re: [PHP-DB] Date Subtraction

2002-08-21 Thread Jason Wong
On Thursday 22 August 2002 02:23, Manoj Japher wrote: > hi, > Is there any way I can get previous day's date, like we get > current > date by using getdate() or date() function. I mean is there some > in-built function in PHP which can subtract date to give me > yesterday's date. > I am curren

RE: [PHP-DB] Date Subtraction

2002-08-21 Thread Hutchins, Richard
Manoj, Just a couple of thoughts: First, I know this particular topic has been discussed here recently, so you might want to search the archives for more exhaustive information. Second, if you're using MySQL, check out the functions DATE_ADD() and MOD(). They're MySQL functions, so you'll have t