Skip to content

Commit 64d68ef

Browse files
picandocodigomarciw
andcommitted
Updates docs/reference/esql.md
Co-authored-by: Marci W <[email protected]>
1 parent f135fe4 commit 64d68ef

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

docs/reference/esql.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ There are two ways to use ES|QL in the Ruby client:
1414
* Use the Elasticsearch [ES|QL API](https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-esql) directly: This is the most flexible approach, but it’s also the most complex because you must handle results in their raw form. You can choose the precise format of results, such as JSON, CSV, or text.
1515
* Use the Ruby ES|QL helper: The helper maps the raw response to an object that’s more readily usable by your application.
1616

17-
There is also a gem which can help you build ES|QL queries with Ruby code, [elastic-esql](#esql-ruby).
17+
You can also try the [`elastic-esql`](#esql-ruby) gem, which helps you build ES|QL queries with Ruby.
1818

1919
## ES|QL API [esql-how-to]
2020

@@ -111,9 +111,7 @@ puts response
111111

112112
## ES|QL Query Builder [esql-ruby]
113113

114-
The [elastic-esql](https://github.com/elastic/esql-ruby) gem allows you to build ES|QL queries to use with Elastic's ES|QL `query` API. The library doesn't depend on an Elasticsearch client - its sole purpose is to facilitate building ES|QL queries in Ruby. This makes it possible to use it with any Elasticsearch client.
115-
116-
It allows you to build queries in Ruby like this:
114+
The [`elastic-esql`](https://github.com/elastic/esql-ruby) gem helps you build queries for use with the [ES|QL query API](docs-content://explore-analyze/query-filter/languages/esql-rest.md). Here's an example:
117115

118116
```ruby
119117
query = Elastic::ESQL.from('sample')
@@ -130,4 +128,5 @@ query.to_s
130128
=> "FROM sample | SORT @timestamp DESC | WHERE event_duration > 5000000 | LIMIT 3"
131129
```
132130

133-
See [the README](https://github.com/elastic/esql-ruby?tab=readme-ov-file#ruby-esql-query-builder) for more information.
131+
The `elastic-esql` library works independently of the {{es}} client, so you can use it alongside any client &mdash; not just `elasticsearch-ruby`.
132+
For more information, see the gem [README](https://github.com/elastic/esql-ruby?tab=readme-ov-file#ruby-esql-query-builder).

0 commit comments

Comments
 (0)