Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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

Can we perform dml in function?

1013


How do you delete duplicates in sql query using rowid?

891


What is cascade in sql?

913


Is sql injection illegal?

963


Can we call a function containing dml statements in a select query?

917


Is coalesce faster than isnull?

906


Why do we create views in sql?

1053


Can we join more than 2 tables in sql?

945


how to calculate expressions with sql statements? : Sql dba

980


What is the main difference between sql and pl/sql?

1026


List different type of expressions with the example.

892


what happens when the column is set to auto increment and you reach the maximum value for that table? : Sql dba

968


What is the non-clustered index in sql?

1008


How do I pipe the output of one isql to another?

943


What is implicit cursor in pl sql?

1026