elasticsearch/docs/reference/esql/functions/left.asciidoc

37 lines
607 B
Plaintext

[discrete]
[[esql-left]]
=== `LEFT`
*Syntax*
[.text-center]
image::esql/functions/signature/left.svg[Embedded,opts=inline]
*Parameters*
`str`::
The string from which to return a substring.
`length`::
The number of characters to return.
*Description*
Returns the substring that extracts 'length' chars from 'str' starting
from the left.
*Supported types*
include::types/left.asciidoc[]
*Example*
[source.merge.styled,esql]
----
include::{esql-specs}/string.csv-spec[tag=left]
----
[%header.monospaced.styled,format=dsv,separator=|]
|===
include::{esql-specs}/string.csv-spec[tag=left-result]
|===