mirror of
https://github.com/elastic/elasticsearch.git
synced 2025-04-25 23:57:20 -04:00
* Source commands * Missing word * Processing commands * Apply suggestions from code review Co-authored-by: Alexander Spies <alexander.spies@elastic.co> * Review feedback * Add sort detail for mv * More review feedback --------- Co-authored-by: Alexander Spies <alexander.spies@elastic.co>
49 lines
882 B
Text
49 lines
882 B
Text
[discrete]
|
|
[[esql-row]]
|
|
=== `ROW`
|
|
|
|
**Syntax**
|
|
|
|
[source,esql]
|
|
----
|
|
ROW column1 = value1[, ..., columnN = valueN]
|
|
----
|
|
|
|
*Parameters*
|
|
|
|
`columnX`::
|
|
The column name.
|
|
|
|
`valueX`::
|
|
The value for the column. Can be a literal, an expression, or a
|
|
<<esql-functions,function>>.
|
|
|
|
*Description*
|
|
|
|
The `ROW` source command produces a row with one or more columns with values
|
|
that you specify. This can be useful for testing.
|
|
|
|
*Examples*
|
|
|
|
[source.merge.styled,esql]
|
|
----
|
|
include::{esql-specs}/row.csv-spec[tag=example]
|
|
----
|
|
[%header.monospaced.styled,format=dsv,separator=|]
|
|
|===
|
|
include::{esql-specs}/row.csv-spec[tag=example-result]
|
|
|===
|
|
|
|
Use square brackets to create multi-value columns:
|
|
|
|
[source,esql]
|
|
----
|
|
include::{esql-specs}/row.csv-spec[tag=multivalue]
|
|
----
|
|
|
|
`ROW` supports the use of <<esql-functions,functions>>:
|
|
|
|
[source,esql]
|
|
----
|
|
include::{esql-specs}/row.csv-spec[tag=function]
|
|
----
|