You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@drill.apache.org by "Timothy Chen (JIRA)" <ji...@apache.org> on 2013/02/14 10:42:12 UTC

[jira] [Commented] (DRILL-35) Implement RunningAggregate Reference Operator

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

Timothy Chen commented on DRILL-35:
-----------------------------------

A bit confused what this operator suppose to output. I thought the existing AggregateSimpleROP is the impl of CollapsingAggregator, but it doesn't define carryovers, etc. 

So according to the plan doc, the list of aggregates are re-evaluated on each record which I will interpret that it does the aggregation on a per record basis, so given rows:

ppu: 15
sales: 10

ppu: 10
sales: 30

the aggregate of summary = sum(ppu * sales) will output

summary = 450

Which differs from CollapseAggregate where it has a key input for boundry, and aggregations are done per boundry. 

However, the within field can specify a boundry which I'm not sure what that meant? Does this mean the aggregation is done within a boundry?
                
> Implement RunningAggregate Reference Operator
> ---------------------------------------------
>
>                 Key: DRILL-35
>                 URL: https://issues.apache.org/jira/browse/DRILL-35
>             Project: Apache Drill
>          Issue Type: New Feature
>            Reporter: Timothy Chen
>            Assignee: Timothy Chen
>              Labels: logical
>
> RunningAggregate (1)
> The running aggregate operator takes an input record and adds appends a set of running aggregations and outputs the resulting record.  The aggregations are re-evaluated on each record within the incoming segment in the order they are provided.  Segment focus can be defined with the ‘within’ value such that aggregations are reset at each segment boundary.
> { @id†: <opref>, op: “runningaggregate”, 
>   input†: <input>, 
>   within*: <name>, 
>   aggregations: [
>     {ref: <name>, expr: <aggexpr> },...
>   ]
> }

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira