Curriculum
Course: SQL
Login

Curriculum

SQL

SQL References

0/80

MySQL Functions

0/139

SQL Server Functions

0/84

SQL Quick Ref

0/1
Text lesson

FLOOR

Example

Provide the maximum integer value that is equal to or less than 25.75.

SELECT FLOOR(25.75);

Definition and Usage

The FLOOR() function yields the greatest integer value that is less than or equal to a given number.

Note: Also consider the ROUND(), CEIL(), CEILING(), TRUNCATE(), and DIV functions.

Syntax

FLOOR(number)

Parameter Values

Parameter

Description

number

Essential: A numerical value is necessary.

Technical Details

Works in: From MySQL 4.0

More Examples

Example

Provide the greatest integer value that is equal to or less than 25.

SELECT FLOOR(25);