This topic is locked

Hiding a record after a date

8/10/2008 1:38:31 PM
PHPRunner General questions
author

I tried searching the forum for this with no luck.
I would like to hide a record after 5 days of a start date field. Is this doable in phprunner or is it something I have to set in the database?
Jim

T
thesofa 8/10/2008

edit the sql query to exclude records older than 5 days.

500441 8/10/2008

edit the sql query to exclude records older than 5 days.


Great, I'm not sure how I would write this. I want it to be 5 days after "FromDate" field in the data base.
Thanks for the help!!

T
thesofa 8/10/2008

where Now() - FromDate >5

500442 8/10/2008

where Now() - FromDate >5


Thank you for the reply. I tried it but I seem to be still getting on my records. Here is how I have the querry

SELECT

Category,

Description,

EventID,

FromDate,

FromTime,

Image,

Location,

`Map`,

Note,

Price,

`Class`,

ToDate,

ToTime,

Code,

Days,

`online`,

registration_fee,

`Fax Form`

FROM events1

WHERE Now() - FromDate >5


Am I putting that in correctly?

T
thesofa 8/10/2008

maybe try

where (Now() - FromDate) >5