Export (0) Print
Expand All
Expand Minimize

FLOOR (SQL Server Compact)

Returns the largest integer less than or equal to the given numeric expression.


FLOOR (numeric_expression)

numeric_expression

An expression of the exact numeric or approximate numeric data type categories, or of data types that are implicitly convertible to float.

Returns the same type as numeric_expression except for the following expressions.

Specified expression Return type

tinyint, smallint

int

real/float

float

Nonnumeric types that can be implicitly converted to float

float

The following example applies the FLOOR function to the UnitPrice column of the Order Details table.

SELECT [Order ID], [Unit Price], FLOOR([Unit Price]) AS [Floor Value]
FROM [Order Details]
WHERE ([Unit Price] > 100)
ORDER BY [Unit Price]
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft