create table ori_trans (account string, maker string, tdate string) partitioned by (country string);

hive  -f test1.hql --hiveconf country='china'

hive  -f test2.hql --hiveconf country='china' --define account=account2 --define maker=yaoxiaohua

hive  -f test2.hql --hiveconf country='japan' --define account=account3 --define maker=yaoyuanyie

 insert overwrite table ori_trans partition(country='${hiveconf:country}')
select
'${account}' as account, '${maker}' as maker, '2012-03-03'
from nums limit 20; hive -f test3.hql --define table_pre=china --define account=account3 --define maker=yaoyuanyie drop table ${table_pre}_ori_trans;
create table ${table_pre}_ori_trans as
select
'${account}' as account, '${maker}' as maker, '2012-03-03'
from nums limit 20; issue1. hive query ‘s job 提交到yarn集群,但是状态一直是accepted,不能进入running.
解决方案:重启DFS服务。
issue2.hadoop yarn如何查看job执行情况?
http://jobtrackerip:8088/
http://jobtrackerip:50070
 

Hive variable demo的更多相关文章

  1. Spark SQL Hive Support Demo

    前提: 1.spark1.0的包编译时指定支持hive:./make-distribution.sh --hadoop 2.3.0-cdh5.0.0 --with-yarn --with-hive - ...

  2. oozie调度hive脚本demo

    1. 环境配置 2. 脚本配置 3. 执行job 4. 查看结果 待发布 ..

  3. 【转】Hive配置文件中配置项的含义详解(收藏版)

    http://www.aboutyun.com/thread-7548-1-1.html 这里面列出了hive几乎所有的配置项,下面问题只是说出了几种配置项目的作用.更多内容,可以查看内容问题导读:1 ...

  4. oozie 运行demo

    昨晚装好了oozie,能启动了,并且配置了mysql作为数据库,好了,今天要执行oozie自带的demo了,好家伙,一执行就报错!报错很多,就不一一列举了,就说我最后解决的方法吧. oozie job ...

  5. Hive配置文件中配置项的含义详解(收藏版)

    这里面列出了hive几乎所有的配置项,下面问题只是说出了几种配置项目的作用.更多内容,可以查看内容 问题导读: 1.hive输出格式的配置项是哪个? 2.hive被各种语言调用如何配置? 3.hive ...

  6. hive 上篇

    hive 是以hadoop为基础的数据仓库,使用HQL查询存放在HDFS上面的数据,HSQL是一种类SQL的语句,最终会被编译成map/reduce,HSQL可以查询HDFS上面的数据:不支持记录级别 ...

  7. Hive分区表创建,增加及删除

    1.创建Hive分区表,按字段分区 CREATE TABLE test1 ( id bigint , create_time timestamp , user_id string) partition ...

  8. hive配置参数的说明:

    hive.ddl.output.format:hive的ddl语句的输出格式,默认是text,纯文本,还有json格式,这个是0.90以后才出的新配置: hive.exec.script.wrappe ...

  9. hive 学习系列二(数据库的创建删除修改) 拿走,不谢。

    database 相当于一个目录或者命名空间,用来更好地进行表的管理 在hdfs 的目录位置大致如下: [root@iZbp12vtv76y9q3d633bh6Z /]# hadoop fs -ls ...

随机推荐

  1. 大话设计模式-->模板方法设计模式

    在学习java的过程中,我们肯定听到过设计模式这名词,在行业中有这么一句话,若您能熟练的掌握23种设计模式,那么你便是大牛! 好了,废话不多说,今天我跟大家分享一下23种设计模式之一的  模板方法 设 ...

  2. linux下基本命令总结

    基本linux命令的使用方法及实例,总结一些常用的命令:  一.创建文件和目录命令:mkdir touch(vim用得较多) 1)mdkir创建一个目录,创建多目录格式 mkdir –p a/{a,b ...

  3. php中的常用数组函数(三)(获取数组交集的函数们 array_intersect()、array_intersect_key()、array_intersect_assoc()、array_intersect_uassoc()、array_intersect_ukey())

    这5个获取交集的函数 有 5个对应的获取差集的函数.我是链接. array_intersect($arr1, $arr2); //获得数组同键值的交集 array_intersect_key($arr ...

  4. Win764位配置Github环境及将代码部署到Github pages-志银强势总结

    (软件及教程下载分享:链接:http://pan.baidu.com/s/1dFysay9 密码:pug0) 1-安装Git-2.9.2-64-bit.exe(解压安装文件,运行安装程序,除了记得修改 ...

  5. Socket 学习实例

    整理一份Socket代码,整理前辈的代码 http://www.cnblogs.com/yellowapplemylove/archive/2011/04/19/2021586.html 直接贴代码 ...

  6. ArcGIS中定义图框样式

    ArcGIS系统中的样式可能不能满足实际生产需要,为了实现快速制图,可自定义一些样式,以便重复利用. 安装字符 因为样式中定义了自定义的符号,这些符号都打包到字体中,所以在使用样式之前,必须安装字体文 ...

  7. English Training Material - 03

    Cross-cultural understanding (2) 1 The following text is about cultural diversity. Read it through o ...

  8. android XMl 解析神奇xstream 四: 将复杂的xml文件解析为对象

    前言:对xstream不理解的请看: android XMl 解析神奇xstream 一: 解析android项目中 asset 文件夹 下的 aa.xml 文件 android XMl 解析神奇xs ...

  9. Objective-C中@encode的使用

    今天看Mansonry的代码时,碰到一个生僻的关键字(也许只是自己没用过).:-) @encode  => 将给定类型编码为内部表示的字符串. 为了方便自己查阅,顺便也写个小例子,贴在这里,实践 ...

  10. Cocos2d入门--3--向量的应用

    *:first-child { margin-top: 0 !important; } body > *:last-child { margin-bottom: 0 !important; } ...