Uploaded image for project: 'Apache AsterixDB'
  1. Apache AsterixDB
  2. ASTERIXDB-2468

Projection pushdown is not performed correctly for COUNT()

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Implemented
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: COMP - Compiler
    • Labels:
      None

      Description

      The following query performs projection pushdown correctly to project out records so that only pks are sorted:

      select count(*) from (select * from %s.%s where sid>=%d AND sid<=%d order by id) tmp;
      

      However, when a dataset variable is referenced by count(), projection pushdown is not working anymore and full records are sorted

      select count(tmp) from (select * from %s.%s where sid>=%d AND sid<=%d order by id) tmp;
      

        Attachments

          Activity

            People

            • Assignee:
              luochen01 Chen Luo
              Reporter:
              luochen01 Chen Luo
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: