Skip
Arish's avatar

134. ORDER BY with Arithmetic


Sort by Calculation

sql
1SELECT name, marks, age, marks + age AS combined
2FROM students
3ORDER BY marks + age DESC;

Sort by computed value.