[ 
https://issues.apache.org/jira/browse/BEAM-11747?focusedWorklogId=575260&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-575260
 ]

ASF GitHub Bot logged work on BEAM-11747:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 01/Apr/21 00:51
            Start Date: 01/Apr/21 00:51
    Worklog Time Spent: 10m 
      Work Description: ibzib commented on a change in pull request #14241:
URL: https://github.com/apache/beam/pull/14241#discussion_r605309390



##########
File path: 
sdks/java/extensions/sql/zetasql/src/main/java/org/apache/beam/sdk/extensions/sql/zetasql/BeamJavaUdfCalcRule.java
##########
@@ -52,4 +117,57 @@ public RelNode convert(RelNode rel) {
         RelOptRule.convert(input, 
input.getTraitSet().replace(BeamLogicalConvention.INSTANCE)),
         calc.getProgram());
   }
+
+  /**
+   * Returns true only if the literal can be correctly implemented by {@link
+   * org.apache.beam.sdk.extensions.sql.impl.rel.BeamCalcRel} in ZetaSQL.
+   */
+  private static boolean udfSupportsLiteral(RexLiteral rexLiteral) {
+    switch (rexLiteral.getType().getSqlTypeName()) {
+      case BIGINT:
+      case BOOLEAN:
+      case DECIMAL:
+      case DOUBLE:
+      case TIME:
+      case TIMESTAMP:
+      case TIMESTAMP_WITH_LOCAL_TIME_ZONE:
+      case VARBINARY:

Review comment:
       Oops, missed those. Done.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Issue Time Tracking
-------------------

    Worklog Id:     (was: 575260)
    Time Spent: 14h 10m  (was: 14h)

> Reject the mixed Java UDF and ZetaSQL builtin operators cases 
> --------------------------------------------------------------
>
>                 Key: BEAM-11747
>                 URL: https://issues.apache.org/jira/browse/BEAM-11747
>             Project: Beam
>          Issue Type: Sub-task
>          Components: dsl-sql-zetasql
>            Reporter: Rui Wang
>            Assignee: Rui Wang
>            Priority: P2
>             Fix For: 2.29.0
>
>          Time Spent: 14h 10m
>  Remaining Estimate: 0h
>
> Before we have Calc splitting implemented, we can reject the mixed Java UDF 
> and ZetaSQL builtin operators cases to maintain the correctness of a query.



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

Reply via email to