Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

All parents for a child node

3201686Mar 18 2016 — edited Mar 21 2016

Hi,

I am using Oracle Version : Oracle9i Enterprise Edition Release 9.2.0.7.0 - 64bit Production

I am looking to generate all parent(direct/indirect) account_ids for a child account id. Can someone help me out in creating SQL for this.

I got to know recursive WITH is not supported in Oracle9i.

child parent

4 3

3 2

2 1

1 NULL

OUTPUT :

child parents

4 3

4 2

4 1

3 2

3 1

2 1

This post has been answered by Frank Kulash on Mar 18 2016
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 18 2016
Added on Mar 18 2016
9 comments
476 views