You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "Arina Ielchiieva (JIRA)" <ji...@apache.org> on 2018/09/06 13:04:00 UTC

[jira] [Closed] (DRILL-4912) Ability to use alias in join conditions

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

Arina Ielchiieva closed DRILL-4912.
-----------------------------------
    Resolution: Invalid

> Ability to use alias in join conditions
> ---------------------------------------
>
>                 Key: DRILL-4912
>                 URL: https://issues.apache.org/jira/browse/DRILL-4912
>             Project: Apache Drill
>          Issue Type: Improvement
>          Components: Execution - Flow, SQL Parser
>    Affects Versions: 1.6.0, 1.8.0
>            Reporter: Kathiresan Selvaraj
>            Assignee: Arina Ielchiieva
>            Priority: Major
>              Labels: doc-impacting
>
> Json files used for testing:
> data.json
> { "name": "Jim","city" : [1,2]}
> cities.json
> {id:1,name:"Sendurai"}
> {id:2,name:"NYC"}
> Below query returns no result.
> select city\[0\] as cityalias from dfs.tmp.`data.json` a join (select id as idalias from dfs.tmp.`cities.json`) b on a.cityalias  = b.idalias 
> However, the query below works fine
> select city\[0\] as cityalias from dfs.tmp.`data.json` a join (select id as idalias from dfs.tmp.`cities.json`) b on a.city\[0\]  = b.idalias 
> Using an alias for city\[0\] in the join condition makes it return no result.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)