You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "Rahul Challapalli (JIRA)" <ji...@apache.org> on 2015/04/22 01:24:01 UTC

[jira] [Closed] (DRILL-2099) Order by has issues with repeated map within a repeated map

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

Rahul Challapalli closed DRILL-2099.
------------------------------------

Verified and added the below testcase :

Functional/Passing/flatten_operators/2rows/orderby10_DRILL-2099.q

> Order by has issues with repeated map within a repeated map
> -----------------------------------------------------------
>
>                 Key: DRILL-2099
>                 URL: https://issues.apache.org/jira/browse/DRILL-2099
>             Project: Apache Drill
>          Issue Type: Bug
>          Components: Execution - Data Types, Execution - Relational Operators
>            Reporter: Rahul Challapalli
>            Assignee: Mehant Baid
>            Priority: Critical
>             Fix For: 0.9.0
>
>         Attachments: DRILL-2099.patch, error.log
>
>
> git.commit.id.abbrev=3e33880
> Data Set :
> {code}
> {
>   "uid" : 1,
>   "map":{"rm": [
>     {"rptd": [{ "a": "foo"},{"b":"boo"}]},
>     {"rptd": [{ "a": "bar"},{"c":1},{"d":4.5}]}
>   ]}
> }
> {code}
> Query : The below query fails
> {code}
> select flatten(s1.rms.rptd) rptds from (select d.uid uid, flatten(d.map.rm) rms from `temp3.json` d order by d.uid) s1 ;
> Query failed: RemoteRpcException: Failure while running fragment., index: -4, length: 4 (expected: range(0, 16384)) [ da0cb480-2fb8-4ea1-8d9a-ae7fc953c11d on qa-node190.qa.lab:31010 ]
> [ da0cb480-2fb8-4ea1-8d9a-ae7fc953c11d on qa-node190.qa.lab:31010 ]
> Error: exception while executing query: Failure while executing query. (state=,code=0)
> {code}
> The below 2 queries work as expected :
> 1. Use filter instead of order by
> {code}
> select flatten(s1.rms.rptd) rptds from (select d.uid uid, flatten(d.map.rm) rms from `temp3.json` d where d.uid=1) s1 ;
> {code}
> 2. Remove the top level flatten
> {code}
> select s1.uid from (select d.uid uid, flatten(d.map.rm) rms from `temp3.json` d order by d.uid) s1 ;
> {code}



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