Skip to Content
author's profile photo Former Member
Former Member

Changing pricing routine - RV61A901

Hi Gurus,

I am changing the pricing routine (RV61A901) via VOFM for the following requirement:

There's a condition ZAGV for one item, and it should be automatically added for item category ZVAT.

Could you please tell me how can I do that?

Kind of an urgent request.

Please help.

Thanks in Advance!

Regards,

Ashutosh.

Add a comment
10|10000 characters needed characters exceeded

Related questions

3 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Dec 09, 2014 at 08:06 AM

    Hi Archana,

    Thanks a lot for helping me out. 😊

    I've finally solved the issue with following code:

    IF W_VBAP-PSTYV = 'ZVAT'.

    READ TABLE W_KOMV INTO WA_KOMV WITH KEY KSCHL = 'ZAGV' KPOSN = '000001'.

    WA_KOMV-KPOSN = '000002'.

    APPEND WA_KOMV TO W_KOMV.

    CLEAR: WA_KOMV.

    ENDIF.


    Closing this thread.


    Best Regards,

    Ashutosh.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 04, 2014 at 05:15 AM

    Hi Ashutosh,

    You put a breakpoint in the Include RV61A901 and sit with your functional to check what values are available in that include. Accordingly, you can code in the routine. Your functional contact can give you formula to achieve the desired functionality. You need to check KOMV-KSCHL for condition type and KWERT is the value field.

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hi Ashutosh,

      You need to loop at komv table (either in field symbol or in work area). In the loop you can check value of KSCHL for each entry. When it is 'ZAGV' copy KWERT vaklue into local variable. After that you need to check when KSCHL is 'ZVAT', put variable value into KWERT for this condition type.

  • author's profile photo Former Member
    Former Member
    Posted on Dec 04, 2014 at 10:13 AM

    It is not Recommended to add a line item or line programmatically ,

    https://service.sap.com/sap/support/notes/178328

    I would recommend to code a check for Item Catergory 'ZVAT' and ZAGV Condition Type , in Sale Order User Exit.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.