Returns the smallest whole number that is greater than or equal to the parameter.

Syntax

CEIL ( expression )

Arguments

expression: A DOUBLE number.

Returns

Returns a DOUBLE value. Returns zero when expression is between 0 and -1.0. Returns expression when expression is a whole number. Returns zero when expression is zero. Returns NULL when expression is NULL.

Examples

SELECT orderAmt, CEIL(orderAmt) AS orderAmtCeil FROM MYSQL.inventory.cust;

-- CEIL(100.07)
-- Returns 101

-- CEIL(-100.07)
-- Returns -100