Skip to main content

GREATEST

Returns the maximum value from a set of values.

Syntax

GREATEST(<value1>, <value2> ...)

Examples

SELECT GREATEST(5, 9, 4);

┌───────────────────┐
│ greatest(5, 9, 4)
├───────────────────┤
9
└───────────────────┘
Did this page help you?
Yes
No
Explore Databend Cloud for FREE
Low-cost
Fast Analytics
Easy Data Ingestion
Elastic Scaling
Try it today