Forum Discussion

shanestocks's avatar
shanestocks
Icon for Helper I rankHelper I
2 years ago
Solved

Weird Rounding Error

Hi all, wanting to perform a very, very simple comparison with the following:   In the "Overuse" column the top record is showing 716 but that's not correct. The DAX is:   = ([Usage (KG)] -...
  • HotChilli's avatar
    2 years ago

    12,544 is not the real value.  It's a rounded display value.  That's what I tried to guide you to with my previous answer.

    The real sum is 12543.50.

    Subtracting 12392 from 12543.50 equals 151.5.  This could be rounded to 151 or 152 .  Multiply those values by 4.98 and you get close to 752 and 757.  So that explains what you're seeing.  And, as before, the Overuse measure is being displayed as a whole number so it's being rounded for display purposes.

    --

    So what to do about it? First, look at the display format of each measure. Click on the measure in the data pane (on  the right) and the MeasureTools ribbon appears. Look at the Format section.  Powerbi makes assumptions here with data type (and decimal places, if applicable).  You can over-ride these choices.  Remember, this is for display.  The 'real' values are held behind the scenes. 

    In your case, the display values have been rounded for display and that's leading to confusion.