Cheap VPS & Xen Server


Residential Proxy Network - Hourly & Monthly Packages

Oracle EQUI JOIN


Oracle Equi join returns the matching column values of the associated tables. It uses a comparison operator in the WHERE clause to refer equality.

Syntax

  1. SELECT column_list
  2. FROM table1, table2….
  3. WHERE table1.column_name =
  4. table2.column_name;

Equijoin also can be performed by using JOIN keyword followed by ON keyword and then specifying names of the columns along with their associated tables to check equality.

Syntax

  1. SELECT *
  2. FROM table1
  3. JOIN table2
  4. [ON (join_condition)]

Oracle EQUI JOIN Example

Let’ take two tables “agents” and “customer”.

Agents table

equi-join1

Agent data

equi-join2

Customer table

equi-join3

Customer data

equi-join4

Execute this query

  1. SELECT agents.agent_city,customer.last_name,
  2. customer.first_name
  3. FROM agents,customer
  4. WHERE agents.agent_id=customer.customer_id;

Output

equi-join5

Comments

comments