drill-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rahul Challapalli (JIRA)" <j...@apache.org>
Subject [jira] [Closed] (DRILL-1642) flatten function is dropping the last record when the json file contains even no of records
Date Thu, 07 May 2015 01:07:00 GMT

     [ https://issues.apache.org/jira/browse/DRILL-1642?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Rahul Challapalli closed DRILL-1642.
------------------------------------

Verified and added the below testcase

Functional/Passing/json_kvgenflatten/flatten/flattenbug_DRILL-1642.q

> flatten function is dropping the last record when the json file contains even no of records
> -------------------------------------------------------------------------------------------
>
>                 Key: DRILL-1642
>                 URL: https://issues.apache.org/jira/browse/DRILL-1642
>             Project: Apache Drill
>          Issue Type: Bug
>          Components: Storage - JSON
>            Reporter: Rahul Challapalli
>            Assignee: Jason Altekruse
>             Fix For: 0.7.0
>
>         Attachments: flatten.json
>
>
> git.commit.id.abbrev=5adadfa
> The below query does not produce the right output. It is missing the last record from
the data file. The record count is even for the data set. However if it is odd, the flatten
operator has not issues .
> {code}
> 0: jdbc:drill:schema=dfs> select rownum, flatten(complex) from `flatten.json`;
> +------------+------------+
> |   rownum   |   EXPR$1   |
> +------------+------------+
> | 1          | {"col1":3} |
> | 1          | {"col2":2,"col3":1} |
> | 1          | {"col1":7} |
> | 2          | {"col2":2,"col3":1} |
> | 2          | {"col1":7} |
> | 3          | {"col1":2,"col3":1} |
> +------------+------------+
> {code} 
> Attached the data file. Let me know if you need anything more.



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

Mime
View raw message