Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> better way
Is there a better way of doing the following query:
"first get all the records in resultset1 and then get records in resultset2 where the records are not in resultset1"
other than
SELECT blah blah...
FROM resultset1
WHERE blah blah...
UNION
SELECTblah blah...
FROM resultset2
WHERE keycolumns not in (SELECT keycolumns...
FROM resultset1 WHERE blah blah...)
having that the query for resultset1 is really very big and will take quite too much time, i dont think its a good idea to run it again as a subquery.
Any one has got other suggested way of doing it?
thanks,
ZS
Received on Wed Oct 17 2001 - 03:41:23 CDT
![]() |
![]() |