You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flink.apache.org by 刘建刚 <li...@gmail.com> on 2019/10/29 07:39:16 UTC

How to use two continuously window with EventTime in sql

      For one sql window, I can register table with event time and use time
field in the tumble window. But if I want to use the result for the first
window and use another window to process it, how can I do it? Thank you.

Re: How to use two continuously window with EventTime in sql

Posted by Jark Wu <im...@gmail.com>.
Hi,

You can use TUMBLE_ROWTIME(...) to get the rowtime attribute of the first
window result, and use this field to apply a following window aggregate.
See more
https://ci.apache.org/projects/flink/flink-docs-master/dev/table/sql.html#group-windows

Best,
Jark

On Tue, 29 Oct 2019 at 15:39, 刘建刚 <li...@gmail.com> wrote:

>       For one sql window, I can register table with event time and use
> time field in the tumble window. But if I want to use the result for the
> first window and use another window to process it, how can I do it? Thank
> you.
>

Re: How to use two continuously window with EventTime in sql

Posted by Jark Wu <im...@gmail.com>.
Hi,

You can use TUMBLE_ROWTIME(...) to get the rowtime attribute of the first
window result, and use this field to apply a following window aggregate.
See more
https://ci.apache.org/projects/flink/flink-docs-master/dev/table/sql.html#group-windows

Best,
Jark

On Tue, 29 Oct 2019 at 15:39, 刘建刚 <li...@gmail.com> wrote:

>       For one sql window, I can register table with event time and use
> time field in the tumble window. But if I want to use the result for the
> first window and use another window to process it, how can I do it? Thank
> you.
>

Re: How to use two continuously window with EventTime in sql

Posted by Jark Wu <im...@gmail.com>.
Hi,

You can use TUMBLE_ROWTIME(...) to get the rowtime attribute of the first
window result, and use this field to apply a following window aggregate.
See more
https://ci.apache.org/projects/flink/flink-docs-master/dev/table/sql.html#group-windows

Best,
Jark

On Tue, 29 Oct 2019 at 15:39, 刘建刚 <li...@gmail.com> wrote:

>       For one sql window, I can register table with event time and use
> time field in the tumble window. But if I want to use the result for the
> first window and use another window to process it, how can I do it? Thank
> you.
>