The greater than operator (>) compares two values and returns TRUE when the value on the left is greater than the value on the right. It is commonly used for numeric comparisons, dates, and other comparable values.
Analysts frequently need to identify records above a particular threshold, such as employees earning more than a certain salary or transactions exceeding a specified amount.
A manager wants to identify employees earning more than ₹75,000. The greater than operator can be used to filter those employees.
SELECT
EmployeeName,
Salary
FROM Employees
WHERE Salary > 75000;
The operator is useful for salary analysis, sales analysis, transaction monitoring, financial reporting, inventory analysis, and threshold-based business rules.
- > means greater than.
- It compares two values.
- It is commonly used with numeric values.
- It can also be used with dates.
- It is useful for threshold-based filtering.
What does > mean in SQL?
The > operator returns records where the value on the left is greater than the value on the right.
Can > be used with dates?
Yes. Greater than can be used to compare date values when supported by the database data type.