On this page

    Categories: Math

    CEILING

    Returns the nearest equal or larger value of the input expression. Can also be called using CEIL().

    Syntax

    CEILING(numeric_expression NUMERIC) → INTEGER

    • numeric_expression: The number (DOUBLE, FLOAT, INTEGER) for which you want to compute the ceiling.

    Examples

    CEILING example
    SELECT CEILING(3.1459)
    -- 4
    
    CEILING example
    SELECT CEIL(37.775420706711)
    -- 38
    
    CEILING example
    SELECT CEIL(-37.775420706711)
    -- -37
    
    CEILING example
    SELECT CEIL(0)
    -- 0