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
Learn about the new Oracle AI Agent Studio for Fusion Applications: Watch Now

Progress with Redwood: Redwood Resources for Oracle Cloud HCM -  Go Here
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.

Dependent Coverage End Date Fast Formula

edited Jul 2, 2021 6:14AM in Benefits 9 comments

Summary

Need a Fast Formula for Dependent Coverage End Date

Content

We have a requirement, when dependent turns 30 years, the coverage should end on last day of the Year. I have writen below FF but it is not working. TO calculate the age of dependent I use a DBI, it is picking the employee's DOB. Can someone help me to improve this FF.

 

Version

21A

Code Snippet

DEFAULT FOR PER_PER_DATE_OF_BIRTH is '1951/01/01 0:00:00'(date)
DEFAULT FOR BEN_PIL_LF_EVT_OCRD_DT is '1950/01/01 00:00:00'(date)

l_age = 0
l_eff_date = BEN_PIL_LF_EVT_OCRD_DT
l_eff_date_year = TO_CHAR(BEN_PIL_LF_EVT_OCRD_DT,'YYYY')
l_cov_end_date = '12/31/'||l_eff_date_year
l_dob = PER_PER_DATE_OF_BIRTH

l_log_data = ESS_LOG_WRITE('FF Start BEN_DEP_CVG_END_DATE')
l_log_data = ESS_LOG_WRITE('l_eff_date: '||TO_CHAR(l_eff_date))
l_log_data = ESS_LOG_WRITE('l_eff_date_year: '||l_eff_date_year)
l_log_data = ESS_LOG_WRITE('l_cov_end_date: '||l_cov_end_date)
l_log_data = ESS_LOG_WRITE('l_dob: '||TO_CHAR(l_dob))
l_log_data = ESS_LOG_WRITE('Age: '||TO_CHAR(MONTHS_BETWEEN(l_eff_date,l_dob)))


IF ( MONTHS_BETWEEN(l_eff_date,l_dob) = 360 ) THEN
(
l_output = TO_DATE(l_cov_end_date)
)

l_log_data = ESS_LOG_WRITE('FF End BEN_DEP_CVG_END_DATE')

return l_output

Howdy, Stranger!

Log In

To view full details, sign in.

Register

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