在shell脚本中,hql使用 $hive -e "$sql"
这里将hive的mr替换为spark
前提条件,配置好spark on hive
将$hive 替换为$spark-sql就可以了
如果遇到小文件过多的问题,在sql中设置set spark.sql.shuffle.partitions=100;
https://blog.csdn.net/a_hui_tai_lang/article/details/81990045
在shell脚本中,hql使用 $hive -e "$sql"
这里将hive的mr替换为spark
前提条件,配置好spark on hive
将$hive 替换为$spark-sql就可以了
如果遇到小文件过多的问题,在sql中设置set spark.sql.shuffle.partitions=100;
https://blog.csdn.net/a_hui_tai_lang/article/details/81990045