2024-04-02 16:43:12 +00:00
|
|
|
-- https://github.com/ClickHouse/ClickHouse/issues/14978
|
2024-07-12 12:49:26 +00:00
|
|
|
SET enable_analyzer=1;
|
2024-04-02 16:43:12 +00:00
|
|
|
CREATE TABLE test1(id UInt64, t1value UInt64) ENGINE=MergeTree ORDER BY tuple();
|
|
|
|
CREATE TABLE test2(id UInt64, t2value String) ENGINE=MergeTree ORDER BY tuple();
|
|
|
|
|
|
|
|
SELECT NULL AS t2value
|
|
|
|
FROM test1 t1
|
|
|
|
LEFT JOIN (
|
|
|
|
SELECT id, t2value FROM test2
|
|
|
|
) t2
|
|
|
|
ON t1.id=t2.id
|
|
|
|
WHERE t2.t2value='test';
|
|
|
|
|
|
|
|
-- workaround should work too
|
|
|
|
SELECT NULL AS _svalue
|
|
|
|
FROM test1 t1
|
|
|
|
LEFT JOIN (
|
|
|
|
SELECT id, t2value FROM test2
|
|
|
|
) t2
|
|
|
|
ON t1.id=t2.id
|
|
|
|
WHERE t2.t2value='test';
|