drill-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chun Chang (JIRA)" <j...@apache.org>
Subject [jira] [Created] (DRILL-2425) Wrong results when identifier change cases within the same data file
Date Wed, 11 Mar 2015 01:21:38 GMT
Chun Chang created DRILL-2425:
---------------------------------

             Summary: Wrong results when identifier change cases within the same data file
                 Key: DRILL-2425
                 URL: https://issues.apache.org/jira/browse/DRILL-2425
             Project: Apache Drill
          Issue Type: Bug
          Components: Execution - Data Types
    Affects Versions: 0.8.0
            Reporter: Chun Chang
            Assignee: Daniel Barclay (Drill)
            Priority: Critical


#Fri Mar 06 16:51:10 EST 2015
git.commit.id.abbrev=fb293ba

I have the following JSON file that one of the identifier change cases:

{code}
[root@qa-node120 md-83]# hadoop fs -cat /drill/testdata/complex_type/json/schema/a.json
{"SOURCE": "ebm","msAddressIpv6Array": null}
{"SOURCE": "ebm","msAddressIpv6Array": {"msAddressIpv6_1":"99.111.222.0", "msAddressIpv6_2":"88.222.333.0"}}
{"SOURCE": "ebm","msAddressIpv6Array": {"msAddressIpv6_1":"99.111.222.1", "msAddressIpv6_2":"88.222.333.1"}}
{"SOURCE": "ebm","msAddressIpv6Array": {"msaddressipv6_1":"99.111.222.2", "msAddressIpv6_2":"88.222.333.2"}}
{code}

Query this file through drill gives wrong results:

{code}
0: jdbc:drill:schema=dfs.drillTestDirComplexJ> select t.msAddressIpv6Array.msAddressIpv6_1
as msAddressIpv6_1 from `schema/a.json` t;
+-----------------+
| msAddressIpv6_1 |
+-----------------+
| null            |
| null            |
| null            |
| 99.111.222.2    |
+-----------------+
{code}

plan:
{code}
0: jdbc:drill:schema=dfs.drillTestDirComplexJ> explain plan for select t.msAddressIpv6Array.msAddressIpv6_1
as msAddressIpv6_1 from `schema/a.json` t;
+------------+------------+
|    text    |    json    |
+------------+------------+
| 00-00    Screen
00-01      Project(msAddressIpv6_1=[ITEM($0, 'msAddressIpv6_1')])
00-02        Scan(groupscan=[EasyGroupScan [selectionRoot=/drill/testdata/complex_type/json/schema/a.json,
numFiles=1, columns=[`msAddressIpv6Array`.`msAddressIpv6_1`], files=[maprfs:/drill/testdata/complex_type/json/schema/a.json]]])
{code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message