I have created drivers, driver 1 tables when trying to create temp tables, etc. and now there is a list of it and want to clean it
do you mean you have created tables called "drivers, driver1 etc" and now you want to get rid of tables and their associated data? Are the folders created under "/usr/hive/warehouse" directory? Have you used the following?
DROP TABLE [IF EXISTS] table_name [PURGE]; --> DROP TABLE IF EXISTS drivers PURGE;
Then run it again for other tables.
If your table is not a hive managed table (data under hive warehouse directory) or in other words when you create an external table, then dropping a table does not delete data. Data is deleted on drop table only for Hive Managed tables.
I completely understand the concept of external table . But what i was looking for is, What are the reasons when a 'Managed Hive table' is dropped but the data underneath hive warehouse directory still exists.
You mean do you want to delete the folders on which the hive table is created?
If its a managed table then dropping the hive table will delete the folders underneath the warehouse.
But if it is a external table then you have to manual delete the folders/ files underneath.
Are these tables External Tables? In the case of external tables you would have manually clean the folders by removing the files and folders that are referenced by the table ( using hadoop fs -rm command)