Created
May 20, 2015 01:17
-
-
Save StuHorsman-zz/0cbc4d49ff6f6ab22306 to your computer and use it in GitHub Desktop.
Extract column names from Hive table
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| hive -S -e 'SET hive.cli.print.header=true; SELECT * FROM default.some_table LIMIT 0;' | sed -e 's/\t/,/g' > headers.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment