Re: [SQL] help w/ constructing a SELECT

2002-09-20 Thread Josh Berkus
Charles, > > 3. All contigs where all clones have read = 'x' SELECT * FROM contigs WHERE NOT EXISTS ( SELECT contig_id FROM clones WHERE clones.contig_id = contigs.contig_id AND read <> 'x'); i.e. "Select all contigs not having any clone whose read is something other than 'x' "

Re: [SQL] help w/ constructing a SELECT

2002-09-19 Thread Josh Berkus
Charles, > Having a problem with a query. > I would like to construct a query which will return a list of all > contigs which are comprised of clones whose 'read' = 'x' (read can be > either 'x' or 'y'). It appears that you haven't formulated clearly what you want to get. I can see 3 possibil

[SQL] help w/ constructing a SELECT

2002-09-19 Thread Charles Hauser
Greetings, Having a problem with a query. I would like to construct a query which will return a list of all contigs which are comprised of clones whose 'read' = 'x' (read can be either 'x' or 'y'). Details: A contig may be comprised of more than 1 clone, so in TABLE clone_contig, there