Skip to Content
-5

Billing Document amount in VBRP is multiplied by 10

The Billing document amount (NETWR) in VF03 is : 10.000 KW and this is the correct value, but in Table VBRP it display as: 100.000 KW and when i select from the table into a program i got the wrong value 100.

Why this is happens, and how i fix this ?

Note that this problem is not exist for example in Sales order (Value on VA03 is the same in table VBAP)

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

6 Answers

  • Mar 14 at 07:23 AM

    Perform first some search in online help (or your otriginal Abap course material) on currency amount fields and how to handle those in Abap (Look also for quantity fields)

    Add comment
    10|10000 characters needed characters exceeded

    • Look with SE11 at the definition of the table you browse with SE16 / SE16n, there is a tab with the link between currency amount field (CURR) and currency code field (CUKY) in some case the currency code field is available in the table you browse, so SAP wil display it accordingly, often it won't be available so SAP switch to default behavior (e.g. 2 decimals)

      • VBAP-NETWR -> VBAP-WAERK (Same table)
      • VBRP-NETWR -> VBRK-WAERK (In another table)
  • Mar 14 at 08:51 AM

    1 Dinar = 1000 Fils

    which means instead of the usual 2 decimals has this currency 3 decimals.

    A currency field in the table has by definition just 2 decimals and a currency with 3 decimals has to be be stored in the same fields.

    Hence it is multiplied by 10 to have just 2 decimals. And this calculation is done via a conversion exit that does it based on your currency settings. You must not take the values directly from the table without going via the conversion exit.

    Add comment
    10|10000 characters needed characters exceeded

    • documents are for end users, SE16 is a table browser for experienced developers

      SAP of course makes use of the conversion in their user interface to the end users.

      Developers usually need to see how the values are stored in the tables.

  • Mar 14 at 09:50 AM

    If any currency do not have two decimal places, then, it should be defined in TCURX table which you can do via OY04 transaction

    Add comment
    10|10000 characters needed characters exceeded

  • Mar 14 at 07:30 AM

    and the currency is? and with how much decimals it is customized?

    Add comment
    10|10000 characters needed characters exceeded

    • The Currency is KWD for Kuwait. instead of 10 it show 100 (Multiplied by 10)

      I checked now for other currencies (AED for UAE & QAR for Qatar) on the same system and it has a correct value in VBRP as in VF03.

  • Mar 14 at 08:51 AM

    10 KW : Correct value - display on VA03

    100 KW : Wrong value - display on table VBRP

    Note that this problem is not exist for example in Sales order (Value on VA03 is the same in table VBAP)

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Mar 14 at 12:37 PM

    Dear Bahaa Hodhod,

    when you select the value of NETWR from VBRP,then make sure the data element defined for storing that value is packed decimal.

    Example :

    types: begin of ts_vbrp,

    vbeln type vbrp-vbeln,

    netwr type p decimal 4,

    end of ts_vbrp.

    data : it_vbrp type table of ts_vbrp,

    wa_vbrp type ts_vbrp.

    hope this will solve your Query.

    Add comment
    10|10000 characters needed characters exceeded