Hi Joe,
Window TVF is supported since Flink 1.13, while 1.12 does not support yet.
Please upgrade to 1.13 version, or use the old Group Window Aggregate [1]
syntax in 1.12.

[1]
https://ci.apache.org/projects/flink/flink-docs-release-1.12/dev/table/sql/queries.html#group-windows

Best,
JING ZHANG


Joseph Lorenzini <jlorenz...@gohealth.com> 于2021年8月6日周五 上午6:15写道:

> Hi all,
>
>
>
> I am on flink 1.12.3. I am trying to get a tumbling window work with the
> table API as documented here:
>
>
>
>
> https://ci.apache.org/projects/flink/flink-docs-master/docs/dev/table/sql/queries/window-tvf/#tumble
>
>
>
> I have a kafka topic as a flink source. I convert the stream into a table
> using the StreamTableEnvironment#fromDataStream method. Then, once the
> table is registered in. I attempt to execute this table api SQL:
>
>
>
> SELECT window_start, window_end, avg(state_ts)
>
> FROM TABLE(TUMBLE(TABLE lead_buffer, DESCRIPTOR(proctime), INTERVAL '1'
> MINUTES))
>
>                GROUP BY window_start, window_end
>
>
>
> However, this exception is thrown:
>
>
>
> Caused by: org.apache.calcite.plan.RelOptPlanner$CannotPlanException:
> There are not enough rules to produce a node with desired properties:
> convention=STREAM_PHYSICAL, FlinkRelDistributionTraitDef=any,
> MiniBatchIntervalTraitDef=None: 0, ModifyKindSetTraitDef=[NONE],
> UpdateKindTraitDef=[NONE]
>
>
>
>
>
> Does anyone have any idea about what I might be doing wrong here?
>
>
>
> Thanks,
>
> Joe
> Privileged/Confidential Information may be contained in this message. If
> you are not the addressee indicated in this message (or responsible for
> delivery of the message to such person), you may not copy or deliver this
> message to anyone. In such case, you should destroy this message and kindly
> notify the sender by reply email. Please advise immediately if you or your
> employer does not consent to Internet email for messages of this kind.
> Opinions, conclusions and other information in this message that do not
> relate to the official business of my firm shall be understood as neither
> given nor endorsed by it.
>

Reply via email to