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

sql_mode 能不能加一下这个ALLOW_INVALID_DATES 这样的话 tidb的 cdc 就可以直接增量同步数据到 starrocks 了 。 #55335

Open
heming79 opened this issue Jan 22, 2025 · 2 comments

Comments

@heming79
Copy link

mysql> set sql_mode='ONLY_FULL_GROUP_BY,ALLOW_INVALID_DATES' ;
ERROR 1231 (42000): Variable 'sql_mode' can't be set to the value of 'ALLOW_INVALID_DATES'

我在tidb 启动 ticdc 往starrocks 同步数据时 报错:
Error: [CDC:ErrMySQLConnectionError]fail to open MySQL connection: Error 1231 (42000): Variable 'sql_mode' can't be set to the value of 'ALLOW_INVALID_DATES'

希望 starrocks sql_mode 加一下这个ALLOW_INVALID_DATES 这样的话 tidb的 cdc 就可以直接增量同步数据到 starrocks 了 。

联系人: starrocks社群群4 何明 陈磊

@jaogoy
Copy link
Contributor

jaogoy commented Jan 22, 2025

  1. Then, what's the behavior when inserting a invalid date, like '2025-02-30'? Set it to NULL?
  2. If you just want to ignore ALLOW_INVALID_DATES, and everything works fine, you can just add it into fe/fe-core/src/main/java/com/starrocks/qe/SqlModeHelper.java, and let some members to review it. It's not difficult.

@heming79
Copy link
Author

你们可以测试一下吗? 可以提交commit 上去吗?

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