Can an Access 2003 query exclude the results from a previous query?

5 pts.
Tags:
Access 2003
Access Database
Access query
Query Parameters
I have a database with 2 tables: one with name/address info, and another with info on yearly donations to our organization. The 2 tables are linked through an ID number. I have set up a query that will give me name/address info for those who donated in 2010 (where the year field is 2010 and the contribution fields are >0) that will be used in a report that makes mailing labels. I want separate mailing labels for everyone else. Is there a way to set up a query that excludes the results of a previous query? There are too many variables to have a simple query that is the opposite of the first one (2010 = 0, for instance) because if someone didn’t donate in 2010, 2010 doesn’t appear in their record. Also, many people who donated in 2010 also donated in previous years, and I don’t want their names repeated. I’ve tried as many things as I can think of, to no avail! Any help would be greatly appreciated.

Software/Hardware used:
Access 2003

Answer Wiki

Thanks. We'll let you know when a new response is added.

I’m not familiar with the Access’ query design view or the query wizards, but you could create a query in SQL view with a code similar to this:

<pre>SELECT *
FROM donor d
WHERE NOT EXISTS (
SELECT 1
FROM donations
WHERE id = d.id
AND year = 2010
AND amount > 0)</pre>

Let us know if this is what you meant.

Discuss This Question:  

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following