PDA

View Full Version : delte records depending on date


scroots
11-02-2002, 01:28 PM
how can i delete records from an access database only if a certain field has a date in it which is before todays. the dates are in the format 01/10/02 etc.

its for a project and i don`t want to have records which are no longer needed.

thanks in advance
scroots

Mhtml
11-02-2002, 01:31 PM
Sql_Delete = "DELETE FROM Table_Name WHERE Field_with_Date ="<date()

whammy
11-02-2002, 05:32 PM
DELETE FROM Table_Name WHERE Field_with_Date < #" & Date() & "#"

Mhtml
11-02-2002, 11:41 PM
That's right, you told me that just the other day..
Sorry Scroots :)

scroots
11-03-2002, 01:07 PM
its ok, i haven`t got to trying it out yet

scroots