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 -> Re: A simple select question

Re: A simple select question

From: Angelo Cavallaro <angelo.cavallaro_at_pcm.bosch.de>
Date: Tue, 10 Nov 1998 16:56:23 +0100
Message-ID: <36486227.24FB@pcm.bosch.de>


Hello Abiy.

With 7.3 you could try this:
(For earlier versions of ORACLE you must first create a  view like the inline view in the statement)

select level, prior name name1, name name2   from (select No_W no, NULL father_no, Name_W name

	  from tab_w
	union
	select  NO_X no , No_W father_no, Name_X name
	  from tab_X
	union
	select  No_Y no , No_X father_no, Name_Y name
	  from tab_Y
	union
	select  No_Z no , No_X father_no, Name_Z name
	  from tab_Z)

  start with father_no is NULL
connect by prior no = father_no
  where father_no is not null;

HTH Angelito. Received on Tue Nov 10 1998 - 09:56:23 CST

Original text of this message

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