R
Ron Le Blanc
I have an Access 2003 database that has several tables in it that are all
related to a client table and have the cascade delete enabled.
I wish to delete all clients that have not been seen for two years or more.
A "meal" table contains the last visit date.
The idea is to find all clients who have not been seen in two or more years.
The data sheet view shows that the correct clients are selected. However,
when I try to run the delete query it says it cannot delete the records. The
"client" table is the table to which all other tables are related to and
have the cascade delete option on.
The SQL generated is:
DELETE client.*, client.MasterID, meals.LastVisit, client.f_name,
client.l_name
FROM client INNER JOIN meals ON client.MasterID = meals.MasterID
WHERE (((meals.LastVisit)<Date()-730));
Does anyone have an idea as to why this does not work and what might be done
to make it work??
Thanks!
related to a client table and have the cascade delete enabled.
I wish to delete all clients that have not been seen for two years or more.
A "meal" table contains the last visit date.
The idea is to find all clients who have not been seen in two or more years.
The data sheet view shows that the correct clients are selected. However,
when I try to run the delete query it says it cannot delete the records. The
"client" table is the table to which all other tables are related to and
have the cascade delete option on.
The SQL generated is:
DELETE client.*, client.MasterID, meals.LastVisit, client.f_name,
client.l_name
FROM client INNER JOIN meals ON client.MasterID = meals.MasterID
WHERE (((meals.LastVisit)<Date()-730));
Does anyone have an idea as to why this does not work and what might be done
to make it work??
Thanks!