-
Notifications
You must be signed in to change notification settings - Fork 3k
JDBC Catalog:Change SQL like escape character from '\\' to '!' #9407
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
Conversation
JDBC Catalog:Change the escape character "\" to "!", to solve the problem that in MySQL the escaped '\' must be written as '\\';
|
fixes #10056 @xuchuanqiu can you rebase this one please to fix the merge conflicts? |
| + " = ? OR " | ||
| + TABLE_NAMESPACE | ||
| + " LIKE ? ESCAPE '\\' " | ||
| + " LIKE ? ESCAPE '!' " |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does it work with any backend like PostgreSQL ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested without problem with PostgreSQL
jbonofre
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I didn't know this ! notation. I will test on PostgreSQL and MySQL to be sure it works with these vendors.
|
If @xuchuanqiu doesn't have the bandwidth, I can help on this one. If it works with MySQL, SQLlite and PostgreSQL, it's a nice fix to include in Iceberg 1.5.1. |
|
I've added this to the 1.5.1 milestone. If we validate that it works on all the backends as expected, then I think we can include in the patch release (we'll also discuss this in the community sync today). |
|
I tested with MySQL 8.3.0 (both server and JDBC driver) and I confirm the I'm doing the same test with PostgreSQL now, to be sure the same statement works fine with PostgreSQL. |
|
I also tested with PostgreSQL 42.7.3 and it works fine. In order to fix the conflict, I propose to create a clean PR. |
|
Replaced by #10167 to merge the conflict. |
|
Thanks @jbonofre ! Discussed offline, we'll ensure that @xuchuanqiu gets co-authorship/attribution. Thanks @xuchuanqiu |
|
I'll close this since #9407 has been merged, thanks @xuchuanqiu @jbonofre ! |
JDBC Catalog:Change the escape character "" to "!", to solve the problem that in MySQL the escaped '' must be written as '\';