hive-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pengcheng Xiong (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HIVE-10698) query on view results fails with table not found error if view is created with subquery alias (CTE).
Date Fri, 15 May 2015 16:55:00 GMT

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

Pengcheng Xiong commented on HIVE-10698:
----------------------------------------

[~jpullokkaran], the failed tests are unrelated. It seems that the patch passes all the CTE
tests in cte_1.q, cte_2.q, cbo_views.q and also two negative tests. Could you recommend some
more tests? Thanks.

> query on view results fails with table not found error if view is created with subquery
alias (CTE).
> ----------------------------------------------------------------------------------------------------
>
>                 Key: HIVE-10698
>                 URL: https://issues.apache.org/jira/browse/HIVE-10698
>             Project: Hive
>          Issue Type: Bug
>            Reporter: Pengcheng Xiong
>            Assignee: Pengcheng Xiong
>         Attachments: HIVE-10698.01.patch
>
>
> To reproduce it, 
> {code}
> use bugtest;
> create table basetb(id int, name string);
> create view testv1 as
> with subtb as (select id, name from bugtest.basetb)
> select id from subtb;
> use castest;
> explain select * from bugtest.testv1;
> hive> explain select * from bugtest.testv1;
> FAILED: SemanticException Line 2:15 Table not found 'subtb' in definition of VIEW testv1
[
> with subtb as (select id, name from bugtest.basetb)
> select id from `bugtest`.`subtb`
> ] used as testv1 at Line 1:22
> Note that there is a database prefix `bugtest`.`subtb`
> {code}



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

Mime
View raw message