bugl
bugl
HomeLearnPatternsSearch
HomeLearnPatternsSearch

Loading lesson path

Learn/SQL/SQL References
SQL•SQL References

MySQL CEILING() Function

Concept visual

MySQL CEILING() Function

Pointer walk
two pointers
leftright102132436485116
left=0
right=6
1
3

Start at both ends

Example

Return the smallest integer value that is greater than or equal to 25.75:

SELECT CEILING(25.75);

Definition and Usage

The CEILING() function returns the smallest integer value that is bigger than or equal to a number.

Note:

This function is equal to the CEIL() function.

Syntax

Ceiling(

number )

Parameter Values

Parameter

Description number

Required. A numeric value

Technical Details

Works in:

From MySQL 4.0

More Examples

Example

Return the smallest integer value that is greater than or equal to 25:

SELECT CEILING(25);

Previous

❮ MySQL Functions

Next

Previous

MySQL CEIL() Function

Next

MySQL COS() Function