Posted by broken arrow on 09/08/06 05:22
Hello Ed
Thanks for the reply
But i need to display both id's and names then wht should i do
Ed Murphy wrote:
> broken arrow wrote:
>
> > i have a table emp with employee id,name and mgrid
> >
> > I need to display the managers and the employee working under that
> > manager . How should this be done.
>
> Assuming you want the names of both, but don't care about IDs:
>
> select m.name, e.name
> from emp m
> join emp e on e.mgrid = m.employee_id
> order by m.name
Navigation:
[Reply to this message]
|