[AccessD] Selecting Parents that have ALL Children

Drew Wutka DWUTKA at marlow.com
Mon Oct 20 13:11:44 CDT 2003


Hmmmm, wouldn't a count greater then 1, from the 'students' end indicate
that?  Just going from your example.

Drew

-----Original Message-----
From: Developer [mailto:Developer at ultradnt.com]
Sent: Monday, October 20, 2003 12:44 PM
To: 'Access Developers discussion and problem solving'
Subject: [AccessD] Selecting Parents that have ALL Children


I am trying to construct a result set (proto-typing in A2k but want to
have a SQL2000 sp at the end, an answer for either is ok), from a user
form, where the user selects items from a list box.  These items are the
possible "right side" of a many-to-many.  I loop the list box, and
construct an IN clause, which works great to find a left-sider that had
ANY of the children, but my users need the result set to be "who had ALL
of these" (sort of a combined IN and AND).

Tia for any assistance,
Steve

For example, if there are classes in Word, Access, Excel, and the user
picked Access and Excel, which students took both, with tblStudent->
tblStudentClass <-tblClass.  The tblStudentClass record with both id's
just needs to exist, there is other criteria.





_______________________________________________
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com


More information about the AccessD mailing list