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
What is DB Development software?
What is dbms explain in brief?
How to combine two function together?
Write short notes on manual refreshes.
fact table and dimension table containg one to many relationship or many to one relastionship
Hi my program is accesing data from two db2 databases.what is the bind card for this program to genarate plan? how to specify the two owners and two qualifiers in bind card
Which data type cannot be used as a parameter in a udf?
Explain what a database is?
If a column is an image value type, how you can compare column values? How can you use this column in join clause?
What you can do to remove data from the cache and query plans from memory for testing the performance of a query repeatedly?
Explain about the relational database?
In which database can extended stored procedures be added?
What are the types of database model?
Where is dbms used?
Explain the process of the user request and data generating?