I am not exactly sure, where you want to have the rounding.
But you can use a combination of INT() and ROUND() with scaling factors inside and outside the functions to cut where you need it:
Hi Karimoo,
Yes, scales seems to be the “Truncating function” that I’m looking for, great jobs Thanks…
I said seems because I cant test it yet…so how do you access this “Scale” function from ?
(I cant type the word, and I dont see it in my function list. ???)
Mine only list 7 functions…
@bibipac Sorry for the confusion.
Scale is not a Adalo function is just the name of the Input field I used. Just replace it with the number you want to use for scaling:
With Rounding:
Scale = 100
Round(77.62 x 95.45 x 100)/ 100 = 7408.82
Here you basically scale up by two digits within the ROUND() function, and scale back the rounded result.
To cut it using INT() without rounding:
Scale 1 = 10000 Scale 2 = 100
INT(77.62 x 95.45 x 10000/100)/10000*100
With Scale 1 you basically decide where you want to cut using the INT() function and Scale 2 is doing the up and downscaling as in the example before.
Oh…okay, Waow…I never though that using 100 would be usefull in achieving the required 2 digit results, that’s very clever ! I must run a test now to see how this work, I got the idea but its still surpring to me ! (I m not too much of a Math person )
Anyway, Thanks you very much… indeed you seems to be the Math Guru in here…and willing to share your knowledge too…
As far as I know, Adalo currently does not support different formatting of decimals for display. A workaround would be to split the decimals in a separate string and use conditional formatting to show “00” if the decimal value is zero.
Thank you for sharing your knowledge here but I have a question for you, this scenario not working for me when I’m applying it on the rating system that means I want to show only 2 decimal places for the average rating, Here is an example -
Sum of stars = 1650
Total no. of users submitted = 450
so it should show = 3.67/5 but the result is 3.66666666667