-
-Original Message-
From: Paul DuBois [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, December 04, 2002 4:28 PM
To: Chris Kay; [EMAIL PROTECTED]
Subject: Re: Date caculation is a select query
At 11:03 +1100 12/4/02, Chris Kay wrote:
>How would I go ab
Chris,
>would someone mind giving me a example query
>where I would add 21 days to a datetime field
Mysql, query
mysql> create table member (
-> dt datetime );
Query OK, 0 rows affected (0.09 sec)
mysql> insert into member values ('1991-06-22 14:00:00');
Query OK, 1 row affected (0.05 sec)
At 11:03 +1100 12/4/02, Chris Kay wrote:
How would I go about grabbing all records where a field is older than 21
days and set to a certain status.
Dunno what you mean by "set to a certain status", but the other part will
be:
WHERE datetime_field < DATE_SUB(NOW(),INTERVAL 21 DAY)
I tried INT
How would I go about grabbing all records where a field is older than 21
days and set to a certain status.
I tried INTERVIAL 21 Day but I cant seem to get it to work
Field in the database is datetime
Am I doing something wrong? Or is there a easier way to do this, would
someone mind giving me a