You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ignite.apache.org by "Evgeny Stanilovsky (Jira)" <ji...@apache.org> on 2021/09/27 09:10:00 UTC

[jira] [Updated] (IGNITE-15586) Calcite. Failed to plan EXISTS with subquery.

     [ https://issues.apache.org/jira/browse/IGNITE-15586?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Stanilovsky updated IGNITE-15586:
----------------------------------------
    Description: 
{noformat}
statement ok
CREATE TABLE integers(i INTEGER)

statement ok
INSERT INTO integers VALUES (1), (2), (3), (NULL)

query IT
SELECT i, EXISTS(SELECT i FROM integers WHERE i1.i>i OR i1.i IS NULL) FROM integers i1 ORDER BY i NULLS FIRST;
----
NULL	true
1	false
2	true
3	true
{noformat}


{noformat}
statement ok
CREATE TABLE integers(i INTEGER)

statement ok
INSERT INTO integers VALUES (1), (2), (3), (NULL)

# nested correlated queries
query II
SELECT i, (SELECT (SELECT 42+i1.i)+42+i1.i) AS j FROM integers i1 ORDER BY i;
----
NULL	NULL
1	86
2	88
3	90
{noformat}



{noformat}
[2021-09-24 10:25:41,982][ERROR][test-runner-#132%srv0%][org.apache.ignite.internal.processors.query.calcite.exec.ExecutionServiceImplc{1}] Unexpected error at query optimizer.
org.apache.calcite.plan.RelOptPlanner$CannotPlanException: There are not enough rules to produce a node with desired properties:
{noformat}


{noformat}
/subquery/exists/test_correlated_exists.test[_ignore]
{noformat}



  was:

{noformat}
statement ok
CREATE TABLE integers(i INTEGER)

statement ok
INSERT INTO integers VALUES (1), (2), (3), (NULL)

query IT
SELECT i, EXISTS(SELECT i FROM integers WHERE i1.i>i OR i1.i IS NULL) FROM integers i1 ORDER BY i NULLS FIRST;
----
NULL	true
1	false
2	true
3	true
{noformat}


{noformat}
[2021-09-24 10:25:41,982][ERROR][test-runner-#132%srv0%][org.apache.ignite.internal.processors.query.calcite.exec.ExecutionServiceImplc{1}] Unexpected error at query optimizer.
org.apache.calcite.plan.RelOptPlanner$CannotPlanException: There are not enough rules to produce a node with desired properties:
{noformat}


{noformat}
/subquery/exists/test_correlated_exists.test[_ignore]
{noformat}




> Calcite. Failed to plan EXISTS with subquery.
> ---------------------------------------------
>
>                 Key: IGNITE-15586
>                 URL: https://issues.apache.org/jira/browse/IGNITE-15586
>             Project: Ignite
>          Issue Type: Improvement
>          Components: sql
>            Reporter: Evgeny Stanilovsky
>            Priority: Major
>              Labels: calcite, calcite2-required, calcite3-required, ignite-3
>
> {noformat}
> statement ok
> CREATE TABLE integers(i INTEGER)
> statement ok
> INSERT INTO integers VALUES (1), (2), (3), (NULL)
> query IT
> SELECT i, EXISTS(SELECT i FROM integers WHERE i1.i>i OR i1.i IS NULL) FROM integers i1 ORDER BY i NULLS FIRST;
> ----
> NULL	true
> 1	false
> 2	true
> 3	true
> {noformat}
> {noformat}
> statement ok
> CREATE TABLE integers(i INTEGER)
> statement ok
> INSERT INTO integers VALUES (1), (2), (3), (NULL)
> # nested correlated queries
> query II
> SELECT i, (SELECT (SELECT 42+i1.i)+42+i1.i) AS j FROM integers i1 ORDER BY i;
> ----
> NULL	NULL
> 1	86
> 2	88
> 3	90
> {noformat}
> {noformat}
> [2021-09-24 10:25:41,982][ERROR][test-runner-#132%srv0%][org.apache.ignite.internal.processors.query.calcite.exec.ExecutionServiceImplc{1}] Unexpected error at query optimizer.
> org.apache.calcite.plan.RelOptPlanner$CannotPlanException: There are not enough rules to produce a node with desired properties:
> {noformat}
> {noformat}
> /subquery/exists/test_correlated_exists.test[_ignore]
> {noformat}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)