Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
0 Essentials
17
Copyright 2007, Oracle. All rights reserved.
Module Objectives
2 of 18
Provide a way to group data according to business logic Are referenced by applets Specify access to tables (read, write, and update) Are used by business objects to provide data to views
Applet
View
Screen
Application
Business Layer
Field
Business Component
Data Layer
Column
Table
References
3 of 18
Business Component
A business component (BC) is a person, place, thing, or event about which data must be stored Represents a fundamental business entity Provides the foundation for controlling how data is selected, inserted, and updated in underlying tables
Opportunity
Opportunity
Quote
Product
Contact
= Business Component
Copyright 2007, Oracle. All rights reserved. 4 of 18
Arranges data from one or more tables into a logical grouping Consists primarily of fields and joins
Each field references a single column in a table
Is not a table
Does not store data Stores metadata: data about data
BC
Opportunity
Name Description Decision Level Sales Stage Sales Stage Phase
S_OPTY
ROW_ID NAME DESC_TEXT CURCY_CD
S_OPTY_X
ROW_ID PAR_ROW_ID ATTRIB_01 ATTRIB_09 ATTRIB_39
S_STG Field
ROW_ID
NAME
PHASE_CD
STG_ORDER
Base Table
Copyright 2007, Oracle. All rights reserved.
Joined Tables
5 of 18
Opportunity
Opportunity
Contact
Contact
Quote
Product
Contact
Quote
Product
Account
6 of 18
Base Table
Contains the main columns for the business component Every business component references only one base table Many BC fields are mapped to base table columns Fields referencing base tables are editable in the UI
Opportunity
Name Description Decision Level Sales Stage Sales Stage Phase
S_OPTY
ROW_ID NAME DESC_TEXT CURCY_CD
Base table
Mapping Example
Field: Description Business Component: Opportunity
Column: DESC_TEXT
Table: S_OPTY
7 of 18
Each business component contains a table property that specifies the base table
Base table
8 of 18
Join is blank
9 of 18
Explicit Join
Is a join that brings in data from tables other than the base table to meet the business components data display requirements
Most fields referencing explicitly joined tables are read-only in the applet
Includes a join definition and a join specification BC field references the join definition
Opportunity
Name
Description
Sales Stage
Base table
S_OPTY
ROW_ID NAME DESC_TEXT CURCY_CD
S_STG
ROW_ID
Joined table
PHASE_CD STG_ORDER
NAME
10 of 18
Join property specifies the join object definition being referenced Column property maps to a column in the joined table
11 of 18
Returns only one row from the joined table There is a 1:1 or 1:M relationship from the joined table to the BC Relationship is established using a FK column on the base table to join to the PK column on the joined table
Base Table
Joined Table
FK
PK
12 of 18
The UI layer specifies how information joined at the business layer will be displayed
S_OPTY
S_STG
13 of 18
Join Definition
Alias of join
Joined table
14 of 18
Join Specification
Specifies how to retrieve the related row from the joined table
Based on the foreign and primary keys used to relate the base and joined tables
Opportunity
Name Description Sales Stage Id
S_OPTY
ROW_ID
NAME DESC_TEXT CURCY_CD CURR_STG_ID
S_STG
ROW_ID NAME
PHASE_CD
STG_ORDER
FK
PK
15 of 18
Implicit Joins
Do not appear as Join object definitions Do appear in the picklist for the Join property in an SVF
Join property specifies the extension table being referenced Column property references a column in the extension table Field is editable in the UI
17 of 18
Module Highlights
A BC is a person, place, thing, or event about which data is stored A BC can be defined once then re-used by different BOs Each BC references a single base table A BC can include data from joined tables A join definition specifies joined table A join specification specifies how to access joined table via PK/FK An extension table extends data in the BC Fields on extension tables use implicit joins
18 of 18