Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Query question

Query question

From: Peter Ashford <peter.m.ashford_at_gmail.com>
Date: Sun, 03 Jun 2007 02:50:29 -0000
Message-ID: <1180839029.192876.326340@j4g2000prf.googlegroups.com>


Hi - I have a question about a query I'm struggling with - please redirect me if this is not an appropriate place to ask.

I've been trolling the net for hours trying to find a solution to this, but obviously I am dumb :o)

What I have is two tables, one with projects and another with personnel linked to projects:

PROJECTS
- projectID (pk)

LINKED PERSONNEL
- projectID (fk into PROJECTS)

So, LinkedPersonnel is in a many-to-one relationship to Projects. i.e: a project can have many personnel, all with different roles.

What I want to do is to select data from Projects, but including the person who plays the 'Primary Investigator' role for that project. Baring in mind that:

I can't restrict using the WHERE clause, since that removes projects which have no PI.

I've tried various forms of subqueries, but to date, with no luck.

If anyone can help, I'd appreciate it. Apologies for being thick =) Received on Sat Jun 02 2007 - 21:50:29 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US