Sie sind auf Seite 1von 12

Unit 5.

Joins, Features and Techniques

Unit 5

Unit Objectives
Understand heterogeneous joins
Use the Joiner transformation in a mapping
Practice using Designer features and techniques

Unit 5

Heterogeneous Joins
Heterogeneous joins cannot be performed on a single database, e.g.
Oracle table and DB2 table
Flat file and database table
Two flat files
Use a Joiner transformation (performs the join within the mapping)
One source is designated the Master, the other Detail
The Joiner select rows from the two sources based on a join condition,
e.g. matching customer ID

Master Source
Joiner
Detail Source

Join Results

Join Condition:
Master.CustomerID
= Detail.CustomerID
Unit 5

Joiner Transformation
Performs heterogeneous joins on two data flows
Enter join condition

Active
Ports
Input or input/output
One source is designated
Master, the other Detail.
Check M column for
ports from Master source
Usage examples:
Join two flat files
Join two tables from
different databases
Join a flat file with a
relational table

Unit 5

Specify Join Type

Unit 5

Join Types
Normal (inner) join keeps only
matching rows based on the condition
Master outer join - keeps all rows from
Detail and matching rows from Master
Detail outer join - keeps all rows from
Master and matching rows from Detail
Full outer join - keeps all rows from both
Master and Detail
Unit 5

Shortcuts

A shortcut is a dynamic link to the original object

If the object is edited, all shortcuts inherit the changes

Original object must be in a shortcut folder


In same repository called a local shortcut
In a global repository called a global shortcut (not used in this course)

Create a shortcut by dragging the object into another open folder or


into a mapping

Shortcuts appear in the Navigator window with a small curved arrow

Unit 5

Unit 5 Lab A
Load Sales Transaction Staging Table
Staging
Area

Source

STG_PRODUCT (table)
Sales_transactions
(flat file)

Join
STG_TRANSACTIONS
(table)

Create a mapping using a Joiner transformation (heterogeneous join)


Create/run a workflow for this mapping

Unit 5

Lab A Review
What did we accomplish with this lab?
Questions?

Unit 5

Unit 5 Lab B
Features and Techniques I
Practice using Designer features and techniques:

Auto Arrange

Remove Links

Revert to Saved

Link Path

Propagating Ports

Shortcut to Port Editing from


Normal View

Create Transformation Methods

Scale-To-Fit

Designer Options

Autolink by Name and Position


Moving Ports

Object Shortcuts and Copies


Copy Objects Within and
Between Mappings

Unit 5

10

Lab B Review
What did we accomplish with this lab?
Questions?

Unit 5

11

Unit 5 Quiz
1. What types of joins are there?
2. When would you use a Joiner transformation rather
than joining in a Source Qualifier?
3. What kinds of ports can the Joiner transformation
have?
4. When would you use shortcuts?

Unit 5

12

Das könnte Ihnen auch gefallen