开发者社区> 问答> 正文

Table api 中指定rowtime的问题

          当我把DataStream流转成Table,并且指定了rowtime,然后使用带有udtf的sql传入tableEnv.sql(),抛出如下错误:Rowtime attributes must not be in the input rows of a regular join. As a workaround you can cast the time attributes of input tables to TIMESTAMP before. 我也按照提示使用to_timestamp函数套在eventTime的外面,并没有起作用,请求如何解决?先是sql,eventTime是事件时间。 

sql: select 

                  tmp.metric_id as metric_id, 

                  tmp.metric_config as metric_config, 

                  startLat, 

                  destName, 

                  bizType, 

                  orderId, 

                  completedTime, 

                  orderStatus, 

                  startHexList, 

                  cityId, 

                  type, 

                  destLat, 

                  endHexList, 

                  destLng, 

                  createTime, 

                  passengerId, 

                  finishedTime, 

                  vehicleId, 

                  startLng, 

                  startName, 

                  eventTime 

                from 

                  htw_order_dwd_htw_order_geo_Infos, 

                  lateral table( 

                    metricUdtf('aa') 

                  ) as tmp(metric_id, metric_config)*来自志愿者整理的flink邮件归档

展开
收起
又出bug了-- 2021-12-02 11:44:52 600 0
1 条回答
写回答
取消 提交回答
  • 可以试下 CAST(eventTime AS TIMESTAMP)*来自志愿者整理的FLINK邮件归档

    2021-12-02 14:50:20
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
CUDA MATH API 立即下载
API PLAYBOOK 立即下载
传统企业的“+互联网”-API服务在京东方的实践 立即下载