Skip to content

Instantly share code, notes, and snippets.

@ragingbal
Created June 19, 2020 15:25
Show Gist options
  • Save ragingbal/f07726ce951fa1a0119713028d5b97d8 to your computer and use it in GitHub Desktop.
Save ragingbal/f07726ce951fa1a0119713028d5b97d8 to your computer and use it in GitHub Desktop.
$hive -e 'show tables in <dbname>' | tee tables.txt
Then create a bash script (describe_tables.sh) to loop over each table in this list:
while read line
do
echo "$line"
eval "hive -e 'describe <dbname>.$line'"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment