GeekInterview.com
  I am new, Sign me up!
 
GeekInterview.com  >  Interview Questions  >  Data Warehousing  >  BO Designer
Go To First  |  Previous Question  |  Next Question 
 BO Designer  |  Question 22 of 117    Print  
Outer join
A join that links two tables, one of which has rows that do not match those in the common column of the other table.


  
Total Answers and Comments: 1 Last Update: July 04, 2006   
  
 Sponsored Links

 
 Best Rated Answer
Submitted by: Suresh
 

Outer Join - method of retreiving selected rows from one table that doesn't match rows with the other table.

Ex: Consider A & B two tables

SELECT eno, ename, a.dno, dname 

FROM a,b

WHERE a.dno=b.dno;

Output:

Eno        Ename           Dno              Dname

100        John               10               Accounts

101        Michael            20               Sales

                                   30              Production                

                                   40              Purchase

In outer join 2 types r there:

Left Outer Join & Right outer Join

Ex: LeftOuter Join

SELECT eno, ename, a.dno, dname 

FROM a,b

WHERE a.dno(+)=b.dno;

Display all the rows from "Table A".

Output:

Eno        Ename           Dno              Dname

100        John               10               Accounts

101        Michael            20               Sales

102        Anni                20               Sales                

103        Sonia              

105        Mann

Ex: Right Outer Join

SELECT eno, ename, a.dno, dname 

FROM a,b

WHERE a.dno=(+)b.dno;

Display all the rows from "Table B".

Output:

Eno        Ename           Dno              Dname

100        John               10               Accounts

101        Michael            20               Sales

102        Anni                20               Sales                

                                   30              Production                

                                   40              Purchase

Suresh



Above answer was rated as good by the following members:
ASHOK1324
July 04, 2006 22:01:40   #1  
Suresh        

RE: Outer join

Outer Join - method of retreiving selected rows from one table that doesn't match rows with the other table.

Ex: Consider A & B two tables

SELECT eno ename a.dno dname

FROM a b

WHERE a.dno b.dno;

Output:

Eno Ename Dno Dname

100 John 10 Accounts

101 Michael 20 Sales

30 Production

40 Purchase

In outer join 2 types r there:

Left Outer Join & Right outer Join

Ex: LeftOuter Join

SELECT eno ename a.dno dname

FROM a b

WHERE a.dno(+) b.dno;

Display all the rows from Table A .

Output:

Eno Ename Dno Dname

100 John 10 Accounts

101 Michael 20 Sales

102 Anni 20 Sales

103 Sonia

105 Mann

Ex: Right Outer Join

SELECT eno ename a.dno dname

FROM a b

WHERE a.dno (+)b.dno;

Display all the rows from Table B .

Output:

Eno Ename Dno Dname

100 John 10 Accounts

101 Michael 20 Sales

102 Anni 20 Sales

30 Production

40 Purchase

Suresh


 
Is this answer useful? Yes | NoAnswer is useful 1   Answer is not useful 0Overall Rating: +1    

 Related Questions

A situation in which a query includes two or more tables that are not linked by a join. If executed, this type of query retrieves all possible combinations between each table and may lead to inaccurate 
Latest Answer : Table A having m records and Table B having n records then the cartesian prodcut is mXn. Regards,Ravi Kumar Garreravi_kumar_garre@yahoo.co.in ...

A join based on the equality between the values in the column of one table and the values in the column of another. Because the same column is present in both tables, the join synchronizes the two tables.  
Latest Answer : it is also called INNER JOIN ...

A relational operation that causes two tables with a common column to be combined into a single table. Designer supports equi-joins, theta joins, outer joins, and shortcut joins.  
Latest Answer : Relational operation that causes two tablesCheers,Sithu ...

A join that links two tables, one of which has rows that do not match those in the common column of the other table.  
Latest Answer : Outer Join - method of retreiving selected rows from one table that doesn't match rows with the other table.Ex: Consider A & B two tablesSELECT eno, ename, a.dno, dname FROM a,bWHERE a.dno=b.dno;Output:Eno        ...

