-
Notifications
You must be signed in to change notification settings - Fork 25.8k
[ESQL] Makes LIMIT BY Tech Preview #145225
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
d46ee21
ee0257d
a41988c
72a711c
ee40db4
a433ae5
2c172da
9965b01
bc63ad4
e3e7711
b786e91
7d99e00
e208f54
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| area: ES|QL | ||
| issues: | ||
| - 112918 | ||
| pr: 145225 | ||
| summary: Adds LIMIT BY ESQL command in Tech Preview | ||
| type: enhancement | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| % This is generated by ESQL's CommandDocsTests. Do not edit it. See ../README.md for how to regenerate it. | ||
|
|
||
| ```esql | ||
| FROM employees | ||
| | SORT salary DESC | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Nit: all examples use a SORT, it seems? Not wrong, though.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is an interesting limitation. With LIMIT BY alone it would be difficult to stabilize the output of the csv tests and I'd have to do artificial things like including a LIMIT between the SORT and LIMIT BY:
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What we've done previously is place the tags such that the sort is not included :) a little bit fake, but should work. But it's just a nit, not a must-have! |
||
| | LIMIT 1 BY gender | ||
| | KEEP first_name, last_name, salary, gender | ||
| ``` | ||
|
|
||
| | first_name:keyword | last_name:keyword | salary:integer | gender:keyword | | ||
| | --- | --- | --- | --- | | ||
| | Otmar | Herbst | 74999 | M | | ||
| | Tzvetan | Zielinski | 74572 | F | | ||
| | Lillian | Haddadi | 73717 | null | | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,7 @@ | ||
| % This is generated by ESQL's CommandDocsTests. Do not edit it. See ../README.md for how to regenerate it. | ||
|
|
||
| ```esql | ||
| FROM employees | ||
| | SORT salary DESC | ||
| | LIMIT 1 BY languages, gender | ||
| ``` |
Large diffs are not rendered by default.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure whether I need
featurehere or whether I need a changelog at allUh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think it matters as features and enhancements get mushed together anyways 😄
https://www.elastic.co/docs/release-notes/elasticsearch#elasticsearch-9.3.2-features-enhancements