elasticsearch/docs/reference/esql/functions/examples/mv_max.asciidoc

23 lines
689 B
Plaintext

// This is generated by ESQL's AbstractFunctionTestCase. Do no edit it. See ../README.md for how to regenerate it.
*Examples*
[source.merge.styled,esql]
----
include::{esql-specs}/math.csv-spec[tag=mv_max]
----
[%header.monospaced.styled,format=dsv,separator=|]
|===
include::{esql-specs}/math.csv-spec[tag=mv_max-result]
|===
It can be used by any column type, including `keyword` columns. In that case it picks the last string, comparing their utf-8 representation byte by byte:
[source.merge.styled,esql]
----
include::{esql-specs}/string.csv-spec[tag=mv_max]
----
[%header.monospaced.styled,format=dsv,separator=|]
|===
include::{esql-specs}/string.csv-spec[tag=mv_max-result]
|===