How to write a procedure for displying the data in a TREE
or (PARENT and CHILD ) relationship , for ex: A is the main
project id, for this project B,C,D are sub tasks(sub
project id's) for B the sub tasks are e,f,g and for c is
h ,i ,j and for d is k,l,m
now i need to display the o/p in a TREE fashion

pls help me ,
thanks in advance
surendra

Answer Posted / hussain

hi,
i think this may help u,


select lpad('',level*4)||projectid,subtask from xyz
start with projectid ='&a' connect by prior projectid=subproid

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

how to enter binary numbers in sql statements? : Sql dba

586


List out the acid properties and explain?

645


Do we need to create index on primary key?

556


How do you write an index?

619


What is difference between sql and excel?

592






What is a database event trigger?

690


What is sql*loader and what is it used for? : aql loader

701


what happens if you no create privilege in a database? : Sql dba

620


What are joins in sql?

625


How do I view a sql database?

654


how can I make a script that can be bi-language (supports english, german)? : Sql dba

618


Explain what is a column in a table?

673


Does pl sql work in mysql?

618


How to create an array in pl/sql?

667


What is difference between pl and sql?

615