首页 > 其他 > 详细

hive 建表导入数据

时间:2017-09-14 12:52:30      阅读:263      评论:0      收藏:0      [点我收藏+]

1、

  1. hive> create table wyp
  2.     > (id int, name string,
  3.     > age int, tel string)
  4.     > ROW FORMAT DELIMITED
  5.     > FIELDS TERMINATED BY ‘\t‘
  6.     > STORED AS TEXTFILE;

 

2、

  1. cat wyp.txt
  2. 1       wyp     25      13188888888888
  3. 2       test    30      13888888888888
  4. 3       zs      34      899314121

3、

load data local inpath ‘wyp.txt‘ into table wyp;

hive 建表导入数据

原文:http://www.cnblogs.com/CaptainLin/p/7519787.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!