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

ASF GitHub Bot commented on DRILL-7406:
---------------------------------------

paul-rogers commented on pull request #1940: DRILL-7406: Update Calcite to 
1.21.0
URL: https://github.com/apache/drill/pull/1940#discussion_r361894195
 
 

 ##########
 File path: 
contrib/storage-hive/core/src/test/java/org/apache/drill/exec/hive/complex_types/TestHiveStructs.java
 ##########
 @@ -476,4 +476,25 @@ public void strWithUnionField() throws Exception {
         .baselineValues(2, mapOf("n", 5, "u", "Text"))
         .go();
   }
+
+  @Test // DRILL-7386
+  public void countStructColumn() throws Exception {
+    testBuilder()
+        .sqlQuery("SELECT COUNT(str_n0) cnt FROM hive.struct_tbl")
+        .unOrdered()
+        .baselineColumns("cnt")
+        .baselineValues(3L)
+        .go();
+  }
+
+  @Test // DRILL-7386
+  public void typeOfFunctions() throws Exception {
+    testBuilder()
+        .sqlQuery("SELECT sqlTypeOf(%1$s) sto, typeOf(%1$s) to, modeOf(%1$s) 
mo, drillTypeOf(%1$s) dto " +
+            "FROM hive.struct_tbl LIMIT 1", "str_n0")
+        .unOrdered()
+        .baselineColumns("sto", "to", "mo", "dto")
+        .baselineValues("STRUCT", "MAP", "NOT NULL", "MAP")
 
 Review comment:
   Should we test this for more than a single case?
 
----------------------------------------------------------------
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]


> Update Calcite to 1.21.0
> ------------------------
>
>                 Key: DRILL-7406
>                 URL: https://issues.apache.org/jira/browse/DRILL-7406
>             Project: Apache Drill
>          Issue Type: Task
>          Components: Query Planning & Optimization, SQL Parser
>    Affects Versions: 1.17.0
>            Reporter: Igor Guzenko
>            Assignee: Igor Guzenko
>            Priority: Major
>             Fix For: 1.18.0
>
>
> DRILL-7340 should be fixed by this update.



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

Reply via email to