Non contributors

  • Thread starter Thread starter John
  • Start date Start date
J

John

Hi,
I have a database of club members some of whoom make regular
payments/donations.I have a members table and a payments table and
associated forms.I need to identify members who have never contributed, and
want to write a simple query to do this. Since those who have never
contributed are consequently not entered in the payments table I need the
query to reflect this but am at a loss for how to do it.Anyone got any
ideas.Tia, John
 
The query wizard can do this for you; look at the Unmatched records option
in the "New Query" list.

Essentially, what you do is a LEFT JOIN between the ClubMember table and the
Payments table and look for members with no record in the Payments table:

SELECT ClubMembers.MemberID
FROM ClubMembers LEFT JOIN Payments
ON ClubMembers.MemberID = Payments.MemberID
WHERE Payments.MemberID Is Null;
 
John,
Your query should use the Members table, linked to the Payments table.
The link should be a Left Join that translates to...
"Show all records in Members and only those in Payments that match."
If you include a field from Payments like PaymentDate, those folks who
haven't contributed will have a Null PaymentDate.
Filter the query for PaymentDate = Null and you'll only return
non-contributers.
 

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

Similar Threads

Counting multiple memberships 1
Table Design - stuck! 4
Payments Schedule 6
Simple Database 5
Complicated query 11
Working with dates 1
Invoices outstanding at end of year 1
Searchable Calendar 1

Back
Top