2023 Mar 28 4:44 AM
Dear All,
i have a program that collect DMBTR, but after i execute it the currency between my program and from the original table is different. for example from a table the value is 192.656.000, but in my program its 1.965.250,00 where it should be the same as from the table.
can anyone help me with that ?
Regards,
Dema
2023 Mar 28 6:30 AM
Did you check about currency decimal inside and outside SAP ?
try to do a WRITE your_amount CURRENCY the_currency.
2023 Mar 28 7:29 AM
it should be like this, with IDR currency. now what should i do to make it all in IDR ?
2023 Mar 28 7:52 AM
SAP store the currency with 2 decimals whatever you have (table TCURC)
You have to make a link between the amount and the currency. When you use ALV Grid, SAP will do the job for you, when you have to create a file, you could use the WRITE ... CURRENCY ... TO
Don't try to convert the internal format
2023 Mar 28 10:30 AM
The number of currency decimals is defined in table TCURX, not TCURC.
2023 Mar 28 10:20 AM
Read first online help on currency amount field (CURR) and link to currency code field (CUKY) for a correct handling of amounts - Currency Fields and Quantity Fields > DDIC - Currency Fields
2023 Mar 28 10:35 AM
The handling of currency amounts always look strange to ABAPers. Please check how it works in the link provided by Raymond.
In the real life, IDR currency (Indonesian Rupiah) has no digits after the decimal point, but in SAP the amounts are technically defined with decimals, but these decimals are ignored when the amounts are output, i.e. in the debugger you see the technical value of dmbtr with decimals, but if you use WRITE dmbtr CURRENCY 'IDR' you will see the amount without decimals (see Frederic answer).
2023 Mar 30 3:58 AM
2023 Apr 04 8:47 AM
Pls close the thread, either by accepting the correct answer or providing the correct input from your side.