RE: Execution plan for queries using minus/union/intersect

  • From: "Allen, Brandon" <Brandon.Allen@xxxxxxxxxxx>
  • To: "gba.oraclel@xxxxxxxxx" <gba.oraclel@xxxxxxxxx>, Oracle Discussion List <oracle-l@xxxxxxxxxxxxx>
  • Date: Thu, 22 Oct 2009 13:59:23 -0700

Not sure if I understand correctly what you're trying to do, but maybe a UNION 
ALL is what you're looking on the UNION option, but not sure about the MINUS 
and INTERSECT, however I'd imagine that if there is a unique index on the 
relevant columns of both tables then Oracle will be smart enough to avoid 
actually doing any sorting even though it might still show the SORT step in the 
plan, there wouldn't be any real work behind it.  Just guessing here so 
everyone feel free to jump in and correct me.

Regards,
Brandon


________________________________
Privileged/Confidential Information may be contained in this message or 
attachments hereto. Please advise immediately if you or your employer do not 
consent to Internet email for messages of this kind. Opinions, conclusions and 
other information in this message that do not relate to the official business 
of this company shall be understood as neither given nor endorsed by it.

Other related posts: