Hari Boda is working as a SAP Lead BW-HANA consultant at TekLink Software Pvt Ltd and has worked on multiple assignments in BW-HANA analytics domain.
Brief about issue:
Amount in certain currency is multiplied by 100 in bex report in other terms the decimal places in a query is returning wrong values, sometimes the amount might be too high or too low by a factor of 100.
Explanation and solution:
This generally happens due to the decimal places maintained in table TCURX.
The Table TCURX defines how currency amounts are converted between DB storage and display on the front-end.
Not only at front end,the TCURX settings are considered also when loading data. Therefore, in order to get consistency, always there should be inverse calculation done at loading time at Application level.
By default, all amounts are stored with 2 decimal places on the database and are later converted for display based on the currency entry in the table TCURX.
If a currency is entered with e.g. value 0, then the currency is displayed with 0 decimal places in BW Queries (which means that the amount is displayed with factor 100 higher than it is stored on DB Level).
Example:
TCURX = NO ENTRY: Database entry = 123.45
The above number is displayed as 123.45
TCURX = 3: Database entry = 123.45
The above number is displayed as 12.345(3 decimal places, as 3 is maintained in the TCURX table).
TCURX = 0 Database entry = 123.45
The above number is displayed as 12345(0 decimal places and shows 12345 as no decimal places maintained in the TCURX table)
In order to correct this in BW:
we have to correct the data for the currencies having issue while loading in BW within the transformation.
- In the routine, get the data from TCURX to fetch number of decimal places for the respective currency.
- for 0 decimal currencies that are having issue’s at reporting layer, assign 100 value to a variable and store it in internal table.
- using above internal table, for the respective KPI’s and Currency Unit we need to divide by 100.
By doing this division by 100, at the reporting layer the KPI will show correctly i.e. without multiplication of 100.
Thank you for reading my blog. Comments and feedback are welcome!