[BUG] Incorrect values of quotted nested fields aggregation when fetch_size
is set
#2530
Labels
bug
Something isn't working
fetch_size
is set
#2530
What is the bug?
Using the SQL API (with the default format
jdbc
), combining quoted nested fields and thefetch_size
attribute cause unexpected failures (on https://playground.opensearch.org) or incorrect value (on my work instance, opensearch 2.12.0).How can one reproduce the bug?
On https://playground.opensearch.org
We can use the
opensearch_dashboards_sample_data_ecommerce
index to show the issue. Run the following 4 commands in the "Dev Tools" console:The command are basically identical and expected to return the same content: command 1 & 2 quote
products.quantity
between backticks, and command 2 & 4 explicitly setfetch_size
to 1000 (the default value).However, while command 1, 3 and 4 produce the same and expected result (only
schema.0.name
change as expected):command 2 fail unexpectedly:
On my work system
The above was obtained when trying to reproduce the issue I see on my workstation. There I have an index
data1
with a nested field and a few documents:queries 1, 3 and 4 produce the expected result:
but the 2nd query produce an incorrect result:
The query return 0 instead of the expected 6.
What is the expected behavior?
All these queries are supposed to be equivalent, so they should return the same value.
What is your host/environment?
Do you have any additional context?
I am not sure if the different behavior is due to the dataset or if this should be 2 distinct bugs.
The text was updated successfully, but these errors were encountered: