当前位置:网站首页>Flink Sql -- toAppendStream doesn‘t support consuming update and delete changes which
Flink Sql -- toAppendStream doesn‘t support consuming update and delete changes which
2022-06-30 08:27:00 【//承续缘_纪录片】
在Flink sql进行测试输出, 想把 sql查询的结果Table 转为DataStream 然后进行打印
当我们table.toAppendStream[Row]的时候 发现报错
其实这个因为我们sql 查的那个动态表 是Mysql 这类源, 他们是可以进行update,delete,insert操作的。
对于toAppendStream呢 是仅可以将追加流进行转换输出 比如kafka
所以我们使用
table.toRetractStream[Row].print() 即可
这操作呢打印结果是一个有两部分, 前面部分为boolean类型, 后面是你的select 其中 true表示insert ,false表示 update/delete
table.toRetractStream[Row].print() 即可
tableEnv.toRetractStream(table,EventLog.class).print();
对于Table / sql 转 Stream 可以看官网也有详细的讲解
官网
边栏推荐
- Deploy the cow like customer network project on the ECS
- Gilbert Strang's course notes on linear algebra - Lesson 1
- Enter the URL in the browser and display it on the page
- [nvme2.0b 14 - 5] commande de téléchargement / commande du logiciel
- Cesium learning notes (I)
- TiDB 6.0:让 TSO 更高效丨TiDB Book Rush
- 增强for循环的增删操作 & 迭代器删除集合元素
- 【NVMe2.0b 14-2】Create/Delete Queue
- 1162 Postfix Expression
- 微信公众号第三方平台开发,零基础入门。想学我教你啊
猜你喜欢

Opencv4.2.0+vs2015 configuration

Redis设计与实现(三)| 服务器与客户端的交互(事件IO模型)

MySQL cannot connect to the intranet database

1162 Postfix Expression

微信公众号第三方平台开发,零基础入门。想学我教你啊

Swagger use

Gilbert Strang's course notes on linear algebra - Lesson 2

Redis design and Implementation (II) | database (deletion strategy & expiration elimination strategy)

电流探头的干扰源电流谱测试
![[JUC series] overview of fork/join framework](/img/49/2cadac7818b0c1100539fd32ec0d37.png)
[JUC series] overview of fork/join framework
随机推荐
在浏览器输入url到页面展示出来
Opencv video
Experiment 3 remote control
自制GIF动态图-gifcam
Want to ask, how to choose securities companies for stock speculation? Is it safe to open an account online?
牛客小白月賽52
2021-02-22
Cesium learning notes (II) uploading data using rest API
Sword finger offer II 074 Merge interval (sort, array)
【NVMe2.0b 14-3】Doorbell Buffer Config command、Device Self-test command
Enter the URL in the browser and display it on the page
Circuit analysis of current probe
【NVMe2.0b 14-1】Abort、Asynchronous Event Request、Capacity Management command
Applet uses QR code plug-in
Deploy the cow like customer network project on the ECS
What are the Amazon evaluation terms?
2021-04-29
vulfocus入门靶机
vite项目require语法兼容问题解决require is not defined
[nvme2.0b 14-7] set features (Part 1)