Module 28 Business Layer Configuration Joins
-
Upload
realvasyapupkin -
Category
Documents
-
view
221 -
download
0
Transcript of Module 28 Business Layer Configuration Joins
-
7/30/2019 Module 28 Business Layer Configuration Joins
1/25
Business Layer Configuration: Joins 1 of 24
Siebel 8.0 Essentials
-
7/30/2019 Module 28 Business Layer Configuration Joins
2/25
Module 27: Business Layer Configuration: Joins
-
7/30/2019 Module 28 Business Layer Configuration Joins
3/25
Business Layer Configuration: Joins 3 of 24
Module Objectives
To create a join that brings data from:
A standard table into a standard business component
A party table into a standard business component
A party table into another party business component
-
7/30/2019 Module 28 Business Layer Configuration Joins
4/25
Business Layer Configuration: Joins 4 of 24
Joined Tables
Business components are primarily based on a Base Table, but they
can include data from other related joined tables
Base TableJoined Table
Service Request
SR # Area Entitlement
SR_NUM
SR_AREA
RTNG_CD
S_SRV_REQ S_ENTLMNT
AGREE_CD
EFF_END_DT
ENTLMNT_NUM
-
7/30/2019 Module 28 Business Layer Configuration Joins
5/25
Business Layer Configuration: Joins 5 of 24
Joined Tables
Three definitions are used to implement a join:
Join Definition specifies the joined tableJoin Specifications specify the Foreign Key and Primary Key used to relate
the base and joined tables
Single-Value Field references the join object definition
1. Join
Definition
2. Join
Specification
3. SVF
-
7/30/2019 Module 28 Business Layer Configuration Joins
6/25
Business Layer Configuration: Joins 6 of 24
Join Example
From
S_SRV_REQ From
S_ENTLMNT
-
7/30/2019 Module 28 Business Layer Configuration Joins
7/25Business Layer Configuration: Joins 7 of 24
Steps to create a Join
1. Locate the data source
2. Examine existing joins
3. Diagram the join
4. Create the join definition
5. Create the join specification
6. Map the Single Value Field(s)
-
7/30/2019 Module 28 Business Layer Configuration Joins
8/25Business Layer Configuration: Joins 8 of 24
1. Locate the data source
Identify what data you need and find out where it resides in the
application
The required data could exist in another business component
Once the data is identified, find out which table and column the data
resides inTrace down from the UI element to the table column
-
7/30/2019 Module 28 Business Layer Configuration Joins
9/25Business Layer Configuration: Joins 9 of 24
2. Examine existing joins
Determine if the required join between the tables already exists
Many commonly used joins are already provided, check through them
Use an existing join if it meets the requirements
If yes, check whether
Join Specifications matchyour requirements
Examine if Table
is already
joined
-
7/30/2019 Module 28 Business Layer Configuration Joins
10/25Business Layer Configuration: Joins 10 of 24
3. Diagram the join
The Join Diagram template gives all details about the join
Business Component: Service Request
Single Value Field: Entitlement Id
S_SRV_REQ
ROW_ID
S_ENTLMNT
ROW_ID
NA
ME
1. Business
Component
2. Base Table
3. Joined Table
4. Joined table
column
5. Foreign
Key Column
6. Primary
Key
Column
7. Single-Value Field
FKPK
AGREE_ID
NA
ME
-
7/30/2019 Module 28 Business Layer Configuration Joins
11/25Business Layer Configuration: Joins 11 of 24
4. Create the Join Definition
The join definition is created in the Join child object definition under
the Business Component object
The Table property specifies the joined table
The Alias property is the name of the join definition
Defaults to the joined tables name
Joined Table
Name of Join
Alias value defaults to
joined table name. If
multiple Joins to same
Table, modify the Alias to
a meaningful name
-
7/30/2019 Module 28 Business Layer Configuration Joins
12/25Business Layer Configuration: Joins 12 of 24
5. Create the Join Specification
In the Join Specification child object definition, specify the foreign key
and the primary key
The foreign key is specified in the Source Field property
The primary key column is specified in the Destination Column property
FK PK
-
7/30/2019 Module 28 Business Layer Configuration Joins
13/25Business Layer Configuration: Joins 13 of 24
6. Map the SVF(s)
In the Single Value Fields child object definition, specify the business
component field name, the joined table and the column name of thejoined table
SVF specifies the data you seek
The join specifies how you access the data
BC SVF Field
name
Join references
S_ENTLMNT table
Entitlement Name
SVF references NAME
column in joined table
-
7/30/2019 Module 28 Business Layer Configuration Joins
14/25Business Layer Configuration: Joins 14 of 24
Outer Join Flag
It is set to TRUE to return all records from the base table, even when
there is no related row in the joined table If there is always a related row in the joined table, do not keep Outer
Join Flag as TRUE. It affects performance
Outer Join
enabled
-
7/30/2019 Module 28 Business Layer Configuration Joins
15/25Business Layer Configuration: Joins 15 of 24
Outer Join Flag
When Outer Join Flag is TRUE, a left outer join is used
All records in source table are displayed, even if there is no related record in
the Joined table
Records with no related record in target table display target values as NULL
-
7/30/2019 Module 28 Business Layer Configuration Joins
16/25Business Layer Configuration: Joins 16 of 24
Joins and Party Business Data
Joins and Party Business Components
Bringing Party Data into a Standard Business Component
Bringing Party Data into a Party Business Component
-
7/30/2019 Module 28 Business Layer Configuration Joins
17/25Business Layer Configuration: Joins 17 of 24
Joins and Party Business Components
The base table for party business components is S_PARTY
The main data is stored in extension tables of S_PARTYAn implicit join is used to reference fields from extension tables
Appears in Join property on SVF
Is used when relationship between tables is known
Doesnt appear as Join object definition
Account
Name Type Location
S_PARTY
ROW_ID
NAME
PARTY_TYPE_CD
PARTY_UID
S_ORG_EXT
ROW_ID
NAME
LOC
PAR_ROW_ID
OU_TYPE_CD
FKPK
Most columns
use join to
S_ORG_EXT
-
7/30/2019 Module 28 Business Layer Configuration Joins
18/25Business Layer Configuration: Joins 18 of 24
Bringing Party Data into a Standard BC
Example: Bringing Account data into the Opportunity BC
Data from
Opportunity
BC
Data from
Account brought
into OpportunityBC
-
7/30/2019 Module 28 Business Layer Configuration Joins
19/25Business Layer Configuration: Joins 19 of 24
Bringing Party Data into a Standard BC
Three definitions bring Party Data into Standard BC:
The Join Definition specifies which S_PARTY extension table to be usedThe Join specification specifies to use PAR_ROW_ID
The SVF is the desired column from the joined extension table
1. Join Definition
2. Join
Specification
3. Single Value
Field
-
7/30/2019 Module 28 Business Layer Configuration Joins
20/25
Business Layer Configuration: Joins 20 of 24
Join specification with Party
It is similar to that for Standard with the following differences:
Destination references PAR_ROW_ID, and not ROW_ID
Keys reference base to extension to join, rather than base to join
S_CONTACT
ROW_ID
PR_ED
EPT_OU_ID
ROW_ID
N
AME
PAR_ROW_ID
S_PARTY
ROW_ID
FK PK FK PK
Typically references
PAR_ROW_ID,
instead of ROW_ID
like in standard
S_ORG_EXT
-
7/30/2019 Module 28 Business Layer Configuration Joins
21/25
Business Layer Configuration: Joins 21 of 24
Bringing Party Data into a Party BC
Name Location Parent Account Name
This account
references the
top account
-
7/30/2019 Module 28 Business Layer Configuration Joins
22/25
Business Layer Configuration: Joins 22 of 24
Bringing Party Data into a Party BC
The Join definition must use an explicit join to an extension table
based on appropriate foreign keys It must not use an existing implicit join to that extension table
An explicit join is
used since an
implicit join to
S_ORG_EXT
already exists
-
7/30/2019 Module 28 Business Layer Configuration Joins
23/25
Business Layer Configuration: Joins 23 of 24
Map Field to Column in Party Table
Select the appropriate explicit join
Select the desired column of the joined table
Set the appropriate type (DTYPE_TEXT, etc)
-
7/30/2019 Module 28 Business Layer Configuration Joins
24/25
Business Layer Configuration: Joins 24 of 24
Module Highlights
BCs can include data from related joined tables Join definitions and join specifications define how to access joined
table data
Single-value fields reference the join definition and define the field to
access in the joined table
To create a join:Locate the data source, examine existing joins, diagram the join, create the
join definition, create the join specification, and define the SVF
Joins that involve party data are similar to standard data; however,
when bringing party data into:
A non-party BC, create a join specification based on PAR_ROW_ID
A party BC, use the appropriate explicit join
-
7/30/2019 Module 28 Business Layer Configuration Joins
25/25
B i L C fi i J i
Lab
In the lab, you will:
Examine references when a join is not present and when a join is present
Create a join that brings in data from joined table and display it in the UI