You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2018/06/16 02:38:00 UTC

[jira] [Commented] (CALCITE-1234) Annotate table functions to allow pushing down project, filter

    [ https://issues.apache.org/jira/browse/CALCITE-1234?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16514637#comment-16514637 ] 

ASF GitHub Bot commented on CALCITE-1234:
-----------------------------------------

Github user F21 commented on the issue:

    https://github.com/apache/calcite-avatica-go/pull/24
  
    @kenshaw Thanks, this is a good idea! As this project is now part of the Apache Calcite project and the change is not trivial, can you please do the following:
    - Open an issue in JIRA and set the component to `avatica-go`: https://issues.apache.org/jira/projects/CALCITE/issues
    - Update your commit message to reflect the JIRA issue number and include your name, ex: `[CALCITE-1234] Change UUID package to github.com/hashicorp/go-uuid (Ken Shaw)`
    
    Thanks! 😄 


> Annotate table functions to allow pushing down project, filter
> --------------------------------------------------------------
>
>                 Key: CALCITE-1234
>                 URL: https://issues.apache.org/jira/browse/CALCITE-1234
>             Project: Calcite
>          Issue Type: Bug
>            Reporter: Julian Hyde
>            Assignee: Julian Hyde
>            Priority: Major
>
> In general it is not possible to push relational operators through table functions but many table functions have properties that will allow push down: for instance, they might preserve fields, preserve row count, return rows in the same order. If we annotate a table function with these properties, we can automatically push down a Filter, and so forth.
> Some ideas:
> * {{PreservesFieldNames}}: If an output field has the same name as an input field, it is assumed to be the same field.
> * {{PreservesRows}}: Each input row causes exactly one output row, in the same order.
> * {{FiltersRows}}: Each input row causes at most one output row, in the same order.
> * {{PreservesFieldPositions}}: The leading N columns of the output are equivalent to the leading N columns of the input.
> If {{(PreservesFieldNames or PreservesFieldPositions) and (PreservesRows or FiltersRows)}}, it is safe to push down a Filter if all of the fields of the predicate exist in the input.
> Similarly pushing down a Project; and we can push down an Aggregate if {{PreservesRows}}.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)