i have a table emp and columns ename,empno,mgr_id,i need ename,manager name as result i.e employee respective manager.. example
empno ename mgr_id
1 john 3
2 paul 3
3 smith 1
4 kevin 1
5 stewart 2
result has to look like this
ename manager
john smith
paul smith
smith john
kevin john
stewart paul
can u plz help me out in this.....
Answer Posted / praveen h
I think this one will work
Select a.ename as Employee ,b.ename as Manager from
EMP ,EMP B
where
A.MGR_ID=B.empno
| Is This Answer Correct ? | 9 Yes | 2 No |
Post New Answer View All Answers
Define join and name different types of joins?
How many row comparison operators are used while working with a subquery?
Whis is not false in primary key?
What is pl/sql language case sensitive?
What is the use of triggers?
Explain about various levels of constraint.
What is difference between pls_integer and integer?
How do you know if a relationship is 2nf?
Is a table valued function object?
Can we create clustered index without primary key?
which tcp/ip port does sql server run on? : Sql dba
Difference between global and parameter variables?
Explain isolation levels. : Transact sql
What is a parameter query?
Is sql between inclusive?