You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@beam.apache.org by "Andrew Pilloud (Jira)" <ji...@apache.org> on 2020/05/13 21:07:00 UTC

[jira] [Commented] (BEAM-9522) BeamJoinRel.extractJoinRexNode RexLiteral cannot be cast to RexCall

    [ https://issues.apache.org/jira/browse/BEAM-9522?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17106667#comment-17106667 ] 

Andrew Pilloud commented on BEAM-9522:
--------------------------------------

My understanding is that expressions are simplified before they reach this code, so `ON 1=2` would be the same as `ON false`. There is a lot of work to get this working, so I'm going to just reject it like we do with CROSS JOIN.

> BeamJoinRel.extractJoinRexNode RexLiteral cannot be cast to RexCall
> -------------------------------------------------------------------
>
>                 Key: BEAM-9522
>                 URL: https://issues.apache.org/jira/browse/BEAM-9522
>             Project: Beam
>          Issue Type: Bug
>          Components: dsl-sql-zetasql
>            Reporter: Andrew Pilloud
>            Assignee: Andrew Pilloud
>            Priority: Major
>              Labels: zetasql-compliance
>
> One failure in shard 2, One failure in shard 35
> {code:java}
> java.lang.ClassCastException: org.apache.beam.vendor.calcite.v1_20_0.org.apache.calcite.rex.RexLiteral cannot be cast to org.apache.beam.vendor.calcite.v1_20_0.org.apache.calcite.rex.RexCall
> 	at org.apache.beam.sdk.extensions.sql.impl.rel.BeamJoinRel.extractJoinRexNodes(BeamJoinRel.java:304)
> 	at org.apache.beam.sdk.extensions.sql.impl.rel.BeamJoinRel$ExtractJoinKeys.expand(BeamJoinRel.java:194)
> 	at org.apache.beam.sdk.extensions.sql.impl.rel.BeamJoinRel$ExtractJoinKeys.expand(BeamJoinRel.java:177)
> 	at org.apache.beam.sdk.Pipeline.applyInternal(Pipeline.java:542)
> 	at org.apache.beam.sdk.Pipeline.applyTransform(Pipeline.java:476)
> 	at org.apache.beam.sdk.values.PCollectionList.apply(PCollectionList.java:178)
> 	at org.apache.beam.sdk.extensions.sql.impl.rel.BeamCoGBKJoinRel$StandardJoin.expand(BeamCoGBKJoinRel.java:93)
> 	at org.apache.beam.sdk.extensions.sql.impl.rel.BeamCoGBKJoinRel$StandardJoin.expand(BeamCoGBKJoinRel.java:86)
> 	at org.apache.beam.sdk.Pipeline.applyInternal(Pipeline.java:542)
> 	at org.apache.beam.sdk.Pipeline.applyTransform(Pipeline.java:493)
> 	at org.apache.beam.sdk.extensions.sql.impl.rel.BeamSqlRelUtils.toPCollection(BeamSqlRelUtils.java:69)
> 	at org.apache.beam.sdk.extensions.sql.impl.rel.BeamSqlRelUtils.lambda$buildPCollectionList$0(BeamSqlRelUtils.java:50)
> 	at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
> 	at java.util.Iterator.forEachRemaining(Iterator.java:116)
> 	at java.util.Spliterators$IteratorSpliterator.forEachRemaining(Spliterators.java:1801)
> 	at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481)
> 	at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)
> 	at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708)
> 	at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
> 	at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499)
> 	at org.apache.beam.sdk.extensions.sql.impl.rel.BeamSqlRelUtils.buildPCollectionList(BeamSqlRelUtils.java:51)
> 	at org.apache.beam.sdk.extensions.sql.impl.rel.BeamSqlRelUtils.toPCollection(BeamSqlRelUtils.java:67)
> 	at org.apache.beam.sdk.extensions.sql.impl.rel.BeamSqlRelUtils.toPCollection(BeamSqlRelUtils.java:39)
> 	at cloud.dataflow.sql.ExecuteQueryServiceServer$SqlComplianceServiceImpl.executeQuery(ExecuteQueryServiceServer.java:288)
> 	at com.google.zetasql.testing.SqlComplianceServiceGrpc$MethodHandlers.invoke(SqlComplianceServiceGrpc.java:423)
> 	at com.google.zetasql.io.grpc.stub.ServerCalls$UnaryServerCallHandler$UnaryServerCallListener.onHalfClose(ServerCalls.java:171)
> 	at com.google.zetasql.io.grpc.internal.ServerCallImpl$ServerStreamListenerImpl.halfClosed(ServerCallImpl.java:283)
> 	at com.google.zetasql.io.grpc.internal.ServerImpl$JumpToApplicationThreadServerStreamListener$1HalfClosed.runInContext(ServerImpl.java:711)
> 	at com.google.zetasql.io.grpc.internal.ContextRunnable.run(ContextRunnable.java:37)
> 	at com.google.zetasql.io.grpc.internal.SerializingExecutor.run(SerializingExecutor.java:123)
> 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
> 	at java.lang.Thread.run(Thread.java:748)
> {code}
> {code}
> Apr 01, 2020 3:55:13 PM cloud.dataflow.sql.ExecuteQueryServiceServer$SqlComplianceServiceImpl executeQuery
> INFO: Processing Sql statement: SELECT R_sub.id as col1, R_sub.a as col2, T_sub.string_val as col3
> FROM (SELECT R.id, R.a FROM R) as R_sub
> FULL JOIN (SELECT T.string_val FROM T) as T_sub on false
> Apr 01, 2020 3:54:46 PM cloud.dataflow.sql.ExecuteQueryServiceServer$SqlComplianceServiceImpl executeQuery
> INFO: Processing Sql statement: SELECT r.*, s.* FROM
> (SELECT x, x FROM (SELECT 2 x)) r FULL JOIN (SELECT 3) s ON false
> {code}



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