on 03-06-2014 11:30 AM
Hi experts,
I want to realize the following IF/ELSE statement in a BEx Query in respect to the result values
If the result of KF1 equals 0, than set the KF2 to 0, Else (KF1 NE 0) show the value of KF2
Background: I want to report the order backlog. In the example above we have an incoming order value of 23.700,80 EUR in periode 12.2013 and an turnover of 22.370,80 EUR in periode 01.2014. The order backlog in ST (KF1) is 1 ST (12.2013) - 1 ST (01.2014) = 0 ST. The order backlog in EUR (KF2) is 23.700,80 EUR (12.2013) - 22.370,80 EUR (01.2014) = 1.330 EUR. The Order and Invoice is finished, but we have an positive order backlog in EUR (reason: less turnover as incoming order).
For this case I want to realize the IF/Else statement to check if the oder backlog in ST = 0, if yes, than set the order backlog in EUR also to 0.
Any best practices?
Many thanks and best regards,
Michael
Use this in KF2 definition : ( KF1 == 0 )* 0 + KF2
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Suman,
thanks aigain for your reply!
I have tried your proposal before you have posted it.
In my special case the following if/else statement works successfully:
CKF = calculated key figure
Formula1 = (CKF1 == 0) * 0 + (CKF1 <> 0) * CKF2
In my case the CKF2 is the result value from "Incoming Order value" - "Turnover"
So I had to define a separate Formula (1:1 equals to CKF2) and then I was able to set "*CKF2" in the statement.
The statement CKF2 = (CKF1 == 0) * 0 + CKF2 is not possible (because it´s not possible to calculate from CKF2 itself).
Now it works
Best regards,
Michael
User | Count |
---|---|
81 | |
25 | |
12 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.