How to create custom function for Calculation where settlement date determines multiplier?
**This post was created as part of a How to Service Request (SR)
Release:
23B
Summary of the question:
How to create custom function for Incentive Compensation which gives the following data -
SELECT
EARN_TRX.OUTPUT_ACHIEVED * NVL((Select 0 from dual where Months_Between(TO_DATE(:2,'DD/MM/YYYY'),TO_DATE(BASE_TRX.ATTRIBUTE21,'DD/MM/YYYY')) > 18),nvl((Select .5 from dual where Months_Between(TO_DATE(:2,'DD/MM/YYYY'),TO_DATE(BASE_TRX.ATTRIBUTE21,'DD/MM/YYYY')) > 12 and Months_Between(TO_DATE(:2,'DD/MM/YYYY'),TO_DATE(BASE_TRX.ATTRIBUTE21,'DD/MM/YYYY')) <=18),nvl((Select 1 from dual where Months_Between(TO_DATE(:2,'DD/MM/YYYY'),TO_DATE(BASE_TRX.ATTRIBUTE21,'DD/MM/YYYY')) <= 12),0)))