You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "Aman Sinha (JIRA)" <ji...@apache.org> on 2015/05/15 19:56:01 UTC

[jira] [Commented] (DRILL-3101) Setting "slice_target" to 1 changes the order of the columns in a "select *" query with order by

    [ https://issues.apache.org/jira/browse/DRILL-3101?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14545877#comment-14545877 ] 

Aman Sinha commented on DRILL-3101:
-----------------------------------

This is a duplicate of DRILL-1499 and is documented behavior.  

> Setting "slice_target" to 1 changes the order of the columns in a "select *" query with order by
> ------------------------------------------------------------------------------------------------
>
>                 Key: DRILL-3101
>                 URL: https://issues.apache.org/jira/browse/DRILL-3101
>             Project: Apache Drill
>          Issue Type: Bug
>          Components: Execution - Flow
>            Reporter: Rahul Challapalli
>            Assignee: Chris Westin
>
> git.commit.id.abbrev=d8b1975
> With Default Settings :
> {code}
> select * from region order by length(r_name);
> +-------------+--------+-----------+
> | r_regionkey | r_name | r_comment |
> +-------------+--------+-----------+
> | 2 | ASIA | ges. thinly even pinto beans ca |
> | 0 | AFRICA | lar deposits. blithely final packages cajole. regular waters are final requests. regular accounts are according to  |
> | 3 | EUROPE | ly final courts cajole furiously final excuse |
> | 1 | AMERICA | hs use ironic, even requests. s |
> | 4 | MIDDLE EAST | uickly special accounts cajole carefully blithely close requests. carefully final asymptotes haggle furiousl |
> {code}
> Now after setting the slice target to 1, the order of the columns changed
> {code}
> 0: jdbc:drill:schema=dfs_eea> alter session set `planner.slice_target` = 1;
> +-------+--------------------------------+
> |  ok   |            summary             |
> +-------+--------------------------------+
> | true  | planner.slice_target updated.  |
> +-------+--------------------------------+
> 1 row selected (0.11 seconds)
> 0: jdbc:drill:schema=dfs_eea> select * from region order by length(r_name);
> +-----------+--------+-------------+
> | r_comment | r_name | r_regionkey |
> +-----------+--------+-------------+
> | ges. thinly even pinto beans ca | ASIA | 2 |
> | lar deposits. blithely final packages cajole. regular waters are final requests. regular accounts are according to  | AFRICA | 0 |
> | ly final courts cajole furiously final excuse | EUROPE | 3 |
> | hs use ironic, even requests. s | AMERICA | 1 |
> | uickly special accounts cajole carefully blithely close requests. carefully final asymptotes haggle furiousl | MIDDLE EAST | 4 |
> +-----------+--------+-------------+
> 5 rows selected (0.796 seconds)
> {code}
> This does not happen when we do not use an "order by" in query



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