Description
Attempting to create a view that has an IN (< subquery >) clause produces an error:
the error
Status: INTERNAL_ERROR
Issues:
<main>: Fatal: ydb/library/yql/sql/v1/context.cpp:165 GetCurrentBlocks(): requirement !CurrentBlocks.empty() failed, code: 1
Reproduction steps
- Create a base table.
CREATE TABLE series (
series_id Int32,
PRIMARY KEY (series_id)
);
- Execute the following query via the QueryService:
CREATE VIEW in_subquery_view WITH (security_invoker = TRUE) AS
SELECT
*
FROM series
WHERE series_id IN (
SELECT
series_id
FROM series
);
- Observe an error.
Tested versions