Please support doubled single quote in SQL according to the ANSI standard
Bug Description:
We use the official MySQL Java driver to connect to Manticore via MySQL protocol (https://github.com/mysql/mysql-connector-j). The problem appeared in the recent versions of this driver when they changed the way they escaping single quotes in SQL. The latest working version was 8.0.17 that escaped single quote as \', in next versions they switched to the '' option. Example of the SQL that the driver prepares from a prepared statement before sending it to Manticore. The old way in older drivers:
INSERT INTO table (name) VALUES ('Peter\'s');vs the new way in newer drivers:
INSERT INTO table (name) VALUES ('Peter''s');We tried to contribute it as a bug to mysql driver developers and they refused to change the code to switch back to \' (https://bugs.mysql.com/bug.php?id=115992). Citing them "... Doubling quotes is the preferred way of escaping a quote char in a MySQL string, regardless of ANSI_QUOTES mode being active or not. As such, this patch should have no impact in the Connector's behavior neither fixes any problem. ...". MySQL actually supports both ways of single quote escaping: \' and ''.
Is there any way you can support double quotes in SQL in Manticore, it will allow to use the latest official MySQL drivers with Java?
Manticore Search Version:
6.3.2
Operating System Version:
Debian 6.9.9-1
Have you tried the latest development version?
No
Internal Checklist:
To be completed by the assignee. Check off tasks that have been completed or are not applicable.
- Implementation completed
- Tests developed
- Documentation updated
- Documentation reviewed
- Changelog updated
Source: manticoresoftware/manticoresearch