hi,
This is my table..
create table man
(
empid int primary key,
empname varchar(50),
managerid int references self(empid)
)
select * from man
empid empname managerid
------- --------- --------
1123sabeer 1124
1124muqeem 1124
1125seshu 1123
1126ranga 1124
1127sakee 1123
use only self join query. i want ouput like this
empid empname mangerid
------ --------- ----------
1123 sabeer 1124(muqeem)
1124muqeem 1124(muqeem)
1125seshu 1123(sabeer)
1126ranga 1124(muqeem)
1127sakee 1123 (sabeer)
i need self join query only?
:P:P:P:P:P:P:P
Thanks,
Sabeer.M