0 Replies Latest reply on Jan 3, 2008 8:52 PM by CF_crazee

    serializeJSON funkiness

    CF_crazee
      I have been beating my head over this for a long time now. I am using a cfgrid and using a custom CFC to return a JSON variable for my grid

      heres the problem , I use ROUND() in my sql query itself to return numbers rounded to 3 decimal places , but some numbers like 12.819 keeps getting converted to 12.81899999999999 when the query is converted to a JSON string using the serializeJSON function, which is not even the original value in the database table the original value in the db table is like 12. 818653.

      What is going on here and since cfgridcolumn in html format cfgrid does not support a number format I dont even have a work around, random numbers in my grid keep having numerous decimal places please help

      Thanks in advance
      Prem