Sobes.tech
Middle

SELECT name, age FROM users WHERE age > 18 ORDER BY age DESC;

sobes.tech AI

Answer from AI

This SQL query selects the name and age columns from the users table for all users over 18 years old. The result is sorted by age in descending order (from oldest to youngest).

Example result:

name age
Ivan 45
Maria 30
Alexey 25

This query is useful when you need to get a list of adult users starting from the oldest.