[jira] [Updated] (HIVE-16875) Query against view with partitioned child on HoS fails with privilege exception.

2017-06-22 Thread Yongzhi Chen (JIRA)

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

Yongzhi Chen updated HIVE-16875:

   Resolution: Fixed
Fix Version/s: 2.4.0
   3.0.0
   Status: Resolved  (was: Patch Available)

Committed the fix to master and branch-2. Thanks [~aihuaxu] for reviewing the 
code.

> Query against view with partitioned child on HoS fails with privilege 
> exception.
> 
>
> Key: HIVE-16875
> URL: https://issues.apache.org/jira/browse/HIVE-16875
> Project: Hive
>  Issue Type: Bug
>  Components: Spark
>Affects Versions: 1.0.0
>Reporter: Yongzhi Chen
>Assignee: Yongzhi Chen
> Fix For: 3.0.0, 2.4.0
>
> Attachments: HIVE-16875.1.patch, HIVE-16875.2.patch, 
> HIVE-16875.3.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; 
> (state=42000,code=4)
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Updated] (HIVE-16875) Query against view with partitioned child on HoS fails with privilege exception.

2017-06-20 Thread Yongzhi Chen (JIRA)

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

Yongzhi Chen updated HIVE-16875:

Attachment: HIVE-16875.3.patch

Attach patch 3 with changing alias to alias_id.

> Query against view with partitioned child on HoS fails with privilege 
> exception.
> 
>
> Key: HIVE-16875
> URL: https://issues.apache.org/jira/browse/HIVE-16875
> 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, 
> HIVE-16875.3.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; 
> (state=42000,code=4)
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Updated] (HIVE-16875) Query against view with partitioned child on HoS fails with privilege exception.

2017-06-19 Thread Yongzhi Chen (JIRA)

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

Yongzhi Chen updated HIVE-16875:

Attachment: HIVE-16875.2.patch

Second patch to fix the test results for spark, and add new test to spark unit 
test

> Query against view with partitioned child on HoS fails with privilege 
> exception.
> 
>
> Key: HIVE-16875
> URL: https://issues.apache.org/jira/browse/HIVE-16875
> 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; 
> (state=42000,code=4)
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Updated] (HIVE-16875) Query against view with partitioned child on HoS fails with privilege exception.

2017-06-12 Thread Yongzhi Chen (JIRA)

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

Yongzhi Chen updated HIVE-16875:

Attachment: HIVE-16875.1.patch

> Query against view with partitioned child on HoS fails with privilege 
> exception.
> 
>
> Key: HIVE-16875
> URL: https://issues.apache.org/jira/browse/HIVE-16875
> Project: Hive
>  Issue Type: Bug
>  Components: Spark
>Affects Versions: 1.0.0
>Reporter: Yongzhi Chen
>Assignee: Yongzhi Chen
> Attachments: HIVE-16875.1.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; 
> (state=42000,code=4)
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Updated] (HIVE-16875) Query against view with partitioned child on HoS fails with privilege exception.

2017-06-12 Thread Yongzhi Chen (JIRA)

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

Yongzhi Chen updated HIVE-16875:

Status: Patch Available  (was: Open)

> Query against view with partitioned child on HoS fails with privilege 
> exception.
> 
>
> Key: HIVE-16875
> URL: https://issues.apache.org/jira/browse/HIVE-16875
> Project: Hive
>  Issue Type: Bug
>  Components: Spark
>Affects Versions: 1.0.0
>Reporter: Yongzhi Chen
>Assignee: Yongzhi Chen
> Attachments: HIVE-16875.1.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; 
> (state=42000,code=4)
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)