on 12-28-2015 3:27 PM
Hi,
We want a condition type which would be calculated based on previous condition value.
Example is below
S.no | From | To | C.Typ | Alt Cal type | Amount | Qty | Cond Value |
---|---|---|---|---|---|---|---|
10 | ZFNN | 1000 | 5 | 5000 | |||
20 | ZVAT | 901 | 5 | 238.10 |
ZFNN
Condition class-Surcharge/Discount
Calculation type-Quantity
ZYYY
Condition class-Surcharge/Discount
Calculation type-G(Formula)
Here for ZYNN i want to key in KBETR value 5 manually.
I wanrt the condition value of ZVAT to be =5000*5/(100+5)
The routine 901=should calculate the value like this 5000*5/(100+5),so that Condition value will become as 238.10
We have created routine for alternate calculation.
But my ZYYY value is coming as 250 but not 238.10
I am little new in using routine.
What will be the Condition class,Calcualtion type to be used for ZYYY,should i use From ,to value for this.
Kindly advise me.
My only doubt now is why the condition type ZVAT is in grey color,
We cannot edit ZVAT in Sales order.Currenlty in the line item condition tab,i add ZVAT with amount 5 and clicked enter,the value is getting updated but it is grey in color,i cannot further edit it.
I have maintained manual entry have priority.In the pricing procedure it is maintained as manual entry only,inspite of this why is it behaving like this.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Now it is working fine,there was a problem with logic,
FORM FRM_KONDI_WERT_901.
*{ INSERT IRDK900244 1
DATA: WA_XKOMV TYPE KOMV,
V_ZAMT TYPE KBETR,
V_ZAMT1 TYPE KBETR,
V_ZVAL TYPE KBETR value '100.00',
V_ZTOT TYPE KBETR.
READ TABLE XKOMV INTO WA_XKOMV WITH KEY KPOSN = XKOMV-KPOSN
KSCHL = 'ZFNN'.
IF SY-SUBRC = 0.
V_ZAMT = WA_XKOMV-KWERT.
ENDIF.
READ TABLE XKOMV INTO WA_XKOMV WITH KEY KPOSN = XKOMV-KPOSN
KSCHL = 'ZVAT'.
IF SY-SUBRC = 0.
IF V_ZAMT IS NOT INITIAL AND
WA_XKOMV-KWERT IS NOT INITIAL.
V_ZAMT1 = V_ZVAL + WA_XKOMV-KBETR.
V_ZTOT = V_ZAMT * WA_XKOMV-KBETR / V_ZAMT1.
CLEAR : XKOMV-KWERT.
wa_XKOMV-KWERT = V_ZTOT.
xkwert = wa_xkomv-kwert.
MODIFY XKOMV.
ENDIF.
ENDIF.
Now it is good.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
109 | |
15 | |
10 | |
5 | |
4 | |
3 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.