-
Notifications
You must be signed in to change notification settings - Fork 24.6k
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
SQL: ORDER BY COUNT(*) should display an error message #34590
Labels
Comments
Pinging @elastic/es-search-aggs |
matriv
added a commit
to matriv/elasticsearch
that referenced
this issue
Oct 25, 2018
Previously, for some queries the validation for ORDER BY fields didn't kick in since a HAVING close or an ORDER BY with scalar function would add `Filter` and `Project` plans between the `OrderBy` and the `Aggregate`. Now the LogicalPlan tree beneath `OrderBy` is traversed and the ORDER BY fields are properly verified. Fixes: elastic#34590
matriv
pushed a commit
that referenced
this issue
Oct 25, 2018
Previously, for some queries the validation for ORDER BY fields didn't kick in since a HAVING close or an ORDER BY with scalar function would add `Filter` and `Project` plans between the `OrderBy` and the `Aggregate`. Now the LogicalPlan tree beneath `OrderBy` is traversed and the ORDER BY fields are properly verified. Fixes: #34590
matriv
pushed a commit
that referenced
this issue
Oct 25, 2018
Previously, for some queries the validation for ORDER BY fields didn't kick in since a HAVING close or an ORDER BY with scalar function would add `Filter` and `Project` plans between the `OrderBy` and the `Aggregate`. Now the LogicalPlan tree beneath `OrderBy` is traversed and the ORDER BY fields are properly verified. Fixes: #34590
matriv
pushed a commit
that referenced
this issue
Oct 25, 2018
Previously, for some queries the validation for ORDER BY fields didn't kick in since a HAVING close or an ORDER BY with scalar function would add `Filter` and `Project` plans between the `OrderBy` and the `Aggregate`. Now the LogicalPlan tree beneath `OrderBy` is traversed and the ORDER BY fields are properly verified. Fixes: #34590
kcm
pushed a commit
that referenced
this issue
Oct 30, 2018
Previously, for some queries the validation for ORDER BY fields didn't kick in since a HAVING close or an ORDER BY with scalar function would add `Filter` and `Project` plans between the `OrderBy` and the `Aggregate`. Now the LogicalPlan tree beneath `OrderBy` is traversed and the ORDER BY fields are properly verified. Fixes: #34590
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The following behavior should return an error message about the limitations of
ORDER BY
, but instead is returning some seemingly incorrect results:composite
aggregation (what is used in anygroup by
sql statements) cannot order on something else other than the key itself (in this case -languages
). But, instead of returning an error message, it gives the false impression that the results are incorrect.Related to #31860.
The text was updated successfully, but these errors were encountered: