-
Notifications
You must be signed in to change notification settings - Fork 190
[BUG] Opensearch returns null for all columns not listed in GROUP BY statement #258
Copy link
Copy link
Open
Labels
tdvtTableau test frameworkTableau test framework
Description
Describe the bug
Opensearch returns null for all columns not listed in GROUP BY statement
To Reproduce
Steps to reproduce the behavior:
- Upload the test data using attached files or generate on your own
curl -s -H 'Content-Type: application/x-ndjson' -XPUT 'https://localhost:9200/calcs?pretty' -u admin:admin --insecure --data-binary @calcs_mappings.json
curl -s -H 'Content-Type: application/x-ndjson' -XPOST 'https://localhost:9200/calcs/_bulk?pretty' -u admin:admin --insecure --data-binary @calcs.json | grep -i error
See below for data sample:
opensearchsql> select `key` as KK, int1, bool0 from calcs;
fetched rows / total rows = 17/17
+-------+--------+---------+
| KK | int1 | bool0 |
|-------+--------+---------|
| key00 | -3 | True |
| key01 | -6 | False |
| key02 | null | null |
| key04 | null | False |
| key05 | null | null |
| key06 | null | True |
| key08 | 3 | null |
| key09 | 3 | null |
| key10 | null | True |
| key15 | null | False |
| key03 | -4 | True |
| key07 | 2 | False |
| key11 | -8 | False |
| key12 | null | null |
| key13 | null | null |
| key14 | null | True |
| key16 | -9 | null |
+-------+--------+---------+
- Execute a query with
GROUP BYstatement
opensearchsql> select `key` as KK, int1 from calcs GROUP BY bool0;
fetched rows / total rows = 3/3
+------+--------+
| KK | int1 |
|------+--------|
| null | null |
| null | null |
| null | null |
+------+--------+
Expected behavior
In this very specific query at least key column shouldn't be empty (filled by nulls)
Plugins
The default set:
curl "localhost:9200/_cat/plugins?h=component&pretty=true"
mapper-murmur3
opensearch-alerting
opensearch-anomaly-detection
opensearch-asynchronous-search
opensearch-index-management
opensearch-job-scheduler
opensearch-knn
opensearch-notebooks
opensearch-performance-analyzer
opensearch-reports-scheduler
opensearch-security
opensearch-sql
Host/Environment (please complete the following information):
Docker container v.1.0.0
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
tdvtTableau test frameworkTableau test framework