wellster34
Programmer
Oracle 8i
Hi,
I have an issue on how to extract data from a single table that stores the data for different levels of a Hierarchy in the same columns. Here's an example:
PARENT_VALUE CHILD_VALUE
100 200
100 300
200 ABC
200 DEF
300 ZZZ
So, if I query 100 for a Parent. I return 200 and 300. Then I need to query the same table for 200 and 300. So on and so on until I get to the bottom of the hierarchy. The hierarchy is like this to be extracted:
100 200 ABC
100 200 DEF
100 300 ZZZ
Is there an Oracle function/query to extract this information or is it a coding logic nightmare?
Thanks for your time
Hi,
I have an issue on how to extract data from a single table that stores the data for different levels of a Hierarchy in the same columns. Here's an example:
PARENT_VALUE CHILD_VALUE
100 200
100 300
200 ABC
200 DEF
300 ZZZ
So, if I query 100 for a Parent. I return 200 and 300. Then I need to query the same table for 200 and 300. So on and so on until I get to the bottom of the hierarchy. The hierarchy is like this to be extracted:
100 200 ABC
100 200 DEF
100 300 ZZZ
Is there an Oracle function/query to extract this information or is it a coding logic nightmare?
Thanks for your time