Need to write a statement.Please help.
A and B,B1,B2 are Key Figures
Condition 1: A> B
Condition 2 : A< B
Condition 3: A==B
Condition 4: B=-B
Created a formula i.e CKF as C.So formula should be like this below.But i am not getting the desired output.
(Condition==1) * NOERR (NODIV ( ( A/B ) ) ) * 30 + (Condition 2==1) * NOERR ( NODIV( ( ( A- B-B1)/B2 * 30 + 60) ) ) + (Condition3==1) * NOERR (NODIV( (A/B)))* 30 +
(Condition4==1) * 0
Result i want to get is :
If A is less than B i.e If Condition 1 then A/B multiply by 30 else if A is greater than B i.e If Condition 2 then (A-B-B1/B2)*30+60 else if A is equals B i.e If Condition 3 then A/B multiply by 30 else if B`s value comes in negative i.e If Condition 4 then 0.
Please suggest how to write.