On 5/9/05, Hrishikesh Deshmukh <hdeshmuk@xxxxxxxxx> wrote: > Hi, > > I have two tables with genes and its annotation and a bunch of > parameters, i wanted to know what are the genes common to these two > tables, so i wrote this query > > create table temp as select gene from dataTable1 intersect > select gene from dataTable2; > > The resulting table has only genes list (one column). > > Now i want to retrieve gene annotation from datatable1, so how i guess > one has to write a query select geneAnnotation from dataTable1 where > genes= " temp table"; > select * from datatable1 where genes in (select gene from temp); Actually, i don't like the name "temp" for a table it seems error prone. -- Atentamente, Jaime Casanova (DBA: DataBase Aniquilator ;) ---------------------------(end of broadcast)--------------------------- TIP 3: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to majordomo@xxxxxxxxxxxxxx so that your message can get through to the mailing list cleanly