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.
| Author |
Topic |
|
dlorenc
Posting Yak Master
172 Posts |
Posted - 2008-10-07 : 12:52:43
|
| The left table contains a list of projects. Each project has a project_ID.The right table contains a list of status reports, several for each project (or none if the project has not filed a status report), each status report carries the project_ID.I would like to produce a report containing the list of project that have NOT filed a status report...So I am trying to produce a (distinct?) list fromt he project table, where project_ID does not exist in the status report table...*scratching my head on this one* |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-10-07 : 12:57:41
|
| SELECT p.*FROM projects pLEFT JOIN StatusReport srON sr.Project_ID=p.Project_IDWHERE sr.Project_ID IS NULL |
 |
|
|
dlorenc
Posting Yak Master
172 Posts |
Posted - 2008-10-07 : 13:11:58
|
that was just what I wanted...simple, yet elegant...thank you! |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-10-07 : 13:22:28
|
welcome |
 |
|
|
|
|
|