ORDER BY - Sorting Results1 / 10
Use ORDER BY to sort records by crop production amount from lowest to highest. Try:
SELECT * FROM crops ORDER BY production_tons;| id | country_name | crop | production_tons | continent |
|---|---|---|---|---|
| 1 | Brazil | Soybeans | 130 | South America |
| 2 | United States | Corn | 360 | North America |
| 3 | India | Rice | 120 | Asia |
| 4 | China | Wheat | 135 | Asia |
| 5 | France | Wheat | 40 | Europe |
Ctrl+Enter to submit
ORDER BY - Sorting Results - Free SQL Practice Online
Practise ORDER BY - Sorting Results with 10 free, interactive SQL exercises. You type real queries into your browser and get instant feedback on every answer - no database setup, no install, and no signup. It is a fast, hands-on way to learn SQL online and build query skills you can use at work.