Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Rhinorhino on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SQL statement to only display certain criteria 1

Status
Not open for further replies.

usagi75

Technical User
Joined
May 24, 2003
Messages
8
Location
AU
If I have say this table

MemID Training Type Hours
----- ------------- -----
1 Training 2.5
1 Training 2.5
2 Access 3
1 Access 1.5
3 Training 2.5
2 Training 2

With the above data, only Member 2 has done "Training" only. What SQL statement do I need to only show the members that have done training only?
 
Oops...I meant only Member 3 has done "Training" only
 
Considering your data, you could try.
SELECT *
FROM tableA
WHERE MemID Not IN (SELECT MemID FROM TableA A WHERE A.TrainingType ="Access")

Duane
MS Access MVP
Find out how to get great answers faq219-2884.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top