[ https://issues.apache.org/jira/browse/HIVE-6796?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13955792#comment-13955792 ]
Thejas M Nair commented on HIVE-6796: ------------------------------------- >From [~deepesh] Steps to reproduce: # Login as admin user (eg hrt_qa) and create a new role. {noformat} 0: jdbc:hive2://hor8n19.gq1.ygridcore.net:100> set role ADMIN; No rows affected (0.048 seconds) 0: jdbc:hive2://:10> create role TESTROLE; No rows affected (0.081 seconds) 0: jdbc:hive2://:10> grant role TESTROLE to user hrt_1; No rows affected (0.086 seconds) 0: jdbc:hive2://:10> show roles; +-----------+ | role | +-----------+ | ADMIN | | PUBLIC | | TESTROLE | | | +-----------+ 4 rows selected (0.05 seconds) {noformat} # Login as public user hrt_1 and assume above role. {noformat} beeline> !connect jdbc:hive2://:10000 hrt_1 pwd Connected to: Apache Hive (version 0.13.0.2.1.1.0-261) Driver: Hive JDBC (version 0.13.0.2.1.1.0-261) Transaction isolation: TRANSACTION_REPEATABLE_READ 0: jdbc:hive2://:10> show current roles; +-----------+ | role | +-----------+ | PUBLIC | | TESTROLE | | | +-----------+ 3 rows selected (0.096 seconds) 0: jdbc:hive2://:10> set role testrole; No rows affected (0.025 seconds) 0: jdbc:hive2://:10> show current roles; +-----------+ | role | +-----------+ | TESTROLE | | | +-----------+ 2 rows selected (0.019 seconds) {noformat} This seems convenient as to not worry about case-sensitivity. # But here is the problem. Try to create role "testrole" (earlier we created TESTROLE). On admin session (hrt_qa): {noformat} 0: jdbc:hive2://:10> create role testrole; No rows affected (0.15 seconds) 0: jdbc:hive2://:10> show roles; +-----------+ | role | +-----------+ | ADMIN | | PUBLIC | | TESTROLE | | testrole | | | +-----------+ 5 rows selected (0.026 seconds) 0: jdbc:hive2://:10> drop role TESTROLE; No rows affected (0.094 seconds) 0: jdbc:hive2://:10> show roles; +-----------+ | role | +-----------+ | ADMIN | | PUBLIC | | testrole | | | +-----------+ 4 rows selected (0.026 seconds) {noformat} Above shows that create/drop role is case sensitive but "set role" is not. They should be all consistent (either they all are case sensitive or they are all case insensitive). > Create/drop roles is case-sensitive whereas 'set role' is case insensitive > -------------------------------------------------------------------------- > > Key: HIVE-6796 > URL: https://issues.apache.org/jira/browse/HIVE-6796 > Project: Hive > Issue Type: Bug > Reporter: Deepesh Khandelwal > Assignee: Thejas M Nair > > Create/drop role operations should be case insensitive. -- This message was sent by Atlassian JIRA (v6.2#6252)