Sunteți pe pagina 1din 3

Practice 6-1

Practice
Practice 6-1
6-1
Using
Using application
application table
table values
values for
for validation
validation

Copyright Oracle Corporation, 2000. All rights reserved.

Practice 6-1 Instructions


Scenario
In this practice, you will use an application table to validate a descriptive
flexfield segment. You will create a table-validated value set to validate
employee numbers based on a Human Resources application table called
PER_ALL_PEOPLE_F. Then you will add an additional segment to the
descriptive flexfield structure you defined in Practice 5-4 to track the
salespersons employee number.
Step 1: Define a Value Set
Use the Value Sets window to define a table-validated value set named
XX_EMP_NUM. Give the value set a description, a format type of Char, and a
maximum size of 30. Enable security and Longlist for the value set.
Specify the table PER_ALL_PEOPLE_F in the Oracle Human Resources
application as the validation table. Assign the Value column the column name
EMPLOYEE_NUMBER, a type of Varchar2, and a size of 30. Assign the
Meaning column the column name FULL_NAME, a type of Varchar2, and a
size of 240. Restrict the value set to include only active employees by
specifying the following Where/Order By clause:
WHERE CURRENT_EMPLOYEE_FLAG = Y
Step 2: Define the Structure (Segment)

Copyright Oracle Corporation, 2000. All rights reserved.

Using Advanced Validation Capabilities


Chapter 6 - Page 11

After defining your value set, use the Descriptive Flexfield Segments window to
define the structure for your descriptive flexfield. For the purposes of this
practice, use the same descriptive flexfield that you worked on previously to
enter your new structure. Unfreeze the flexfield definition first so that you can
change the structure.
You can keep the two segments that you defined previously for the Global Data
Elements context. Now define a new segment for the Global Data Elements
context. Name the segment Employee Number, with a prompt of Employee
Number. Assign the segment the number 30, the column ATTRIBUTE3, and
the value set XX_EMP_NUM.
Ensure that the new segment is displayed and enabled. When you finish
defining the structure, freeze and compile your flexfield definition.
After defining your value set and segment, navigate to your descriptive flexfield
and test the results of your work. When you are finished, exit without saving.
Practice 6-1 Solutions
Step 1: Define a Value Set
1 Navigate to the Value Sets window.
System Administrator: (N) Application>Validation>Set
2 Enter the information for the value set in the following fields:
Value Set Name: XX_EMP_NUM
Description: XX Employee Number Value Set
Security Available: Selected
Enable Longlist: Selected
Format Type: Char
Maximum Size: 30
Validation Type: Table
3 Click the Edit Information button to navigate to the Validation Table
Information window.
4 Use the lists of values in the Table Application and Table Name fields
to select Oracle Human Resources as the table application and
PER_ALL_PEOPLE_F as the table name.
5 In the Table Columns region, use the lists of values in the following
fields to select this information for the Value column:
Name: EMPLOYEE_NUMBER
Type: Varchar2
Size: 30
6 In the Table Columns region, use the lists of values in the following
fields to select this information for the Meaning column:
Name: FULL_NAME
Type: Varchar2

Copyright Oracle Corporation, 2000. All rights reserved.

Using Advanced Validation Capabilities


Chapter 6 - Page 12

Size: 240
7 In the Where/Order By field, enter
WHERE CURRENT_EMPLOYEE_FLAG = Y
8 Save your work.
Step 2: Define the Structure (Segment)
1 Navigate to the Descriptive Flexfield Segments window.
System Administrator: (N) Application>Flexfield>
Descriptive>Segments
2 Query your descriptive flexfield.
3 Clear the Freeze Flexfield Definition check box.
4 In the Context Field Values region, select the Global Data Elements
context and click the Segments button to navigate to the Segments
Summary window.
5 Keep the two segments that you defined previously.
6 Enter the information for the third segment in the following fields:
Number: 30
Name: Employee Number
Window Prompt: Employee Number
Column: ATTRIBUTE3
Value Set: XX_EMP_NUM
Displayed: Selected
Enabled: Selected
7 Save your work.
8 Navigate back to the Descriptive Flexfield Segments window.
9 Select the Freeze Flexfield Definition check box.
10 Click the Compile button to compile the flexfield definition.
After defining your value set and segment, navigate to your descriptive
flexfield and test the results of your work. When you are finished, exit
without saving.

Copyright Oracle Corporation, 2000. All rights reserved.

Using Advanced Validation Capabilities


Chapter 6 - Page 13

S-ar putea să vă placă și