-
Notifications
You must be signed in to change notification settings - Fork 25.1k
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
ESQL: grouping by just a keyword ignores null values #100109
Labels
:Analytics/ES|QL
AKA ESQL
>enhancement
>non-issue
Team:QL (Deprecated)
Meta label for query languages team
Comments
Pinging @elastic/es-ql (Team:QL) |
Pinging @elastic/elasticsearch-esql (:Query Languages/ES|QL) |
Thanks Costin. I can reproduce the issue, and I think OrdinalsGroupingOperator doesn't handle nulls properly. |
This was referenced Sep 30, 2023
I've opened #100117. |
dnhatn
added a commit
that referenced
this issue
Oct 1, 2023
This change introduces null handling in the OrdinalsGroupingOperator, replacing the current behavior which skips null keys. Ordinals are now incremented by 1, with 0 being used to represent null ordinals. Closes #100109
piergm
pushed a commit
to piergm/elasticsearch
that referenced
this issue
Oct 2, 2023
This change introduces null handling in the OrdinalsGroupingOperator, replacing the current behavior which skips null keys. Ordinals are now incremented by 1, with 0 being used to represent null ordinals. Closes elastic#100109
jakelandis
pushed a commit
to jakelandis/elasticsearch
that referenced
this issue
Oct 2, 2023
This change introduces null handling in the OrdinalsGroupingOperator, replacing the current behavior which skips null keys. Ordinals are now incremented by 1, with 0 being used to represent null ordinals. Closes elastic#100109
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
:Analytics/ES|QL
AKA ESQL
>enhancement
>non-issue
Team:QL (Deprecated)
Meta label for query languages team
Description
Not sure if it's a regression or not but when grouping by just one keyword field, the null group is not returned:
should return [F, M, null] yet only [F, M] are.
It looks like the hashing function (whether ordinal or not) ends up dropping null along the way.
This doesn't happen with multiple keys as long as the keyword is not the first key:
The text was updated successfully, but these errors were encountered: