• Resolved A2A Dijital

    (@a2adijital)


    Hello,

    I want to round up the values I have calculated on my site.

    For example: I want to show the resulting value of 23.01 as 24.

    When I try the ROUND function, I get 23 for 23.01 and 24 for 23.51. How can I round the upper number in any case?

    Thank you.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author codepeople

    (@codepeople)

    Hello @a2adijital

    Use the CEIL operation instead the ROUND one. CEIL(X) returns the integer number, equal or greater than X

    Best regards.

    Thread Starter A2A Dijital

    (@a2adijital)

    Hello,
    It definitely worked.
    Thank you very much for your support.

    Hi,
    round works but not with second parameters ( number of decimals )
    ex : round( (parameter1*parameter2), 2 )

    Plugin Author codepeople

    (@codepeople)

    Hello @cordonnierc

    The operation to use in this case would be PREC

    PREC(X,Y) rounds the number X with Y decimals.
    ROUND(X,Y) rounds the number X to the nearest multiple of Y.

    So, the equation would be:

    
    PREC(parameter1*parameter2, 2)
    

    Best regards.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Round Up’ is closed to new replies.