You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sentry.apache.org by "Anne Yu (JIRA)" <ji...@apache.org> on 2015/05/28 01:04:18 UTC

[jira] [Created] (SENTRY-747) Create a view by unioning tables, grant select then select from view encounter errors (1.5.0 only)

Anne Yu created SENTRY-747:
------------------------------

             Summary: Create a view by unioning tables, grant select then select from view encounter errors (1.5.0 only)
                 Key: SENTRY-747
                 URL: https://issues.apache.org/jira/browse/SENTRY-747
             Project: Sentry
          Issue Type: Bug
    Affects Versions: 1.5.0
            Reporter: Anne Yu
             Fix For: 1.5.0


cc [~sravya]. This issue shows after column level privilege.

{code}
CREATE TABLE test_complex_view_table (userid VARCHAR(64), link STRING, source STRING) PARTITIONED BY (datestamp STRING) CLUSTERED BY (userid) INTO 256 BUCKETS STORED AS ORC;

CREATE TABLE test_complex_view_table_2 (userid VARCHAR(64), name VARCHAR(64), age INT, gpa DECIMAL(3, 2)) CLUSTERED BY (age) INTO 2 BUCKETS STORED AS ORC;

CREATE TABLE test_user_info (userid VARCHAR(64), name STRING, address STRING, tel STRING);

CREATE VIEW test_complex_view AS SELECT u.userid, u.name, u.address, res.uid FROM (SELECT t1.userid AS uid FROM test_complex_view_table t1 UNION ALL SELECT t2.userid AS uid FROM test_complex_view_table_2 t2 ) res JOIN test_user_info u ON (u.userid = res.uid);

Required privileges for this query: Server=server1->Db=test_complex_view_database->Table=test_complex_view_table->Column=userid->action=select;
{code}



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