How do I subtract records in one table from another table

J

Jolly

Until I changed to Access, I had been using Paradox to
maintain a mailing list of about 17,000 names that in
generated about 3 times a year. When I got a returned
letter, I marked a field indicating that address was no
longer valid. I then used a query to remove those records
and put them in another table named "No Mail". Paradox has
a feature that allows me to subtract the records in "No
Mail" from the new table that I build by importing the
customer info. I can't find that feature in Access. How
can I subtract the records in table A from table B?

Jolly
 
G

Guest

Hi Jolly,

Not sure how to delete records being in two tables in one of them using
queries, but won't it be sufficient to delete the ones which are marked as
not valid anymore?
In this case you could use a Delete Query.

Bernd
 
G

Guest

Hi Bernd,

That could be done but the list of known bad addresses is a
little over 17,000 and they would have to be marked
individually in order to be selected for removal. The
entire master list is close to 30,000 names that have
accumulated over the years. I like the Paradox method of
comparing the two tables then removing the known bad entries.

Jolly
 
P

PC Datasheet

I'm having trouble making full sense of your question. Is this what you
want ---

Create a query that includes both tables and join the tables on the primary
keys.Only include the primary key of the new table in the query grid. If you
run the query at this point, the query will only return the records in the
new table that are also in the No Mail table. Change the query to a Delete
query. You will delete the records in the new table that are also in the No
Mail table.
 
G

Guest

Got it!! Thank you very much.

Jolly
-----Original Message-----
I'm having trouble making full sense of your question. Is this what you
want ---

Create a query that includes both tables and join the tables on the primary
keys.Only include the primary key of the new table in the query grid. If you
run the query at this point, the query will only return the records in the
new table that are also in the No Mail table. Change the query to a Delete
query. You will delete the records in the new table that are also in the No
Mail table.

--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications
(e-mail address removed)
www.pcdatasheet.com





.
 

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

Top