Sorting results

You can order the result based on the column or aliased column. You can be specify DESC for descending order or ASC for ascending. By default, ordering will be ascending. You can combine the  LIMIT clause with ORDER BY to limit the results.

Get MySQL 8 Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.