What are the all different types of Joins in SQL Server
2000, Anybody can explain each join with definition..Thanks
in advance....

Answer Posted / siva prasad

In SQL Server 2000 we have three types of joins
1. Inner join
2. Outer Join
3. Cross Join
1. Inner Join: Inner Join is the default type of join, it
will producesses the result set, which contains matched
rows only.
syntax: select * from table1<innerjoin>table2

2. Outer Join: Outer join produces the results, which
contains matched rows and unmatched rows.
here we have three types of joins,
1.Left Outer Join 2.Right Outer Join 3.Full Outer Join
Left Outer Join: Left Outer Join producesses the results,
which contains all the rows from Left table and matched
rows from Right Table.
syntax: select * from table1<leftouterjoin>table2

Right Outer Join: Right Outer Join producesses the
resultset, which contains all the rows from right table and
matched rows from left table.
syntax:select * from table1<right outer join>table2

Full Outer Join: Full Outer Join producesses the resultset,
which contains all the rows from left table and all the
rows from right table.
syntax:select * from table1<fullouterjoin>table2

3.Cross Join: A join without having any condition is known
as Cross Join, in cross join every row in first table is
joins with every row in second table.
syntax: select * from table1<cross join>table2

Self Join: A join joins withitself is called self join
working with self joins we use Alias tables.

Is This Answer Correct ?    154 Yes 17 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Beginning with sql server version 7 0, a new enhanced data type nchar was added what type of data is supported with this data type?

510


What do you mean by SQL injection attack?

609


Explain the use of containers in ssis?

524


Your table has a large character field there are queries that use this field in their search clause what should you do?

499


List the different normalization forms?

534






Delete duplicate rows without using rowid.

1063


what are the reporting service components in SSRS?

118


What is the New in SQL server 2008?

573


Any one plz send me SQL Server Developer/DBA resume for 4 years experience

2172


What stored procedure can you use to display the current processes?

490


How do I create a trace in sql server?

512


how do you implement one-to-one, one-to-many and many-to-many relationships while designing tables? : Sql server database administration

574


What are the different types of normalization?

612


What is hot add cpu in sql server 2008?

516


you added a row to a view, but the row is not shown on the view. Explain how this can happen, and how you can remedy the situation

533