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

Home -> Community -> Usenet -> c.d.o.server -> tricky SQL SELECT - help!

tricky SQL SELECT - help!

From: Norman Dunbar <Norman.Dunbar_at_lfs.co.uk>
Date: Fri, 31 Jan 2003 16:31:11 -0000
Message-ID: <E2F6A70FE45242488C865C3BC1245DA7033EABD7@lnewton.leeds.lfs.co.uk>


This is horrible !

SELECT NAME FROM people
WHERE INSTR((SELECT people_ids FROM pets WHERE pet = 'Rat'),';'||TO_CHAR(ID)||';

NAME


John                                              
Wilma                                             
Dick                                              
Mike        
                                      

4 rows selected

Can you imagine having to do that with a join to another table on the poeople id ?
Yeuch !    

Cheers,
Norman



Norman Dunbar
Database/Unix administrator
Lynx Financial Systems Ltd.
mailto:Norman.Dunbar_at_LFS.co.uk
Tel: 0113 289 6265
Fax: 0113 289 3146
URL: http://www.Lynx-FS.com

-------------------------------------

-----Original Message-----

From: Norman Dunbar
Posted At: Friday, January 31, 2003 4:11 PM Posted To: server
Conversation: tricky SQL SELECT - help!
Subject: tricky SQL SELECT - help! (PS)

PS. And having done that, find me a list of all the people who keep rats .........

Cheers,
Norman.



Norman Dunbar
Database/Unix administrator
Lynx Financial Systems Ltd.
mailto:Norman.Dunbar_at_LFS.co.uk
Tel: 0113 289 6265
Fax: 0113 289 3146
URL: http://www.Lynx-FS.com

-------------------------------------
Received on Fri Jan 31 2003 - 10:31:11 CST

Original text of this message

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