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

Sergey Nuyanzin updated FLINK-29237:
------------------------------------
    Description: 
It seems there is some work should be done to make it happen
Currently removal of RexSimplify from Flink repo leads to failure of several 
tests like
{{IntervalJoinTest#testFallbackToRegularJoin}}
{{CalcITCase#testOrWithIsNullInIf}}
{{CalcITCase#testOrWithIsNullPredicate}}
example of failure
{noformat}
Sep 07 11:25:08 java.lang.AssertionError: 
Sep 07 11:25:08 
Sep 07 11:25:08 Results do not match for query:
Sep 07 11:25:08   
Sep 07 11:25:08 SELECT * FROM NullTable3 AS T
Sep 07 11:25:08 WHERE T.a = 1 OR T.a = 3 OR T.a IS NULL
Sep 07 11:25:08 
Sep 07 11:25:08 
Sep 07 11:25:08 Results
Sep 07 11:25:08  == Correct Result - 4 ==   == Actual Result - 2 ==
Sep 07 11:25:08  +I[1, 1, Hi]               +I[1, 1, Hi]
Sep 07 11:25:08  +I[3, 2, Hello world]      +I[3, 2, Hello world]
Sep 07 11:25:08 !+I[null, 999, NullTuple]   
Sep 07 11:25:08 !+I[null, 999, NullTuple]   
Sep 07 11:25:08         
Sep 07 11:25:08 Plan:
Sep 07 11:25:08   == Abstract Syntax Tree ==
Sep 07 11:25:08 LogicalProject(inputs=[0..2])
Sep 07 11:25:08 +- LogicalFilter(condition=[OR(=($0, 1), =($0, 3), IS 
NULL($0))])
Sep 07 11:25:08    +- LogicalTableScan(table=[[default_catalog, 
default_database, NullTable3]])
Sep 07 11:25:08 
Sep 07 11:25:08 == Optimized Logical Plan ==
Sep 07 11:25:08 Calc(select=[a, b, c], where=[SEARCH(a, Sarg[1, 3; NULL AS 
TRUE])])
Sep 07 11:25:08 +- BoundedStreamScan(table=[[default_catalog, default_database, 
NullTable3]], fields=[a, b, c])
Sep 07 11:25:08 
Sep 07 11:25:08        
Sep 07 11:25:08         at org.junit.Assert.fail(Assert.java:89)
Sep 07 11:25:08         at 
org.apache.flink.table.planner.runtime.utils.BatchTestBase.$anonfun$check$1(BatchTestBase.scala:154)
Sep 07 11:25:08         at 
org.apache.flink.table.planner.runtime.utils.BatchTestBase.$anonfun$check$1$adapted(BatchTestBase.scala:147)
Sep 07 11:25:08         at scala.Option.foreach(Option.scala:257)
Sep 07 11:25:08         at 
org.apache.flink.table.planner.runtime.utils.BatchTestBase.check(BatchTestBase.scala:147)
Sep 07 11:25:08         at 
org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:162)
Sep 07 11:25:08         at 
org.apache.maven.surefire.booter.ForkedBooter.run(ForkedBooter.java:562)
Sep 07 11:25:08         at 
org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:548)
Sep 07 11:25:08 

{noformat}

  was:

It seems there is some work should be done to make it happen
Currently removal of RexSimplify from Flink repo leads to failure of several 
tests like
{{IntervalJoinTest#testFallbackToRegularJoin}}
{{CalcITCase.testOrWithIsNullInIf}}
{{CalcITCase.testOrWithIsNullPredicate}}
example of failure
{noformat}
Sep 07 11:25:08 java.lang.AssertionError: 
Sep 07 11:25:08 
Sep 07 11:25:08 Results do not match for query:
Sep 07 11:25:08   
Sep 07 11:25:08 SELECT * FROM NullTable3 AS T
Sep 07 11:25:08 WHERE T.a = 1 OR T.a = 3 OR T.a IS NULL
Sep 07 11:25:08 
Sep 07 11:25:08 
Sep 07 11:25:08 Results
Sep 07 11:25:08  == Correct Result - 4 ==   == Actual Result - 2 ==
Sep 07 11:25:08  +I[1, 1, Hi]               +I[1, 1, Hi]
Sep 07 11:25:08  +I[3, 2, Hello world]      +I[3, 2, Hello world]
Sep 07 11:25:08 !+I[null, 999, NullTuple]   
Sep 07 11:25:08 !+I[null, 999, NullTuple]   
Sep 07 11:25:08         
Sep 07 11:25:08 Plan:
Sep 07 11:25:08   == Abstract Syntax Tree ==
Sep 07 11:25:08 LogicalProject(inputs=[0..2])
Sep 07 11:25:08 +- LogicalFilter(condition=[OR(=($0, 1), =($0, 3), IS 
NULL($0))])
Sep 07 11:25:08    +- LogicalTableScan(table=[[default_catalog, 
default_database, NullTable3]])
Sep 07 11:25:08 
Sep 07 11:25:08 == Optimized Logical Plan ==
Sep 07 11:25:08 Calc(select=[a, b, c], where=[SEARCH(a, Sarg[1, 3; NULL AS 
TRUE])])
Sep 07 11:25:08 +- BoundedStreamScan(table=[[default_catalog, default_database, 
NullTable3]], fields=[a, b, c])
Sep 07 11:25:08 
Sep 07 11:25:08        
Sep 07 11:25:08         at org.junit.Assert.fail(Assert.java:89)
Sep 07 11:25:08         at 
org.apache.flink.table.planner.runtime.utils.BatchTestBase.$anonfun$check$1(BatchTestBase.scala:154)
Sep 07 11:25:08         at 
org.apache.flink.table.planner.runtime.utils.BatchTestBase.$anonfun$check$1$adapted(BatchTestBase.scala:147)
Sep 07 11:25:08         at scala.Option.foreach(Option.scala:257)
Sep 07 11:25:08         at 
org.apache.flink.table.planner.runtime.utils.BatchTestBase.check(BatchTestBase.scala:147)
Sep 07 11:25:08         at 
org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:162)
Sep 07 11:25:08         at 
org.apache.maven.surefire.booter.ForkedBooter.run(ForkedBooter.java:562)
Sep 07 11:25:08         at 
org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:548)
Sep 07 11:25:08 

{noformat}


> RexSimplify can not be removed after update to calcite 1.27
> -----------------------------------------------------------
>
>                 Key: FLINK-29237
>                 URL: https://issues.apache.org/jira/browse/FLINK-29237
>             Project: Flink
>          Issue Type: Sub-task
>          Components: Table SQL / API, Table SQL / Planner
>            Reporter: Sergey Nuyanzin
>            Priority: Major
>
> It seems there is some work should be done to make it happen
> Currently removal of RexSimplify from Flink repo leads to failure of several 
> tests like
> {{IntervalJoinTest#testFallbackToRegularJoin}}
> {{CalcITCase#testOrWithIsNullInIf}}
> {{CalcITCase#testOrWithIsNullPredicate}}
> example of failure
> {noformat}
> Sep 07 11:25:08 java.lang.AssertionError: 
> Sep 07 11:25:08 
> Sep 07 11:25:08 Results do not match for query:
> Sep 07 11:25:08   
> Sep 07 11:25:08 SELECT * FROM NullTable3 AS T
> Sep 07 11:25:08 WHERE T.a = 1 OR T.a = 3 OR T.a IS NULL
> Sep 07 11:25:08 
> Sep 07 11:25:08 
> Sep 07 11:25:08 Results
> Sep 07 11:25:08  == Correct Result - 4 ==   == Actual Result - 2 ==
> Sep 07 11:25:08  +I[1, 1, Hi]               +I[1, 1, Hi]
> Sep 07 11:25:08  +I[3, 2, Hello world]      +I[3, 2, Hello world]
> Sep 07 11:25:08 !+I[null, 999, NullTuple]   
> Sep 07 11:25:08 !+I[null, 999, NullTuple]   
> Sep 07 11:25:08         
> Sep 07 11:25:08 Plan:
> Sep 07 11:25:08   == Abstract Syntax Tree ==
> Sep 07 11:25:08 LogicalProject(inputs=[0..2])
> Sep 07 11:25:08 +- LogicalFilter(condition=[OR(=($0, 1), =($0, 3), IS 
> NULL($0))])
> Sep 07 11:25:08    +- LogicalTableScan(table=[[default_catalog, 
> default_database, NullTable3]])
> Sep 07 11:25:08 
> Sep 07 11:25:08 == Optimized Logical Plan ==
> Sep 07 11:25:08 Calc(select=[a, b, c], where=[SEARCH(a, Sarg[1, 3; NULL AS 
> TRUE])])
> Sep 07 11:25:08 +- BoundedStreamScan(table=[[default_catalog, 
> default_database, NullTable3]], fields=[a, b, c])
> Sep 07 11:25:08 
> Sep 07 11:25:08        
> Sep 07 11:25:08       at org.junit.Assert.fail(Assert.java:89)
> Sep 07 11:25:08       at 
> org.apache.flink.table.planner.runtime.utils.BatchTestBase.$anonfun$check$1(BatchTestBase.scala:154)
> Sep 07 11:25:08       at 
> org.apache.flink.table.planner.runtime.utils.BatchTestBase.$anonfun$check$1$adapted(BatchTestBase.scala:147)
> Sep 07 11:25:08       at scala.Option.foreach(Option.scala:257)
> Sep 07 11:25:08       at 
> org.apache.flink.table.planner.runtime.utils.BatchTestBase.check(BatchTestBase.scala:147)
> Sep 07 11:25:08       at 
> org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:162)
> Sep 07 11:25:08       at 
> org.apache.maven.surefire.booter.ForkedBooter.run(ForkedBooter.java:562)
> Sep 07 11:25:08       at 
> org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:548)
> Sep 07 11:25:08 
> {noformat}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to