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 -> SQLPlus ==> How do I rewrite this Query ?

SQLPlus ==> How do I rewrite this Query ?

From: LT Cheah <LT_Cheah_at_army.net>
Date: Tue, 14 Jan 2003 21:54:38 +0800
Message-ID: <ri482v0bs7tft6vd8acs9kdf7414lvmqn6@4ax.com>


My SQLPlus query (on Oracle 8.1.7) is

SELECT EVAL, HD13
FROM MY_TABLE
GROUP BY EVAL, HD13
/

which returns the below :-

EVAL		HD13		
-----	-----	
QDOS		ABC
AII		ABC
QDOS		XYZ
AII		PQR
QDOS		PQR
QDOS		AAA
AII		BBB

...
...
...

Question:-
How can the query be rewritten to list out only rows 1,2,4,5 ie rows with both QDOS and AII for any single HD13 (note only possible values for EVAL is either QDOS or AII)

Thanks in advance Received on Tue Jan 14 2003 - 07:54:38 CST

Original text of this message

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