tsql - T-SQL - How to write query to get records that match ALL records in a many to many join -
(I do not think I have given this question correctly - but I do not know how to describe it )
This is what I am trying to do:
Assuming that I have a person table with a PersonID field and I say that a person has many The groups can be related to the groups, so the group has a group table and group membership table with field, which is two Likaon and group membership tables are being added between a many-to-many, one PersonID field and a Smuhaidi field. So far, it is very easy for many people to join.
Looking at a list of groupings, I would like to be able to write a query that gives to all the people involved in those groups (none of those groups). And any number of queries should be able to handle group edits. I would like to avoid dynamic SQL.
Is there any easy way to do this that I remember? Thanks, blank
select person_id, count (*) from group membership in group_id ([ Your Edit <>:
Comments
Post a Comment