Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Round function not rounding

I have used the round function to round to 2 decimal places, but when I export my reports, the numbers are coming out almost rounded, but not quite (for example, 27,343.0900000001). Any idea why this is happening?

  • I can't seem to reproduce the problem with hard values: 

    Table without roundingTable with rounding

    I get the same results?

     

    Kind regards

    Djerro123

    -------------------------------

    If this answered your question, please mark it as the Solution. This also helps others to find what they are looking for.

    Keep those thumbs up coming! 🙂

8 Replies

    • Anonymous's avatar
      Anonymous
      Not applicable

      Thanks, I will post there. 

       

      I do have another question, perhaps I am doing something wrong. I have a table with a field that is rounded using the round function, and then another table that is just 1/2 of the sum of that field. If I leave the second table unrounded, it = half of the sum of the first table. If I put the round function on the second table, the amount is off by a few dollars. Any ideas?

      • JarroVGIT's avatar
        JarroVGIT
        Resident Rockstar

        Are you using SUM (ROUND ([column]) )? Because that would first ROUND it and then sum the Rounded numbers. The other way arround will sum the colum and then round the result. So if I have two value, 4.02, 5.49 and go with the SUM(ROUND()), it would be 4 + 5 = 9. If I go with ROUND(SUM()) it would be ROUND(4.02+5.49) = ROUND(9.51) = 10. 

         

        Kind regards

        Djerro123

        -------------------------------

        If this answered your question, please mark it as the Solution. This also helps others to find what they are looking for.

        Keep those thumbs up coming! 🙂