Delete from one table but not another

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I wanted to delete records from my master list table using a field called
DELETED and store in a query.
 
That's a very common way of representing inactive data - its advantage is
that you can undelete such records. The field can be a Yes/No. To implement
this, you need to refer to your data only through queries, not directly to
the table. To work on not deleted records, use the query:
SELECT * FROM [put table name here] WHERE NOT DELETED
TO work on deleted records, use the query:
SELECT * FROM [put table name here] WHERE DELETED
You can then use these two queries as if they were two tables, one with
active data, the other with inactive.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top