Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi friends,
i need to get Earned Premium of year wise.my requirement is
IF(TP_POL_TO_DT>vCurrentYear)=(sum((TP_PREM_LC_1-TP_DISC_LC_1)+(TP_LOAD_LC_1)-(TP_BRK_COMM_LC_1-TP_INW_COMM_LC_1))/(TP_POL_TO_DT-TP_POL_FM_DT))*(vCurrentYear-TP_POL_FM_DT))
else
Earned Premium=Premium.
Please convert the above expression to set analysis.
Please check my expression is there any wrong in this applying set analysis because i'm not getting any data.
=sum({$<year={"TP_POL_TO_DT>vCurrentYear"}>}(sum((TP_PREM_LC_1-TP_DISC_LC_1)+(TP_LOAD_LC_1)-(TP_BRK_COMM_LC_1-TP_INW_COMM_LC_1)) /(TP_POL_TO_DT-TP_POL_FM_DT))*(vCurrentYear-TP_POL_FM_DT))
=if((TP_POL_TO_DT>vCurrentYear),(sum((TP_PREM_LC_1-TP_DISC_LC_1)+(TP_LOAD_LC_1)-(TP_BRK_COMM_LC_1-TP_INW_COMM_LC_1)) /(TP_POL_TO_DT-TP_POL_FM_DT))*(vCurrentYear-TP_POL_FM_DT))
Regards
Krishna
Try:
sum({$<year={"TP_POL_TO_DT>$(vCurrentYear)"}>}((TP_PREM_LC_1-TP_DISC_LC_1)+(TP_LOAD_LC_1)-(TP_BRK_COMM_LC_1-TP_INW_COMM_LC_1))/(TP_POL_TO_DT-TP_POL_FM_DT))*(vCurrentYear-TP_POL_FM_DT)
Dear Gysbert,
Thank you for your reply.If i want to give else condition in set analysis,how can i mention?
i have calculated like this.
=if(TP_POL_TO_DT>vCurrentYear,(sum((TP_PREM_LC_1-TP_DISC_LC_1)+(TP_LOAD_LC_1-TP_BRK_COMM_LC_1-TP_INW_COMM_LC_1)))/
(TP_POL_TO_DT-TP_POL_FM_DT)*(vCurrentYear-TP_POL_FM_DT),Sum((TP_PREM_LC_1-TP_DISC_LC_1)+TP_LOAD_LC_1))
Regards
krishna
You cannot do branching logic in set analysis. An else condition is not possible. If you need that then you need to use and if-else statement.
Is my above expression is correct?branching of expressions.
The branching looks ok.
Thank You..How can we assign '%' to the particular row?
Regards
Krishna