hive命令行

来源:互联网 发布:淘宝关于退货运费规则 编辑:程序博客网 时间:2024/05/18 02:14

1.hive执行sql并保存结果到本地

hive -S -e "select  *  from table_name "  >> /tmp/comandinfo.txt

2.产看hive的某个属性

hive -s -e "set" | grep  (查找关键字)

3.执行hive文件

hive -f   /path/myhive.sql

4.hive中执行shell指令

hive> ! pwd

5.hive中执行HDFS命令

hive>  dfs -ls  /   

0 0
原创粉丝点击