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

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

                Author: ASF GitHub Bot
            Created on: 11/Dec/19 01:00
            Start Date: 11/Dec/19 01:00
    Worklog Time Spent: 10m 
      Work Description: amaliujia commented on pull request #9739: [BEAM-8362] 
Don't use toString() for accessing Enum Types
URL: https://github.com/apache/beam/pull/9739#discussion_r356357491
 
 

 ##########
 File path: 
sdks/java/extensions/sql/zetasql/src/main/java/org/apache/beam/sdk/extensions/sql/zetasql/translation/ExpressionConverter.java
 ##########
 @@ -661,8 +662,8 @@ private RexNode convertArrayValueToRexNode(ArrayType 
arrayType, Value value) {
     return rexBuilder().makeCall(SqlStdOperatorTable.ARRAY_VALUE_CONSTRUCTOR, 
operands);
   }
 
-  private RexNode convertEnumToRexNode(Type type, Value value) {
-    if (type.typeName().equals("`zetasql.functions.DateTimestampPart`")) {
+  private RexNode convertEnumToRexNode(EnumType type, Value value) {
+    if 
("zetasql.functions.DateTimestampPart".equals(type.getDescriptor().getFullName()))
 {
 
 Review comment:
   I see. So `type.getDescriptor().getFullName()` is a working path to get 
fullname in string.
 
----------------------------------------------------------------
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: 357548)
    Time Spent: 1h 50m  (was: 1h 40m)

> Don't use ZetaSQL's unimplemented functions
> -------------------------------------------
>
>                 Key: BEAM-8362
>                 URL: https://issues.apache.org/jira/browse/BEAM-8362
>             Project: Beam
>          Issue Type: New Feature
>          Components: dsl-sql-zetasql
>    Affects Versions: 2.15.0
>            Reporter: Andrew Pilloud
>            Assignee: Andrew Pilloud
>            Priority: Major
>          Time Spent: 1h 50m
>  Remaining Estimate: 0h
>
> Unfortunately a bunch of debug functionality is still unimplemented in 
> ZetaSQL. We should avoid calling those functions.



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

Reply via email to