Skip to main content

Rounding Functions

Ceiling

Substrait definition

Rounds a number up to its closest integer.

Its output type will always be an integer, if a non numeric type is passed in, the function will return null.

SQL Usage

SELECT ceiling(column1) FROM ...

or

SELECT ceil(column1) FROM ...

Floor

Substrait definition

Rounds a number down to its closest integer.

Its output type will always be an integer, if a non numeric type is passed in, the function will return null.

SQL Usage

SELECT floor(column1) FROM ...

Round

Substrait definition

Rounds a number to its closest integer.

Its output type will always be an integer, if a non numeric type is passed in, the function will return null.

SQL Usage

SELECT round(column1) FROM ...