ORDER BY DESC sorts query results from higher to lower values for numeric data and from later to earlier values for dates.
Descending sorting is essential when identifying top performers, highest sales, largest transactions, or most recent records.
Find employees with the highest salaries first.
SELECT
EmployeeName,
Salary
FROM Employees
ORDER BY Salary DESC;
DESC is widely used in ranking reports, top-N analysis, sales reporting, financial analysis, and recent-activity reports.
- DESC means descending order.
- Higher numeric values appear first.
- Later dates generally appear first.
- It is commonly used for rankings.
- DESC can be combined with multiple sort columns.
What does DESC mean?
DESC means descending order.
How do you find the highest salary first?
Use ORDER BY Salary DESC.