Skip to Content
avatar image
Former Member

Losing values in XKOMV structure

Dear All,

Please help it's very urgent.

I have created a routine in VOFM under formulas-Condition Value. After populating value XKOMV-KBETR the value is replaced by the standard structure RETTKOMV.

Because of this my calculated value for KBETR is replacing with RETTKOMV-KBETR value.

This is happening after comming out of the routine.

Please do needful it's very urgent.

Thanks

Hreddy

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

10 Answers

  • avatar image
    Former Member
    Oct 16, 2006 at 03:09 PM

    Hi,

    Try this..This might work..

    In the condition type configuration..V/06 remove the access sequence for the condition type...Then execute your transaction..

    THanks,

    Naren

    Message was edited by: Narendran Muthukumaran

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Oct 16, 2006 at 03:11 PM

    Hi Hussain,

    Welcome to SDN.

    Is it possible to hold the value of XKOMV-KBETR temporarily in any other variable and use it later.

    Reward points if this helps.

    Manish

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Oct 16, 2006 at 03:41 PM

    Hi,

    First of all ..how do you update the structure..

    XKOMV-KBETR = '1.00'. This should be okay..

    IS the VOFM routine correctly configured to the pricing condition type..

    Thanks,

    Naren

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Naren,

      We have configured it correctly, eventhough the value is replaced by RETTKOMV-KBETR value.

      I think that value should also reflect in RETTKOMV-KBETR .

      Please suggest in this.

      Thanks

      HREDDY

  • avatar image
    Former Member
    Oct 16, 2006 at 04:19 PM

    Hi,

    How are you updating the value in XKOMV-KBETR.Are you updating the internal table XKOMV or the structure XKOMV-KBETR.

    Thanks,

    Naren

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Naren,

      In debugging mode it showing XKOMV as internal table.

      Plese suggest us how to continue.

      Thanks,

      HREDDY

  • avatar image
    Former Member
    Oct 16, 2006 at 04:37 PM

    Hi,

    Check the following..

    1. Check if the VOFM routine - Condition value formula is configured in the pricing procedure for the correct pricing condition type..

    2. Sample code..

    FORM RV64Axxx.

    • Always default the condition rate to 10.

    XKOMV-KBETR = '10.000'.

    ENDFORM.

    Hope this helps..

    Thanks,

    Naren

    Message was edited by: Narendran Muthukumaran

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi,

      if xkomv-kofrm ne 0 and wertformel eq space and komp-kposn ne 0.

      rettkomv = xkomv.

      xkwert = xkomv-kwert.

      frm_kondi_wert-nr = xkomv-kofrm.

      perform (frm_kondi_wert) in program saplv61a if found.

      xkomv = rettkomv.

      endif.

      After comming out of the routine control is on xkomv = rettkomv . statement.After this statement kbetr value is showing zero

      WE Have appllied your suggestion

      xkomv-kbetr = '10'.

      eventhough we are facing the same problem.

      Thanks,

      HREDDY

  • avatar image
    Former Member
    Oct 16, 2006 at 04:59 PM

    Hi,

    Actually it is Pricing condition type not output type..Sorry for the typo..

    Anyways..

    Goto to the transaction V/08...Then give the select the pricing procedure..And double click on "control" on the left hand side tree..

    You will see a list of condition types in the third column..For your corresponding condition type row..Check in the column "AltCty" if your VOFM routine is given or not..

    Thanks,

    Naren

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Oct 16, 2006 at 05:05 PM

    Hi,

    I think the formula is not configured in the pricing procedure..That is the reason why it is getting replaced..

    Check this code in the include LV61AA43..The flag wertformel will be set if the routine is configured..

    IF xkomv-kofrm NE 0.

    <b>wertformel = 'X'.</b>

    xkwert = xkomv-kwert.

    frm_kondi_wert-nr = xkomv-kofrm.

    PERFORM (frm_kondi_wert) IN PROGRAM saplv61a IF FOUND.

    xkomv-kwert = xkwert.

    ENDIF.

    If the flag is set the if condition that you mentioned will fail and it will not overwrite..

    if xkomv-kofrm ne 0 and <b>wertformel eq space</b> and komp-kposn ne 0.

    rettkomv = xkomv.

    xkwert = xkomv-kwert.

    frm_kondi_wert-nr = xkomv-kofrm.

    perform (frm_kondi_wert) in program saplv61a if found.

    xkomv = rettkomv.

    endif.

    Check in my previous reply for the formula in the pricing procedure..

    Thanks,

    Naren

    Message was edited by: Narendran Muthukumaran

    Add comment
    10|10000 characters needed characters exceeded

    • Exact same problem in here, with Purchase orders.

      After modifiying the XKOMV structure, it gets overwritten with the rettkomv "backup" copy, since the form is executed from here (SAPLV61A -> LV61AA55 -> form xkomv_bewerten, line 1237:

      * execute condition value formula not changing xkomv
      * will normally be processed in xkomv_kwert_ermitteln
          if xkomv-kofrm ne 0 and wertformel eq space and komp-kposn ne 0.
            rettkomv = xkomv.
            xkwert   = xkomv-kwert.
            frm_kondi_wert-nr = xkomv-kofrm.
            perform (frm_kondi_wert) in program saplv61a if found.
            xkomv    = rettkomv.
          endif.
      

      How to know which structures or tables are available for reading/modifications, for a given type of Pricing routine?

      Please help

      Many thanks

      EDIT: It appears we solved this. It was enough to define two separate routines, One for amount conditions and one for percentage ones. When the condition is a percentage condition, the form gets called from other place, without replacing XKONV, thus XKOMV-KBETR can be modified. Hope this helps.

  • avatar image
    Former Member
    Oct 16, 2006 at 05:45 PM

    Hi,

    Check if the calculation type in your condition type in V/06...If it is B (Fixed amount) or T (Multi dimensional)..Then the flag is not getting set..If it is B try to change it to A or C..

    Also check if the flag for group condition type is not set in your condition type in V/06...

    Thanks,

    Naren

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Jan 16, 2007 at 11:25 PM

    Hi Hussain,

    I am also facing the same problem stated below . If you have any solution to this issue , please let me know.

    Thanks

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Aug 13, 2007 at 06:58 PM

    I got the same problem and i resolved it by changing the value

    XKWERT

    for a condition let us think 'pjo1' if u want to change the amount field

    change the value xkwert in the subroutine.Don't change the structure xkomv.

    just change that field to some value that will reflect in the structure xkomv(may be it will reflect after save)

    FORM FRM_KONDI_WERT_601

    xkwert = '20.00'.

    END FORM.

    this will make changes in xkomv

    Add comment
    10|10000 characters needed characters exceeded