Support Questions
Find answers, ask questions, and share your expertise

Is it possible to DROP TABLE but not DROP DATABASE in Hive using Ranger Hive Plugin?

Explorer

- Is it possible to DROP TABLE but not DROP DATABASE in Hive using Ranger Hive Plugin on latest version of HDP?

3 REPLIES 3

Re: Is it possible to DROP TABLE but not DROP DATABASE in Hive using Ranger Hive Plugin?

New Contributor

DROP TABLE IF EXISTS tableName;

Re: Is it possible to DROP TABLE but not DROP DATABASE in Hive using Ranger Hive Plugin?

Explorer

@sulanta thanks but my requirement is little different. What I want is to restrict the user from dropping the database but that user should be able to drop the table. Is this possible?

Re: Is it possible to DROP TABLE but not DROP DATABASE in Hive using Ranger Hive Plugin?

New Contributor

The above command does not drop the database , it will only drop the specific table mentioned in the command.