query problem (I can't really describe in a short space like this) (1 Viewer)

bauer

Registered User.
Local time
Today, 12:54
Joined
Aug 23, 2001
Messages
77
I have two tables, One holds people going to an event (Participants), and another that holds the peoples information (Individuals).
I need a query that holds all of the Individuals that are not going to a particular event, where a field in the Participants table is EventID (which event they are going to).
Also I can't just put a not by the event number, b/c a person can go to more than one event, doing that would end up getting people who are in this event and are also going to other events.

I hope that I was clear, and I appreciate any help

Thank you
 

simongallop

Registered User.
Local time
Today, 17:54
Joined
Oct 17, 2000
Messages
611
Create a query based on the event that you are looking at. You now have all the people going to an event. Now compare the query against the individuals table to get who isn't going
 

bauer

Registered User.
Local time
Today, 12:54
Joined
Aug 23, 2001
Messages
77
But now, how do I get only the people who are not in that other query?
 

simongallop

Registered User.
Local time
Today, 17:54
Joined
Oct 17, 2000
Messages
611
Link the table to the query (qryGoing) by name and ( I don't know the names of joins .. sorry!!) drag the name of the people from the individuals table to the query. Make this join No 2 (show all records from table Individuals and only those from query etc....)
Now show the names field from both the table and qryGoing and in the criteria of the field from qryGoing make it Is Null. this will then only show the records that do not appear in qryGoing.

Hope that you can understand my ramblings!!
 

bauer

Registered User.
Local time
Today, 12:54
Joined
Aug 23, 2001
Messages
77
Thank you so much, that worked perfectly.
 

Users who are viewing this thread

Top Bottom