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 -> traversing all dependent data

traversing all dependent data

From: Markus <markus.breitenbach_at_gmx.de>
Date: 24 Feb 2004 09:14:15 -0800
Message-ID: <9bc574d3.0402240914.521e40bb@posting.google.com>


I have a table T with several 1:n relationships to tables U1, U2,... Now I'd like to process all records in T (plus dependent data) satisfiying some condition C.
As there is a hugh amount of data my idea to handle this bulk data was:

  1. SELECT * FROM T WHERE C
  2. SELECT * FROM T WHERE C EQUI-JOIN U (for each of the U's)
  3. nested loop: for every selected record in T read dependent data from the joined result sets.

Now I have to ensure that the order in which elements of T appear in the various result sets is the same, but an ORDER BY on some key of T is very slow. Some natural (!?) BUT CONSISTENT ordering would be enough.
How can this be done most efficiently with Oracle? Any hints?

Things get even more complicated as the tables U may have 1:n relationships with tables V...

Cheers,

   Markus. Received on Tue Feb 24 2004 - 11:14:15 CST

Original text of this message

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