2. Slide No. 2
Flexfields
Purpose and Applications
• Flexibility to implement Code Structure
• Flexibility to capture Additional Information
3. Slide No. 3
Flexfields
As the name suggests, a flexfield is a “Flexible Field”.
A flexfield is a field made up of segments (which are
actually table columns). Each segment has a name that can
be assigned, and a set of valid values.
There are two types of flexfields in Oracle Applications: Key
flexfields (KFF) and descriptive flexfields (DFF).
Using key and descriptive flexfields, you give end users the
ability to customize your application to match their
business needs, without programming.
4. Benefits of Flexfield
Flexfields provide you with the features you need to satisfy the following business needs:
• Customize your applications to confirm to your current business practice for accounting
codes, product codes, and other codes.
• Customize your applications to capture data that would not otherwise be tracked by your
application.
• Have ”intelligent fields” that are fields comprised of one or more segments, where each
segment has both a value and a meaning.
• Rely upon your application to validate the values and the combination of values that you enter
in intelligent fields.
• Have the structure of an intelligent field change depending on data in your form or application
data.
• Customize data fields to your meet your business needs without programming.
5. Slide No. 5
Key-Flexfields
A key flexfield represents an “intelligent key” that uniquely
identifies an application entity.
Each key flexfield segment has a name you assign, and a
set of valid values you specify. Each value has a meaning
which can be specified.
A key flexfield provides with a flexible ”code” data structure
that users can set up however they like using key flexfield
segments.
6. Slide No. 6
Key-Flexfields
Key flexfields let you satisfy the needs of different
customers as per their business practices, without having
to reprogram the application.
For each segment one can also define valid values for each
segment, as well as cross–validation rules to describe valid
segment combinations.
Oracle General Ledger’s Accounting Flexfield is an example
of a key flexfield used to uniquely identify a general ledger
account.
7. Slide No. 7
Key Flexfields
You could use the Item Flexfield in an inventory application
to uniquely identify inventory parts. It could contain such
segments as product class, product code, size, color and
packaging code.
You could define valid values for the color segment, for
example, to range from 01 to 10, where 01 means red, 02
means blue, and so on.
You could even specify cross–validation rules to describe
valid combinations of segment values.
• For example, products with a specific product code may only be
available in certain colors.
8. Slide No. 8
Key-Flexfield
A Flexfield Segment Is a Single Sub-field of a Flexfield
Each segment is a single column of a table.
Flexfield segments are usually validated against a set of
valid values, called a value set.
Key Flexfields Identify an Entity
Key flexfields serve as an intelligent primary key, where
each segment contains meaningful information.
Key flexfields are integral parts of a form. They appear as
normal fields until the flexfield window pops up.
Often the segment descriptions also appear on the form
in a concatenated-values field.
10. Oracle Applications Key Flexfields
Accounting
Category
Asset
Location
Oracle
Assets
Oracle
General
Ledger
Account Aliases
Item Catalogs
Item Categories
Sales Orders
Stock Locators
System Items
Oracle
Inventory
Bank Details
Cost Allocation
People Group
Oracle
Payroll
Grade
Job
Personal Analysis
Position
Soft Coded
Oracle
Human
Resources
Territory
Sales Tax Location
Oracle
Receivables
Oracle Service Item
Oracle
Service
11.
12. Slide No. 12
Accounting Keyflexfield
Has special features and is used for Chart of Account definition
Requires setup of
• Flexfield Qualifiers
• Segment qualifiers
• Parent-Child Relationship and Hierarchy
• Segments used with Rollup groups
Features for Security
Features : Dynamic Insert
Valueset Security
Cross validation Rules
Shorthand Alias
13. Key Flexfields in Oracle Applications
Owner Name Code
Oracle Assets Asset Key Flexfield KEY#
Oracle Assets Category Flexfield CAT#
Oracle Assets Location Flexfield LOC#
Oracle General
Ledger
Accounting Flexfield GL#
Oracle Human
Resources
Grade Flexfield GRD
Oracle Human
Resources
Job Flexfield JOB
Oracle Human
Resources
Personal Analysis
Flexfield
PEA
14. Owner Name Code
Oracle Human
Resources
Position Flexfield POS
Oracle Human
Resources
Soft Coded KeyFlexfield SCL
Oracle Inventory Account Aliases MDSP
Oracle Inventory Item Catalogs MICG
Oracle Inventory Item Categories MCAT
Oracle Inventory SalesOrders RLOC
Oracle Inventory Stock Locators MTLL
Oracle Inventory System Items MSTK
Key Flexfields in Oracle Applications
15. Owner Name Code
Oracle Payroll Bank Details KeyFlexField BANK
Oracle Payroll Cost Allocation Flexfield COST
Oracle Payroll People Group Flexfield GRP
Oracle
Receivables
Sales Tax Location Flexfield MKTS
Oracle
Receivables
Territory Flexfield CT#
Oracle Service Oracle Service Item Flexfield SERV
Oracle Training
Administration
Training Resources RES
Key Flexfields in Oracle Applications
16. Slide No. 16
Descriptive Flexfields
Descriptive flexfields provide customizable ”expansion
space” to capture information which otherwise is not
captured by the application.
It lets you satisfy different groups of users without having
to reprogram your application.
17. Slide No. 17
Descriptive Flexfields
Descriptive flexfields can be context sensitive, where the
information your application stores depends on other
values your users enter in other parts of the form.
Each descriptive segment has a name you assign. You
can specify valid segment values or set up criteria to
validate the entry of any value.
Example : Customer Retail info, Asset info based on
asset type.
18. Slide No. 18
Descriptive Flexfield
A Field Made Up of Sub-fields
Flexfields appear in a pop-up window on a form.
Flexfields are implemented as a set of database columns,
with one column for each segment.
The brackets [ ] indicate the presence of a descriptive
flexfield.
When the cursor reaches the brackets, the descriptive
flexfield pops open.
If the descriptive flexfield is not enabled, the cursor skips
over the brackets.
19.
20. Slide No. 20
Flexfields
Customizing Flexfields
• Customizing a flexfield means specifying the prompt, length
and data type of each flexfield segment.
• It also includes specifying valid values for each segment, and
the meaning of each value to your application.
• You or your end users can even define cross–validation rules
to specify valid combinations of segment values ( in case of
Key Flexfields)
21. Slide No. 21
Flexfields
A Flexfield May Have One or More Structures
Both key and descriptive flexfields can have more than one
structure.
Standard report submission parameter windows behave as
descriptive flexfield structures.
• Each parameter acts as a segment.
• Tailor structures for specific end-user needs.
22. Slide No. 22
Flexfields
Multiple Structures
• Flexfields lets you define multiple segment structures for the
same flexfield.
• Your flexfield can display different prompts and fields for
different end users based on a data condition in your form or
application data.
• Most of the features used with your flexfield segments also
apply to your parameter window for Standard Request
Submission programs.
23. Slide No. 23
Definitions
Segment
• For a key flexfield, a segment is a single piece of the complete
entity code ( like item part code)
• For a descriptive flexfield, a segment is a single field or a single
attribute of the entity
• A segment is represented by a single column in a table.
• A segment is a single sub–field within a flexfield.
• You define the appearance and meaning of individual
segments when customizing a flexfield.
24. Slide No. 24
Definitions
Combination
• For a key flexfield, a combination of segment values that make
up the complete code or key.
• You can define valid combinations with simple cross–validation
rules when you customize your key flexfield.
25. Slide No. 25
Definitions
Structure
• A flexfield structure is a particular arrangement of flexfield
segments.
• The maximum size of the structure depends on the individual
flexfield.
• A flexfield may have one or more structures. Both key and
descriptive flexfields can have more than one structure.
• Users can tailor structures for specific needs.
• If you add or remove segments, or rearrange the order of
segments in a flexfield, you get a different structure.
26. Slide No. 26
Definitions
Values, Validation and Value Sets
• Your end user enters a segment value into a segment while
using an application. Generally, the flexfield validates each
segment against a set of valid values (a ”value set”) that are
usually predefined.
27. Slide No. 27
Definitions
Combinations Table
• For a key flexfield, a database table you include in your
application to store valid combinations of key flexfield segment
values.
• Each key flexfield must have a combinations table. It contains
columns for each flexfield segment, as well as other columns.
This is the same table you use as your entity table.
Combinations Form
• For a key flexfield, a combinations form is the form whose base
table (or view) is the combinations table. The only purpose of
the combinations form is to maintain the combinations table.
28. Slide No. 28
Definitions
Dynamic Insertion
• Dynamic insertion is the insertion of a new valid combination
into a key flexfield combinations table from a form other than
the combinations form.
• All validation rules still will apply during insertion
Structure Defining Column
• A column you include in a combinations table or entity table so
the flexfield can support multiple segment structures.
29. Slide No. 29
Customizing a DFF
Planning a Descriptive flexfield.
• The planning phase can be broken into smaller, though still
interrelated, steps:
– Decide which flexfields to implement
– Learning about a specific flexfield
– Planning the structure
– Planning the segments
– Planning the segment validation
– Planning to use additional features
– Documenting your plan
30. Slide No. 30
Customizing a Flexfield
Customize the Flexfield’s Appearance
• Flexfield title
• Number and order of segments
• Prompts
• Value sets, values, and value descriptions
Use Flexfield Functionality for Validation
• Pop-up windows
• Individual segment validation
• Cross-segment validation
Customize to the Situation
• Flexfields allow the application to adjust to fit specific business needs.
• Use multiple structures to match different needs in different situations.
31. Slide No. 31
Customizing a DFF
Planning the segment validation
• For each segment, plan your validation. Consider what types of
values you will be using in your flexfield segments. These
decisions affect how you set up your value sets and values.
• Plan for field prompts
• Define dependencies among the segments or customize a
descriptive flexfield to display context–sensitive segments, so
that different segments or additional pop–up windows appear
depending on the values you enter in other fields or segments.
32. Slide No. 32
Different Structures
One Flexfield Captures Different Information
Use different structures for different situations.
Make the flexfield structure depend automatically on the
value of another field. This is called using a reference field.
Define the flexfield to allow choosing the structure when
entering the flexfield. This is called using a context field.
33. Slide No. 33
Structures Concept
For a descriptive flexfield, a structure consists of any global
segments plus all context-sensitive segments for a particular
context field value.
Context-sensitive structures are all the segments defined for a
context field value.
34. Slide No. 34
Customizing a DFF : Reference field
Planning for Reference Fields
• Reference fields are fields from which a descriptive flexfield can
get a context field value (optional, but recommended).
• Reference fields must be separate fields Frequently, most of the
existing (non–flexfield) fields in your form can also serve as
reference fields.
• They are NOT the structure defining field (typically
ATTRIBUTE_CATEGORY is a structure defining field).
• Good reference fields are those that have a short, fairly static list
of possible values.
35. Slide No. 35
Customizing a DFF
Planning for Reference Fields
• You specify fields as reference fields when you register your
descriptive flexfield in the Register Descriptive Flexfield form.
Your users then have the option of using a reference field or not
when they set up your flexfield.
• Reference field is just an ordinary field on the form before you
choose to use it as a reference field
• Use a reference field on the form to derive a context field value.
36. Slide No. 36
Context field
Determine which context-sensitive structure appears with a
context field.
Context Fields is NOT a Segment.
The context field has a context field prompt.
The response, called a context field value, determines which
group of context-sensitive segments appears next.
Each value for the context field can correspond to a separate
context-sensitive structure.
Context fields do not always display. Non-displayed context
fields derive values from a default or from a reference field,
and the user cannot change the context field value.
37. Slide No. 37
Elect to Hide the Context Field
Use a reference field to supply the context field value. The
context field never appears, so that users cannot change the
value.
Or, use the reference field as a default but allow users to
override. Visible context fields are alterable.
Change the value of the context field without changing the
value in the reference field.
Context field
38. Slide No. 38
Customizing DFF
Create different context-sensitive segments to appear only
for a particular context field value. Different context field
values cause different context-sensitive segments to pop
open.
39. Slide No. 39
Global Field
Define global segments that always appear in the
descriptive flexfield pop-up window, regardless of context
(any other information in the form).
Define global segments before any context-dependent
structures.
40. Slide No. 40
Customizing a DFF
Planning Validations
• Choose a Validation Type for Your Value Set. There are several
validation types that affect the way users enter and use segment
or parameter values:
• None (not validated at all)
• Independent
• Dependent
• Table
• Special (advanced)
• Pair (advanced)
• Translatable Independent
• Translatable Dependent
41. Slide No. 41
Building & Implementing a DFF
There are 4 main steps to implement a DFF.
• Define the DFF Database columns in the table (ATTRIBUTEn
VARCHAR2(150)
• Define the Structure column ATTRIBUTE_CATEGORY
VARCHAR2(30)
• Register the table and its columns with AOL.
• Register the DFF and its segments using proper value sets as
per the plan prepared.
• Add Flexfields to Forms
42. Slide No. 42
Adding Flexfields to Forms
There are four basic parts to calling a flexfield from an
Oracle Forms window. These steps apply to both key and
descriptive flexfields.
To code a flexfield into your form :
• Create your hidden fields
• Create your displayed fields
• Create your flexfield definition
• Invoke your flexfield definition from several event triggers
43. Slide No. 43
Flexfield Underlying Table
Table have flexfield columns as any other columns defined as per
standard suggested by oracle.
Attribute columns are built in by the developer. Their number
cannot increase.
Use only as many segments as the table has available columns (for
a single flexfield structure that contains both global and context-
sensitive segments).
Most columns called Attribute#. ( 1 to 15)
Attribute_category is used as structure column and stores the
context value.
Global segments use the same column in all flexfield structures.
Context-sensitive segments use a column only for that particular
structure.
44. Slide No. 44
DF Table Definition
Context-sensitive Segments Can Reuse Columns
Since context-sensitive segments only use columns for
their particular structure, two segments in different context-
sensitive structures can share the same column.
Defining global segments first prevents wastefully using all
columns for context-sensitive segments.
45. Slide No. 45
View Generation
A view is generated by AOL to allow access data based on
the descriptive flexfield definition
46. Slide No. 46
Customizing a DFF options
Use a combination of these features to create a descriptive
flexfield.
What Kind of Segments
Create global segments ?
Create context-sensitive segments ?
A context field that the user sees (override allowed Yes) ?
How to choose which context-sensitive segments
appear/populate the context field ?
Choose which context-sensitive segments appear by using a
reference field ?
Specify a default context field value ? (to choose which
context-sensitive segments appear by default)
47. Validating Input Using Value Sets
__ Item Information _________
Category
Item
Computer
Monitor
COM
876
COM APPL FURN
Category value set
Item value set
876
755 933
48. None Validation is minimal
Independent Input must exist on previously
defined list of values.
Dependent Input is checked against a subset of
values based on a prior value.
Table Input is checked against values in an
application table.
Special Value set uses a flexfield itself.
Types of Value Sets
49. Pair Two flexfields together specify
a range of valid values.
Translatable Independent Input must exist on previously
defined list of values;
translated value can be used.
Translatable Dependent Input is checked against a
subset of values based on a
prior value; translated value
can be used.
Types of Value Sets
50. Validation Type None
Values are checked for expected data type,
length, and so on.
Values are not checked against an approved values list.
Examples include credit card number, street address, phone
number.
51. Independent Value Sets
__ Item Information _________
Category
Item
Computer
Monitor
COM
876
COM APPL FURN
Category value set
52. Dependent Value Sets
Category value set Item value set
COM Computer
APPL Appliances
FURN Furniture
755 Modem
876 Monitor
933 Printer
320 Microwave
560 Refrigerator
876 Washer
877 Desk
154 Table
677 Bunk Bed
53. Table-Validated Value Sets
WHERE
REGION =
‘Western’
Cities_West
value set
Customer table
Acme Computers
North Bay Foods
Midwest Grain
Southern Milling
Rockies Mining
San Jose
Boston
Chicago
Charleston
Denver
Western
Eastern
Eastern
Southern
Western
Name City
Region
San Jose Denver
54. Slide No. 54
Value Sets
Value Set Options
Set Options Format Type Validation Type
Name Format Type Independent
Description Maximum Length Dependent
Security Available Precision None
LongList Enabled ? Alphabetic Characters? Table
Uppercase Only? Special
Right-justify Zero-fill
Numbers?
Pair
Minimum Value
Maximum Value
55. Validation Types: Summary
*Application Object Library
Type List of Values
Available
Values Stored
In
None
Table
Special/Pair
N/A
Depends on value set
No
Independent
Dependent
AOL* Table
AOL* Table
Yes
Yes
Yes Application Table
Translatable
Independent
Translatable
Dependent
AOL* Table
Yes
AOL* Table
Yes
Depends on value set
56. Predefined Value Sets
Choosing a predefined value set limits the necessary
maintenance of values.
Most predefined value sets are table-validated value sets.
A useful value set is Yes_No, containing the values Yes and
No.
Never alter value sets provided by Oracle Applications,
especially the SRS value set.