Skip to content

Commit

Permalink
integration tests order by aggregation function
Browse files Browse the repository at this point in the history
  • Loading branch information
emasab committed Sep 25, 2019
1 parent 11ac9c1 commit a305938
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions x-pack/plugin/sql/qa/src/main/resources/agg-ordering.csv-spec
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
aggSumWithColumnRepeatedWithOrderAsc
SELECT gender AS g, gender, SUM(salary) AS s3, SUM(salary), SUM(salary) AS s5 FROM test_emp GROUP BY gender ORDER BY gender;
SELECT gender AS g, gender, SUM(salary) AS s3, SUM(salary), SUM(salary) AS s5 FROM test_emp GROUP BY gender ORDER BY SUM(salary);

g:s | gender:s | s3:i | SUM(salary):i | s5:i
null |null |487605 |487605 |487605
Expand All @@ -8,7 +8,7 @@ M |M |2671054|2671054 |2671054
;

aggSumWithAliasWithColumnRepeatedWithOrderDesc
SELECT gender AS g, gender, SUM(salary) AS s3, SUM(salary), SUM(salary) AS s5 FROM test_emp GROUP BY g ORDER BY g DESC;
SELECT gender AS g, gender, SUM(salary) AS s3, SUM(salary), SUM(salary) AS s5 FROM test_emp GROUP BY g ORDER BY s5 DESC;

g:s | gender:s | s3:i | SUM(salary):i | s5:i
M |M |2671054|2671054 |2671054
Expand All @@ -17,7 +17,7 @@ null |null |487605 |487605 |487605
;

aggSumWithNumericRefWithColumnRepeatedWithOrderDesc
SELECT gender AS g, gender, SUM(salary) AS s3, SUM(salary), SUM(salary) AS s5 FROM test_emp GROUP BY 2 ORDER BY 2 DESC;
SELECT gender AS g, gender, SUM(salary) AS s3, SUM(salary), SUM(salary) AS s5 FROM test_emp GROUP BY 2 ORDER BY 3 DESC;

g:s | gender:s | s3:i | SUM(salary):i | s5:i
M |M |2671054|2671054 |2671054
Expand Down

0 comments on commit a305938

Please sign in to comment.