What are the all different types of Joins in SQL Server
2000, Anybody can explain each join with definition..Thanks
in advance....
Answer Posted / j.jyothy
Already i explained 3 joins now i tell u Outerjoins.
leftouterjoin:It will display all the rows of left table
irrespective of whether there is a match in the right or
not.If there is no match in the right table then the null
row is aasumed and it is displayed in the output.
Display all emps in the emptable.
select empno,ename,esal,e.deptno,d.deptno,dname,loc from
emp e left outerjoin dept d on e.deptno=d.deptno
RightOuterJoin:It will display all the rows of right table
irrespective of whether there is a match in the right or
not.If there is no match in the Left table then the null
row is aasumed and it is displayed in the output
Example
select empno,ename,esal,e.deptno,d.deptno,dname,loc from
emp e right outerjoin dept d on e.deptno=d.deptno
| Is This Answer Correct ? | 23 Yes | 18 No |
Post New Answer View All Answers
What does it mean to invest in the index?
How to change the password of a login name in ms sql server?
Why we should not use triggers?
How optimize sql query with multiple joins in sql server?
How to return the date part only from a sql server datetime datatype?
How do triggers work?
What is the difference between rank and dense_rank?
What is use of attribute hierarchy optimized state? : sql server analysis services, ssas
In what sequence sql statement is processed?
What are the export options of ssrs?
What is an execution plan? How would you view the execution plan?
What do you understand by mirroring?
Explain the difference between cross join and full outer join?
What is the purpose of a table?
What do you mean by SQL injection attack?