Table of Contents

Search

  1. Preface
  2. Introduction to Test Data Management
  3. Test Data Manager
  4. Projects
  5. Policies
  6. Data Discovery
  7. Data Subset
  8. Data Masking
  9. Data Masking Techniques and Parameters
  10. Data Generation
  11. Data Generation Techniques and Parameters
  12. Working with Test Data Warehouse
  13. Plans and Workflows
  14. Monitor
  15. Reports
  16. ilmcmd
  17. tdwcmd
  18. tdwquery
  19. Data Type Reference
  20. Data Type Reference for Test Data Warehouse
  21. Glossary

Joins

Joins

You can use joins when you run a query with the Select and Select Distinct clauses.
You can use the following types of joins in a query:
Inner Join
Use the following syntax to perform an inner join:
SELECT <columns> FROM <table 1> INNER JOIN <table 2> ON <table 1>.<column_name> = <table 2>.<column_name>
For example:
SELECT suppliers.supplier_id, suppliers.supplier_name, orders.order_date FROM suppliers, INNER JOIN orders ON suppliers.supplier_id = orders.supplier_id
Left Outer Join
Use the following syntax to perform a left outer join:
SELECT <columns> FROM <table 1> LEFT OUTER JOIN <table 2> ON <table 1>.<column_name> = <table 2>.<column_name>
For example:
SELECT suppliers.supplier_id, suppliers.supplier_name, orders.order_date FROM suppliers LEFT OUTER JOIN orders ON suppliers.supplier_id = orders.supplier_id
Right Outer Join
Use the following syntax to perform a right outer join:
SELECT <columns> FROM <table 1> RIGHT OUTER JOIN <table 2> ON <table 1>.<column_name> = <table 2>.<column_name>
For example:
SELECT orders.order_id, orders.order_date, suppliers.supplier_name FROM suppliers RIGHT OUTER JOIN orders ON suppliers.supplier_id = orders.supplier_id
Full Outer Join
Use the following syntax to perform a full outer join:
SELECT <columns> FROM <table 1> FULL OUTER JOIN <table 2> ON <table 1>.<column_name> = <table 2>.<column_name>
For example:
SELECT suppliers.supplier_id, suppliers.supplier_name, orders.order_date FROM suppliers FULL OUTER JOIN orders ON suppliers.supplier_id = orders.supplier_id