What are inner join and outer join?
Answers were Sorted based on User's Feedback
Answer / akn
Inner join is the most common type of join. Inner joins
return all rows from multiple tables where the join
condition is met.
Outer join returns all rows from one table and only those
rows from a secondary table where the joined fields are
equal (join condition is met).
Is This Answer Correct ? | 17 Yes | 3 No |
Answer / pandian raman
Inner Join (simple join)
Inner joins return all rows from multiple tables where the
join condition is met.
For example,
SELECT suppliers.supplier_id, suppliers.supplier_name,
orders.order_date FROM suppliers, orders
WHERE suppliers.supplier_id = orders.supplier_id;
This SQL statement would return all rows from the suppliers
and orders tables where there is a matching supplier_id
value in both the suppliers and orders tables.
Outer Join
This type of join returns all rows from one table and only
those rows from a secondary table where the joined fields
are equal (join condition is met).
For example,
select suppliers.supplier_id, suppliers.supplier_name,
orders.order_date from suppliers, orders where
suppliers.supplier_id = orders.supplier_id(+);
This SQL statement would return all rows from the suppliers
table and only those rows from the orders table where the
joined fields are equal.
The (+) after the orders.supplier_id field indicates that,
if a supplier_id value in the suppliers table does not exist
in the orders table, all fields in the orders table will
display as <null> in the result set.
The above SQL statement could also be written as follows:
select suppliers.supplier_id, suppliers.supplier_name,
orders.order_date from suppliers, orders where
orders.supplier_id(+) = suppliers.supplier_id
Is This Answer Correct ? | 9 Yes | 1 No |
Answer / omprakash.jsm
Inner join return rows from many tables where the join field and data type are equal.
outer join return rows from many tables where the join field are not equal but data type will be same.
Is This Answer Correct ? | 0 Yes | 2 No |
two tables are there emp(eno,ename,sal,deptno),dept(deptno,dname).how form the query in deptno,ename,max(sal)
What is a sub query? What are its various types?
what are pseudocolumns?
What are nested tables?
How to drop an index in oracle?
Why do I get unexpected characters from 8-bit character sets in weblogic jdriver for oracle?
I have a parent program and a child program. I want to write a statement in Exception Block of the parent program so that when the statement in the exception block is executed, the control goes to the next statement in the parent block bypassing the child block.How do i do that?
Differnce between view and index
What are the general rules on data consistency?
 How to use an oracle sequence generator in a mapping?
What is the effect of setting the value "all_rows" for optimizer_goal parameter of the alter session command? What are the factors that affect optimizer in choosing an optimization approach?
What do you mean by merge in oracle?