Julian Hyde created CALCITE-2540:
------------------------------------

             Summary: Streaming Sort relational operator
                 Key: CALCITE-2540
                 URL: https://issues.apache.org/jira/browse/CALCITE-2540
             Project: Calcite
          Issue Type: Bug
            Reporter: Julian Hyde
            Assignee: Julian Hyde


Add a sub-class of the Sort operator that takes advantage of the fact that its 
input is sorted on a prefix of the key.

For example, given the relation "select * from t order by x" it is easier to 
compute "select * from t order by x, y". The Sort operator can spot when the 
value of "x" changes, flush all of its input, and start sorting on values of 
"y" until the value of "x" changes again.

I don't know whether to call this "weak" sort or "partial sort". It's 
"streaming" in the sense that it can produce output before it sees all of the 
input (and therefore requires less memory); it is not just applicable to 
streaming SQL.



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

Reply via email to