Professional Documents
Culture Documents
Run query in BI publisher to find the ABSENCE_PLAN_ID for Absence type that will be selected on
Manage Absence records page.
SELECT A.absence_type_id
FROM anc_absence_types_f A
,anc_absence_types_f_tl B
Output:
Plan ABSENCE_PLAN_ID
Ali Planned End Date Type 300000106791904 – we are picking this for our test below.
Step 2.
Step 3.
a) Set Context name same as Absence type (Ali Planned End Date Type)
So, in this example, For Ali Planned End Date Type, from above query output, ABSENCE_TYPE_ID is
300000106791904. Use this 300000106791904 as the "Context Code" instead of name.
Save.
Within Context Sensitive Segments above, click “Create” to take you to “Create Segment” page below:
Fill up required values, like Name, Data type, value set, etc as per your requirements.
FYI - Click View Value set,
Click Done
Deploy FlexField
Step 5: Test the setup by adding a absence type via Manage Absence Records
Add a new record, by selecting random Absence type than one which was setup, lets say, Ali Military
Now, Add a new record, by selecting our test Absence type Ali Planned End Date Type
As seen above, Context Segment, which was setup earlier is defaulted automatically when Type is
selected as Ali Planned End Date Type. “Generic” segment with value set as 20 characters displayed as
well. This is how one can display different fields depending on absence type being selected.
“The context needs to be created for all absence types. For absence types where no value is required,
create dummy contexts with the Absence_Type_ID. If this is not done, there may get an error when
selecting an absence type for which there are no defined contexts.”
Random errors like one below can be seen when selecting absence type, hence suggestion to have
dummy contexts created (without any segments)
To avoid any such errors seen, it is recommended to create blank contexts for remaining absence types
(without any segments) for ALL absence types that exist in your setup.
Save
Done
Deploy again
Context Ali Military defaults automatically upon selection of Ali Military Ali LE type.