hive-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Aihua Xu (JIRA)" <>
Subject [jira] [Commented] (HIVE-16875) Query against view with partitioned child on HoS fails with privilege exception.
Date Tue, 20 Jun 2017 20:27:02 GMT


Aihua Xu commented on HIVE-16875:

I see. We are expecting an alias_id here rather than an alias. 

nit: maybe we can change alias to alias_id and the same in the function {{setupMapWork(MapWork
mapWork, GenSparkProcContext context, PrunedPartitionList partitions, TableScanOperator root,
String alias)}} to be clear.

Otherwise, the change looks good to me. +1. 

> Query against view with partitioned child on HoS fails with privilege exception.
> --------------------------------------------------------------------------------
>                 Key: HIVE-16875
>                 URL:
>             Project: Hive
>          Issue Type: Bug
>          Components: Spark
>    Affects Versions: 1.0.0
>            Reporter: Yongzhi Chen
>            Assignee: Yongzhi Chen
>         Attachments: HIVE-16875.1.patch, HIVE-16875.2.patch
> Query against view with child table that has partitions fails with privilege exception
even with correct privileges.
> Reproduce:
> {noformat}
> create table jsamp1 (a string) partitioned by (b int);
> insert into table jsamp1 partition (b=1) values ("hello");
> create view jview as select * from jsamp1;
> create role viewtester;
> grant all on table jview to role viewtester;
> grant role viewtester to group testers;
> Use MR, the select will succeed:
> set hive.execution.engine=mr;
> select count(*) from jview;
> while use spark:
> set hive.execution.engine=spark;
> select count(*) from jview;
> it fails with:
> Error: Error while compiling statement: FAILED: SemanticException No valid privileges
>  User tester does not have privileges for QUERY
>  The required privileges: Server=server1->Db=default->Table=j1part->action=select;
> {noformat}

This message was sent by Atlassian JIRA

View raw message