Mohd Izzar
Posts: 0
Joined: Fri Feb 22, 2019 9:28 am

mySQL two decimal point

Hi, I have counter some issue. In mysql, the data show two decimal point eg: 30.08. But, when call the database to apperry io, my data become like this, 30.079999923706055. Is there any solution so that I can get only to two decimal point.

Thanks

Serhii Kulibaba
Posts: 150
Joined: Tue Aug 27, 2013 1:47 pm

mySQL two decimal point

You can change the format on the server side (if you use API Express Visual Builder) on the client side with a code:preMath.round(30.079999923706055 * 100)/100/pre
Just replace that static value with your variable.

It is related to a data format you use there. It has to be a string, not a number

Mohd Izzar
Posts: 0
Joined: Fri Feb 22, 2019 9:28 am

mySQL two decimal point

Thanks Serhii

Return to “Issues”