Oracle FLOOR() function
Description
The FLOOR() function returns the largest integer value not greater than a number specified as an argument.
The function takes any numeric or nonnumeric data type (can be implicitly converted to a numeric data type) as an argument.
Syntax :
FLOOR(N)
Parameters:
Name | Description |
---|---|
N | A number. |
The function returns the same data type as the numeric data type of the argument.
Pictorial Presentation of FLOOR() function
Example
The statement below returns 4 which is the largest integer value of given number (4.93) as specified in the argument.
SELECT FLOOR(4.93) FROM dual;
Here is the result.
FLOOR(4.93) ----------- 4
Example: FLOOR() with negative value
The above MySQL statement return -5 which is not the largest integer value of given number (-4.93) as specified in the argument.
SELECT FLOOR(-4.93) FROM dual;
Here is the result.
FLOOR(-4.93) ------------ -5
- New Content published on w3resource:
- HTML-CSS Practical: Exercises, Practice, Solution
- Java Regular Expression: Exercises, Practice, Solution
- Scala Programming Exercises, Practice, Solution
- Python Itertools exercises
- Python Numpy exercises
- Python GeoPy Package exercises
- Python Pandas exercises
- Python nltk exercises
- Python BeautifulSoup exercises
- Form Template
- Composer - PHP Package Manager
- PHPUnit - PHP Testing
- Laravel - PHP Framework
- Angular - JavaScript Framework
- Vue - JavaScript Framework
- Jest - JavaScript Testing Framework