[discrete]
[[esql-right]]
=== `RIGHT`

*Syntax*

[.text-center]
image::esql/functions/signature/right.svg[Embedded,opts=inline]

*Parameters*

`str`::
The string from which to returns a substring.

`length`::
The number of characters to return.

*Description*

Return the substring that extracts 'length' chars from 'str' starting
from the right.

include::types/right.asciidoc[]

*Example*

[source.merge.styled,esql]
----
include::{esql-specs}/string.csv-spec[tag=right]
----
[%header.monospaced.styled,format=dsv,separator=|]
|===
include::{esql-specs}/string.csv-spec[tag=right-result]
|===
