[[eql-function-ref]]
== EQL function reference
++++
Function reference
++++
experimental::[]
{es} supports the following EQL functions:
* <>
[discrete]
[[eql-fn-substring]]
=== `substring`
Extracts a substring from a source string at provided start and end positions.
If no end position is provided, the function extracts the remaining string.
[%collapsible]
====
*Example*
[source,eql]
----
substring("start regsvr32.exe", 6) // returns "regsvr32.exe"
substring("start regsvr32.exe", 0, 5) // returns "start"
substring("start regsvr32.exe", 6, 14) // returns "regsvr32"
substring("start regsvr32.exe", -4) // returns ".exe"
substring("start regsvr32.exe", -4, -1) // returns ".ex"
----
*Syntax*
[source,txt]
----
substring(