By using the below commands, we can access subdirectories recursively in Hive:
hive> Set mapred.input.dir.recursive=true;
hive> Set hive.mapred.supports.subdirectories=true;
Hive tables can be pointed to the higher level directory, and this is suitable for the directory structure:
/data/country/state/city/