on 10-16-2008 4:46 PM
Hi,
We've created two condition value formulas (RV64A910 and RV64A920) to calculate discounts in the invoice, according to some criteria.
When we execute simulation on transaction VF04, the values are correctly calculated. For example:
CnTy Amount Crcy per UoM C Value
ZRCO 2.160- COP 64 017 138.240-
With an amount of -2160 multiplied by 64 equals -138,240.
Then, when the invoice is created (using the same transaction VF04), if we check the invoice created the values are wrong:
CnTy Amount Crcy per UoM C Value
ZRCO 2.160- COP 64 017 2.329-
Can anyone please tell me why could this be happening, and how can I fix it?
Thank you in advance.
Daniel Reyes
SAP executes the routine, and the routine calculates the value correctly.
For some unknown reason, when the routine ends and SAP standard takes control, SAP recalculates this price condition, and then the value is wrong.
We also found that SAP calls the routine several times for each position in the billing document. So we modify the routine to recalculate the value each time SAP calls this routine, taking into account the business logic.
Daniel Reyes
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
HI,
I am not sure this may be the case but check, if in the routines which have been written you may added the T.code when this has to be executed like Vf01, or VF02 if this is the case then add VF04 t.code also in the routines and check.
check this may help
regards
sudhakar
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sudhakar,
First of all, thank you for your reply.
The only check that routine RV64A910 has is to avoid execution when the invoice is being checked on transaction VF02, so it doesn't calculate again the value.
In the code the value is calculated like this:
xkomv-kbetr = ti_xkomv-kwert / lv_quantity.
xkomv-kpein = lv_quantity_ex.
xkwert = xkomv-kbetr * lv_quantity_ex.
I'm thinking that maybe when the routine has ended, when SAP standard takes control again somehow it recalculates this condition and then it is wrong. Can anyone please tell me if this may be happening and how to correct it?
Thanks in advance.
Kind regards,
Daniel Reyes
Hi all,
Checking the price condition in the invoice, i see these values:
Amount 2.160- COP / 33 UND
Cond.base value 71,000 UND
Condition value 4.647- COP
The result we need is Condition Value = -2.160 * 33, but, because this formula is calculated in a position of the invoice, this position has its own quantity that differs from the quantity calculated by the formula.
In simulation, SAP takes the result as we need, that is Condition Value = -2.160 * 33. But when the billing document is created, the value is calculated like this:
Condition value = (-2.160 / 33) * 71
Condition value = (KOMV-KBETR / KOMV-KPEIN) * KOMV-KAWRT
Maybe there is something that is missing in our condition value formula.
Can anyone please tell me where can I find a document that explain some details to have into account when we develop a condition value formula using transaction code VOFM?
I kindly ask you to give me any clue.
Thanks in advance.
Kind regards,
Daniel Reyes
User | Count |
---|---|
99 | |
11 | |
11 | |
6 | |
6 | |
4 | |
4 | |
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.