Skip
Arish's avatar

76. MAX Function


MAX Function

MAX returns the highest value.

Syntax

sql
1SELECT MAX(column) FROM table;

Example: Highest Age

sql
1SELECT MAX(age) AS oldest FROM students;

With WHERE

sql
1SELECT MAX(marks) FROM students
2WHERE course = 'Python';