Uploaded image for project: 'Kylin'
  1. Kylin
  2. KYLIN-4629

"sum case when" not support in kylin 3.1.0 not yet ?

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Information Provided
    • v3.1.0
    • v3.1.0
    • Query Engine
    • CDH 6.2.1

    Description

      Using the latest version of 3.1.0, the following is still not supported. Why?

      使用了3.1.0的最新版,依然不支持以下写法,为何?

      select sum(case ACCOUNT_COUNTRY when 'CN' THEN 1 else 0 end) from kylin_account
      

       

      error info:

      No realization found for OLAPContext, CUBE_UNMATCHED_AGGREGATION[FunctionDesc [expression=SUM, parameter=CASE(=($3, 'CN'), 1, 0), returnType=null]], rel#2071:OLAPTableScan.OLAP.[](table=[DEFAULT, KYLIN_ACCOUNT],ctx=,fields=[0, 1, 2, 3, 4, 5]) while executing SQL: "select * from (select sum((case ACCOUNT_COUNTRY when 'CN' THEN 1 else 0 end)) from kylin_account) limit 50000"

      Attachments

        Activity

          People

            xiaoge chuxiao
            shaiyachen tylor
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: