aws-samples / aws-big-data-blog

Apache License 2.0
897 stars 628 forks source link

aws-big-data-blog/aws-blog-athena-importing-hive-metastores/ #102

Open NaveenK79 opened 6 years ago

NaveenK79 commented 6 years ago

There is a bug in the script exportdatabase.py, the line 25

command="hive -f "+schema+"_tables.hql -S >> "+schema+".output"

need to be replaced as below

command="hive --database "+schema+" -f "+schema+"_tables.hql -S >> "+schema+".output"

The schema name needs to be specified in case if we are exporting from a schema other than default.