Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 SQL Query HOWTo

Author  Topic 

kingduffy
Starting Member

2 Posts

Posted - 2001-10-12 : 15:59:09
Looking for some help on a SQL query that I am having trouble with. The logic is fairly straight forward, just haven't had enough experience to find the answer.

Here is a simple representation of the tables in question for the query. There are three tables (USERID, GROUP, GROUPMEMBER).

USERID has two fields
ID (Identity)
USERNAME (VARCHAR 100)

GROUP has two fields
ID (Identity)
DISPName (VARCHAR 100)

GROUPMEMBER has four fields
ID (identity)
FK_UserID (Foriegn Key to the USER table)
FK_GroupID (Foriegn Key to the GROUP table)

The GROUPMEMBER table keeps the membership of the various groups for a company. In this example we have five groups (DALLAS, AUSTIN, HOUSTON, HR, TECH)

I am looking for a listing of all the members of the TECH group who are also members of the DALLAS and AUSTIN group.
   

- Advertisement -