A join that links two tables by bypassing one or more other tables in the universe.  
Latest Answer : A. short cut joins are used to improve the query performance at universe level i.e. for performance tuning. Suppose if we have 4 tables A,B,C and D A--->B---->C---->D and there is a chance to link A--->D but we should not link (causes loop) ...

A join that links tables based on a relationship other than equality between two columns.  
Latest Answer : Theta join—A theta join is created when the data in two fields from two tables is related via some comparison operator other than equals (=). For example, a not-equal join relates data using the not equal operator (). For example, suppose you want to ...

What is block? types of blocks?what is locking systm in universe?what is shortcut join where it is neccessary?
Read Answers (1) | Asked by : naveen

What is joinpath problem? 
Latest Answer : the join path problems areee loops, chasmtraps, fantraps..these can be solved by using 1) visualising analysis of schema2) by  using aliases3) by using contexts ...
Read Answers (3) | Asked by : kusam_m


 Sponsored Links

 
Related Articles

Breaking up XML into Relational Data

Breaking up XML into Relational Data While the preceding example shows how to construct an XML representation over relational data the example in this section illustrates how you can shred XML data back into relational data This reverse operation can be useful if your application works with relation
 

Querying Data with Oracle XQuery

Querying Data with Oracle XQuery Starting with Oracle Database 10g Release 2 you can take advantage of a full featured native XQuery engine integrated with the database With Oracle XQuery you can accomplish various tasks involved in developing PHP Oracle XML applications operating on any kind of dat
 

Retrieving XML Data

Retrieving XML DataTo retrieve XML data from an XMLType table you can use a SELECT SQL statement just as you would if you had to query a relational table For example to select the employee with the id set to 100 from the employees XMLType table discussed in the preceding section you might issue the
 

Using XMLType for Handling XML Data in the Database

Using XMLType for Handling XML Data in the Database Being an object type XMLType can not only be used to store XML data in the database but also to operate on that data via its built in methods Regardless of the storage model you choose XMLType provides a set of XML specific methods to operate on XM
 

Using Oracle Database for Storing, Modifying, and Retrieving XML Data

Using Oracle Database for Storing Modifying and Retrieving XML Data With Oracle XML DB you have various XML storage and XML processing options allowing you to achieve the required level of performance and scalability One of the most interesting things about Oracle XML DB is that it allows you to per
 

ODP.NET - Techniques to Improve Performance while Retrieving Data

ODP NET Techniques to Improve Performance while Retrieving Data Performance tuning is a great subject in Oracle Volumes of books would not be enough to cover every aspect of performance tuning in Oracle However in this section we will only discuss the fundamental performance techniques while working
 

ODP.NET - Populating a Dataset with a Single Data Table

ODP NET Populating a Dataset with a Single Data Table A dataset is simply a group of data tables These data tables can be identified with their own unique names within a dataset You can also add relations between data tables available in a dataset mosgoogle The following code gives you the details o
 

ODP.NET - Retrieving Typed Data

ODP NET Retrieving Typed Data While retrieving values from OracleDataReader we can extract information available in individual columns of a particular row either by using column ordinal position values or column names mosgoogle Retrieving Typed Data Using Ordinals ODP NET provides data specific enum
 

ODP.NET - Retrieving Data Using OracleDataReader

ODP NET Retrieving Data Using OracleDataReader OracleDataReader is simply a read only and forward only result set It works only if the database connection is open and it makes sure that the connection is open while you are retrieving data As the data that it retrieves is read only it is a bit faster
 

ODP.NET - Fundamental ODP.NET Classes to Retrieve Data

ODP NET Fundamental ODP NET Classes to Retrieve Data To retrieve data from an Oracle database using ODP NET we need to work with a few of the ODP NET classes At this point we will discuss the most fundamental classes available in ODP NET for retrieving data mosgoogle The following is the list of fun
 

About Us -  Privacy Policy -  Terms and Conditions -  Contact -  Ask Question -  Propose Category -  Site Updates 

Copyright © 2005 - 2009 GeekInterview.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape