Skip to content

Commit ce6fd7b

Browse files
committed
Fix bwc
1 parent 7bbad91 commit ce6fd7b

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

x-pack/plugin/esql/qa/testFixtures/src/main/resources/eval.csv-spec

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -638,6 +638,7 @@ foo:keyword
638638

639639

640640
evalAfterAvgUsingSameName
641+
required_capability: remove_empty_attribute_in_merging_output
641642
from employees
642643
| stats avg = avg(salary)
643644
| eval avg = 12
@@ -648,6 +649,7 @@ avg:integer
648649
;
649650

650651
evalAfterStatsUsingSameName
652+
required_capability: remove_empty_attribute_in_merging_output
651653
from employees
652654
| stats count = count(emp_no), median = median(salary), top_salaries = TOP(salary, 3, "desc")
653655
| keep median, top_salaries
@@ -660,6 +662,7 @@ median:integer
660662
;
661663

662664
evalAfterStatsUsingSameName2
665+
required_capability: remove_empty_attribute_in_merging_output
663666
ROW foo = [10, 11, 12]
664667
| mv_expand foo
665668
| stats sum = sum(foo), max = max(foo)

x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/action/EsqlCapabilities.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -413,6 +413,12 @@ public enum Cap {
413413
*/
414414
RENAME_SEQUENTIAL_PROCESSING,
415415

416+
/**
417+
* Support for removing empty attribute in merging output.
418+
* See <a href="https://github.com/elastic/elasticsearch/issues/126392"> ESQL: EVAL after STATS produces an empty column #126392 </a>
419+
*/
420+
REMOVE_EMPTY_ATTRIBUTE_IN_MERGING_OUTPUT,
421+
416422
/**
417423
* Fix for union-types when some indexes are missing the required field. Done in #111932.
418424
*/

0 commit comments

Comments
 (0)