ClickHouse / clickhouse-odbc

ODBC driver for ClickHouse
https://clickhouse.tech
Apache License 2.0
239 stars 84 forks source link

Remove ODBC {escape '/'} escape sequence #413

Open Segate-ekb opened 1 year ago

Segate-ekb commented 1 year ago

ODBC driver version Release 1.2.1.20220905 Context: queries are generated from 1C enterprise.

Some {escape '/'} ODBC secape sequences are let as it by ODBC driver, so ClickHouse server issues a SQL error. Sample:

Error ODBC. SQLSTATE: HY000 Descripion: HTTP status code: 400 Received error: Code: 62. DB::Exception: Syntax error: failed at position 429 ('{') (line 27, col 37): {escape '/'}) OR (T1.Comment LIKE '%test%' {escape '/'}) OR (T1.Computer LIKE '%test%' {escape '/'}) OR (T1.Data LIKE '%test%' {escape '/'}) OR (T1.DataPresenta. Expected one of: token, DoubleColon, MOD, DIV, NOT, BETWEEN, LIKE, ILIKE, NOT LIKE, NOT ILIKE, IN, NOT IN, GLOBAL IN, GLOBAL NOT IN, IS, AND, OR, QuestionMark, alias, AS, Comma. (SYNTAX_ERROR) (version 22.9.3.18 (official bui

The {escape '/'} should at least be removed by ODBC driver (the targetted function is well known and supported by ClickHouse server).