What is a self join? Explain it with an example?
Answer Posted / madhavi
Joining the table to itself is self join.
Example:
To find the manager name for each employee in the employee
table:
select e1.empno employee_id,e1.ename employee_name,e2.ename
manager_name,e2.empno employee_num from emp e1,emp e2 where
e1.empno=e2.mgr;
| Is This Answer Correct ? | 27 Yes | 17 No |
Post New Answer View All Answers
Explain what a database is?
I have a few records all are same structures data, I want to store data in multiple targets how
Write the fastest query to find out how many rows exist in a table?
How can I detect whether a given connection is blocked?
Explain the role of indexing in databases?
You are testing the performance of a query the first time you run the query, the performance is slow. the second time you run the query, the performance is fast. why is this?
Explain about query and reporting.
How you can make a parameterized view?
In which table collections errors are stored.
Explain about a primary key?
Where is dbms used?
explain detail about ftp in datastage?
Explain about relational operator join?
Explain about post-relational databases?
Can an extended stored procedure be called from inside a user-defined function?