You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "Robert Hou (JIRA)" <ji...@apache.org> on 2016/09/08 01:23:20 UTC
[jira] [Created] (DRILL-4883) Drill Explorer returns "SYSTEM ERROR:
UnsupportedOperationException: Unhandled field reference ; a field
reference identifier must not have the form of a qualified name (i.e., with
".").
Robert Hou created DRILL-4883:
---------------------------------
Summary: Drill Explorer returns "SYSTEM ERROR: UnsupportedOperationException: Unhandled field reference ; a field reference identifier must not have the form of a qualified name (i.e., with ".").
Key: DRILL-4883
URL: https://issues.apache.org/jira/browse/DRILL-4883
Project: Apache Drill
Issue Type: Bug
Components: Execution - Codegen
Affects Versions: 1.8.0
Environment: Drill Explorer runs in Windows
Reporter: Robert Hou
When Drill Explorer submits this query, it returns an error regarding favorites.color:
select age,`favorites.color` from `dfs`.`drillTestDir`.`./json_storage/employeeNestedArrayAndObject.json`
The error is:
ERROR [HY000] [MapR][Drill] (1040) Drill failed to execute the query: select age,`favorites.color` from `dfs`.`drillTestDir`.`./json_storage/employeeNestedArrayAndObject.json`
[30027]Query execution error. Details:[
SYSTEM ERROR: UnsupportedOperationException: Unhandled field reference "favorites.color"; a field reference identifier must not have the form of a qualified name (i.e., with ".").
This query can be executed by sqlline (note that the format of the query is slightly different for sqlline and Drill Explorer).
select age,`favorites.color` from `json_storage/employeeNestedArrayAndObject.json`;
The physical plan for the query when using sqlline is different from the physical plan when using Drill Explorer. Here is the plan when using sqlline:
00-00 Screen : rowType = RecordType(ANY age, ANY favorites.color): rowcount = 1.0, cumulative cost = {0.1 rows, 0.1 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 19699870
00-01 Project(age=[$0], favorites.color=[$1]) : rowType = RecordType(ANY age, ANY favorites.color): rowcount = 1.0, cumulative cost = {0.0 rows, 0.0 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 19699869
00-02 Scan(groupscan=[EasyGroupScan [selectionRoot=maprfs:/drill/testdata/json_storage/employeeNestedArrayAndObject.json, numFiles=1, columns=[`age`, `favorites.color`], files=[maprfs:///drill/testdata/json_storage/employeeNestedArrayAndObject.json]]]) : rowType = RecordType(ANY age, ANY favorites.color): rowcount = 1.0, cumulative cost = {0.0 rows, 0.0 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 19699868
The physical plan when using Drill Explorer is:
00-00 Screen : rowType = RecordType(ANY age, ANY favorites.color): rowcount = 1.0, cumulative cost = {1.1 rows, 1.1 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 19675621
00-01 ComplexToJson : rowType = RecordType(ANY age, ANY favorites.color): rowcount = 1.0, cumulative cost = {1.0 rows, 1.0 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 19675620
00-02 Project(age=[$0], favorites.color=[$1]) : rowType = RecordType(ANY age, ANY favorites.color): rowcount = 1.0, cumulative cost = {0.0 rows, 0.0 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 19675619
00-03 Scan(groupscan=[EasyGroupScan [selectionRoot=maprfs:/drill/testdata/json_storage/employeeNestedArrayAndObject.json, numFiles=1, columns=[`age`, `favorites.color`], files=[maprfs:///drill/testdata/json_storage/employeeNestedArrayAndObject.json]]]) : rowType = RecordType(ANY age, ANY favorites.color): rowcount = 1.0, cumulative cost = {0.0 rows, 0.0 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 19675618
Drill Explorer has an extra ComplexToJson operator that may have a problem.
Here is the data file used:
{
"first": "John",
"last": "Doe",
"age": 39,
"sex": "M",
"salary": 70000,
"registered": true,
"interests": [ "Reading", "Mountain Biking", "Hacking" ],
"favorites": {
"color": "Blue",
"sport": "Soccer",
"food": "Spaghetti"
}
}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)