on 08-26-2013 9:20 AM
Hi all
I am trying to change the pricing date(prsdt) for sd order to be the same as req delv. date , but the change is not always being performed and wrong pricing date is occuring in some cases according to our requirement.
where does the pricing date come from and why the use exit coding is ignored in some cases ... is there any condition I should look at.
Thanks.
Hi Mehraj,
Please change the code to
IF xvbak-vdatu IS NOT INITIAL.
IF xvbak-vdatu <> xvbkd-prsdt.
xvbkd-prsdt = xvbak-vdatu.
modify xvbkd index sy-tabix.
ENDIF.
ENDIF.
and see if it works. Also please check if you already have any other custom code which is undoing your change.
Regards,
Shashi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Merhej,
Could you please let me know whether you are changing the pricing date at Header level or Item level? Ideally, If the pricing date is changed at Header level then all line items in the SO will fetch the price from the maintained condition record based on the new changed date.
Thanks & Regards,
Sharan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
First thing is how you are chjanging pricing date? in which userexit and by what logic? Could you please share the logic if possible.
Second thing is in which case it is not the same as delivery date? Check in that case what is delivery date. There can be a reason that system runs availability check and prpsoe a new delivery date but your logic is not catering this. You have to check and analyze the difference in both cases (1 where pricing date is ok 2 where pricing date and delivery dates are different).
Please check and update.
Thank$
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for the reply
I am using the exit SAVE DOCUMENT PREPARE
coding .
IF vbak-vdatu <> xvbkd-prsdt.
xvbkd-prsdt = vbak-vdatu.
modify xvbkd index sy-tabix.
ENDIF.
This works fine but it is ignored i some cases which I do not know how.
if the order has contract , then it takes the contract price , and this also works fine , the problem occurs for order without contract with pricing date not equal to delivery date.
Thanks
Hi
The logic seems ok to me. Try this in USEREXIT_MOVE_FIELD_TO_VBKD too. The best way to get the issue is to create a new order with similar values in which dates are different and debug the issue. Check in debug mode why system is not making XVBKD-PRSDT same as VBAK-VBATU. If you are ABAPER then you know very well what I mean and if you are not like me then take help of your abaper.
I think the issue will be with availability check. Check what is different points in both cases i.e correct one and with wrong date.
Thank$
Hello Merhej,
If it's specifically for those Orders that are without Contract reference then please check up with the 'Prop.f.pricing date' for your Sale Document Type in VOV8. Also, as suggested earlier to you try to check the case in Debugger Mode and see that why the values aren't being populated as they should be. Thanks.
Hello Ammarah
Thank you for your reply.
in VOV8 it is the req delivery date , and I am using several exits to tjek the pricing date , but it is still occuring , and the worst is I can not debug because I do not know when and why this occurs. it is in some cases which can occurs at any time, but for sure according to some reason
Thanks
Dear Mehrej,
For those cases specifically when this issue arises you can also check in Debugger Mode your Internal Table in which you're updating the values, check from where it's getting the pricing date in ITAB. Also check up with the loops logic as if it's okay because i'm sure that there's some issue in it. Thanks, try to give a shot and i'm sure this will gonna work out.
User | Count |
---|---|
108 | |
12 | |
11 | |
6 | |
5 | |
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.