Thank you for supporting the Cloud Customer Connect Community in 2024. It's a gift to work with you!

Look back
You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register
Get Started with Redwood for Oracle Cloud HCM   Begin Now
To ensure that questions get required attention from community members and are NOT left unanswered, it’s important for the author to indicate (by selecting “Yes” or “No” when prompted) whether the question was answered. (newly added) Please note that it is also important to respond to EACH comment your question receives. Your Yes or No response ensures an accurate status for your question.

For more information, please refer to this announcement explaining best practices for getting answers to questions.

Getting CHANGE_CONTEXTS errors in fast formulas

Summary:

I need to find the previous location code of an employee. I have written a fast formula and getting change_contexts error.

Below is the code I used:

DEFAULT FOR PER_LOC_LOCATION_CODE IS '###'

ld_effective_date = GET_PARAMETER_VALUE_DATE('EFFECTIVE_DATE')

change_contexts(effective_date = ADD_DAYS(ld_effective_date,-1))
(
IF PER_LOC_LOCATION_CODE WAS NOT DEFAULTED
THEN RULE_VALUE = PER_LOC_LOCATION_CODE
)

RETURN RULE_VALUE

Error message:
ORA-20001: Context LOCATION_ID wasn't set when used at line 14 of formula RP_ADP_PREVLOCATION. Details: All database items context values must be set when using the database item. All formula functions context values must be set when calling the function. Context values can be set within a formula using a CHANGE_CONTEXTS statement. When writing formula make sure all the required context values are set. ORA-06512: at "FUSION.FF_EXEC", line 3796 ORA-06512: at "FUSION.FF_EXEC", line 3577 ORA-06512: at "FUSION_DYNAMIC.FFP300000049744182_01012000", line 2727 ORA-06512: at "FUSION.FF_EXEC", line 3796 ORA-06512: at "FUSION.FF_EXEC", line 397 ORA-06512: at "FUSION.FF_EXEC", line 3710 ORA-06512: at "FUSION.FF_EXEC", line 4466 ORA-06512: at

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!