Re: Re[2]: [PHP] MySQL query
| From: | CPT John W. Holmes | Date: | Mon, 12 Jan 2004 20:38:27 +0000 |
| Subject: | Re: Re[2]: [PHP] MySQL query | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-174369@lists.php.net to get a copy of this message | ||
From: "Richard Davey" <rich@launchcode.co.uk>
> RD> SELECT whatever FROM table WHERE date_column_name BETWEEN '2004-01-09
> RD> 00:00:00' AND '2004-01-04 23:59:59'
>
> Actually sorry, inverse the seconds (put the 00:00:00 onto the lower
> date, the 4th) so it encompasses the whole period. You might actually
> be able to not even include the seconds, try it and see what happens.
What he said for my answer, too! ;)
I didn't even notice you had the later date first in your write-up. Ooops.
---John Holmes...