You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Error handling the CTE INSERT command: Failed to parse SQL. #3279
High Level Area Labels:
- jdbc-v2
Specific Area Labels:
- jdbc-insert
- client-insert
Description
Steps to reproduce
for examples , create table test123
CREATETABLEIF NOT EXISTS test123
(
`timestamp` DateTime64(9, 'UTC'),
`eid` UInt64,
) ENGINE = MergeTree()
PARTITION BY toYYYYMMDD(timestamp)
ORDER BY (timestamp);
execute this sql
with a as (
SELECTtimestamp,eid
FROM test123
),
b as ( SELECTtimestamp,eid
FROM test123 )
insert into test123(`timestamp`,eid)
SELECT a.`timestamp`,b.eidFROM a left join b ona.eid=b.eid ;
The SQL server executed successfully, but the client-side parsing failed,Maybe this is a bug in the JavaCC parser
Error Log or Exception StackTrace
WARN c.c.j.i.p.j.ClickHouseSqlParser [76] - Failed to parse SQL. If you believe the SQL is valid, please feel free to open an issue on GitHub with this warning. Enable DEBUG logging for details.
This is a logging issue because client may not follow ClickHouse in syntax parsing and we just use parser to get needed information.
Fix in parser may break someone`s case.
Activity
fiend19961 commentedon Nov 12, 2026
ClickHouse/ClickHouse#85368
ClickHouse/ClickHouse#87789
same issues @chernser
chernser commentedon Nov 17, 2026
@fiend19961
Thank you for reporting!
Will be fixed as part of #3300
This is a logging issue because client may not follow ClickHouse in syntax parsing and we just use parser to get needed information.
Fix in parser may break someone`s case.