-
hi
We have a one table like emp
emp-table
empno mgr
(pk) (fk of empno)
1
2 1
3 2
4 3
5 4
6 4
.
.
.
1234 1233
.
.
n n-2
We need a output like this
1
. 2
.....3
***** 4
******* 5
********* 6
***********7
************8
**************9
****************** 1233
.
.
*************************n-1
just like a hirarchial model.
It resembles like Directory structure.
thanks in advance
anj
-
Try:
select rpad('*',pk_fld,'*')||ltrim(rtrim(to_char(fk_fld)) from emp_table;
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|