on 07-15-2008 4:15 PM
Hi,
I have to implement below simple business logic at Querry level
Var Plan/Actual Cost Percent % =
If Plan Cost NE 0:
% = (Actual Cost - Plan Cost ) * 100 / Plan Cost
Else
Actual Cost = 0.
% = 0
Else
% = 100
endif.
and I have created calculated keyfigure as below
( 'Planned costs' NE 0 ) * 'Actual costs' % 'Planned costs' + ( ( 'Actual costs' == 0 ) AND ( 'Planned costs' == 0 ) ) * 0 + ( ( 'Actual costs' NE 0 ) AND ( 'Planned costs' == 0 ) ) * 100
I know that we need not validate again planned costs in else part but still as it was not working correctly just modified after refering sap help but still it is not giving expected result so can you please have a look at it and let me know what i am missing here??
Thanks for your valuable time..
BRK
Edited by: BRK on Jul 15, 2008 5:19 PM
Edited by: BRK on Jul 15, 2008 5:20 PM
Hi,
Try the following formula. it should work for ya.
(( 'Planned costs' NE 0 ) * ('Actual costs' % 'Planned costs' ))+ (( ( 'Actual costs' NE 0 ) AND ( 'Planned costs' == 0 ) ) * 100)
Regds,
Shashank
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Shashank,
Just now I am looking at your reply infact just yesterday implemented the formula like you said and it worked ..
However i say fully thanks and award points as it is matching my requirement..
but i could not understand what was the wrong in my initial formula ..will see when have time again..
Thanks & Regards,
BRK
Hi,
Check the usage of conditional calculations.
http://help.sap.com/saphelp_nw04/helpdata/en/23/17f13a2f160f28e10000000a114084/content.htm
Regards.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Walt,
I think there is some problem in displaying NE in symbols as angle brackets because if we type angle brackets after saving those are getting disappeared (I mean in SDN)
anyway however i have seen your message you had mentioned * (star) between Plan Cost NE 0 and Actual Cost NE 0 ..
is it really star or Logical AND ..
(PLANCOST0)*(ACTUALCOST0)..
Inshort still it didnt solve my problem .. so can you please explain me in more detail..
Thanks & regards,
BRK
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
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.