Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

java.lang.String cannot be cast to java.math.BigDecimal #382

Closed
xjs513 opened this issue Sep 10, 2019 · 1 comment
Closed

java.lang.String cannot be cast to java.math.BigDecimal #382

xjs513 opened this issue Sep 10, 2019 · 1 comment

Comments

@xjs513
Copy link

xjs513 commented Sep 10, 2019

数据在文件中,金额的格式是:10.00
ClickHouse 定义的金额是 Decimal(18, 2)
然后导入数据报如题异常,请问如何处理

@RickyHuo
Copy link
Contributor

需要在filter阶段转换数据结构。

Decimal 格式的数据, 使用sql 插件转换, CAST(source AS DECIMAL(P, S))

详情参考 https://interestinglab.github.io/waterdrop/#/zh-cn/configuration/output-plugins/Clickhouse?id=clickhouse%e7%b1%bb%e5%9e%8b%e5%af%b9%e7%85%a7%e8%a1%a8

@RickyHuo RickyHuo mentioned this issue Oct 23, 2020
Closed
ruanwenjun pushed a commit to ruanwenjun/incubator-seatunnel that referenced this issue Nov 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants