[
https://issues.apache.org/jira/browse/DRILL-7501?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Paul Rogers resolved DRILL-7501.
--------------------------------
Resolution: Won't Fix
As explained on the dev list, the return value in this case was changed to
match the preferred name {{STRUCT}} for what Drill has historically called a
{{MAP}}. The name {{STRUCT}} is consistent with Hive.
> Drill 1.17 sqlTypeOf for a Map now reports STRUCT
> -------------------------------------------------
>
> Key: DRILL-7501
> URL: https://issues.apache.org/jira/browse/DRILL-7501
> Project: Apache Drill
> Issue Type: Bug
> Affects Versions: 1.16.0
> Reporter: Paul Rogers
> Assignee: Paul Rogers
> Priority: Minor
>
> Drill 1.14 introduced the {{sqlTypeOf()}} function to workaround limits of
> the {{typeof()}} function. {{sqlTypeOf()}} should return the name of the SQL
> type for a column, using the type name that Drill uses.
> A query from page 163 of _Learning Apache Drill_:
> {code:sql}
> SELECT sqlTypeOf(`name`) AS name_type FROM `json/nested.json`;
> {code}
> Drill 1.14 results (correct):
> {noformat}
> +------------+
> | name_type |
> +------------+
> | MAP |
> +------------+
> {noformat}
> Drill 1.17 results (incorrect):
> {noformat}
> +-----------+
> | name_type |
> +-----------+
> | STRUCT |
> +-----------+
> {noformat}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)