andygrove commented on code in PR #22474: URL: https://github.com/apache/datafusion/pull/22474#discussion_r3318739344
########## datafusion/core/tests/tpc-ds/9.sql: ########## @@ -1,52 +1,76 @@ --- Copyright 2015 Transaction Processing Performance Council - -select case when (select count(*) - from store_sales - where ss_quantity between 1 and 20) > 409437 - then (select avg(ss_ext_tax) - from store_sales - where ss_quantity between 1 and 20) - else (select avg(ss_net_paid) - from store_sales - where ss_quantity between 1 and 20) end bucket1 , - case when (select count(*) - from store_sales - where ss_quantity between 21 and 40) > 4595804 - then (select avg(ss_ext_tax) - from store_sales - where ss_quantity between 21 and 40) - else (select avg(ss_net_paid) - from store_sales - where ss_quantity between 21 and 40) end bucket2, - case when (select count(*) - from store_sales - where ss_quantity between 41 and 60) > 1333710 - then (select avg(ss_ext_tax) - from store_sales - where ss_quantity between 41 and 60) - else (select avg(ss_net_paid) - from store_sales - where ss_quantity between 41 and 60) end bucket3, - case when (select count(*) - from store_sales - where ss_quantity between 61 and 80) > 2361102 - then (select avg(ss_ext_tax) - from store_sales - where ss_quantity between 61 and 80) - else (select avg(ss_net_paid) - from store_sales - where ss_quantity between 61 and 80) end bucket4, - case when (select count(*) - from store_sales - where ss_quantity between 81 and 100) > 1517817 - then (select avg(ss_ext_tax) - from store_sales - where ss_quantity between 81 and 100) - else (select avg(ss_net_paid) - from store_sales - where ss_quantity between 81 and 100) end bucket5 -from reason -where r_reason_sk = 1 +SELECT CASE + WHEN + (SELECT count(*) + FROM store_sales + WHERE ss_quantity BETWEEN 1 + AND 20) + > 74129 + THEN + (SELECT avg(ss_ext_discount_amt) Review Comment: Is it intentional that this changed from `ss_ext_tax` to `ss_ext_discount_amt`? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
