1、数据描述:用户的历史微博数据,截止到20131215,
压缩后221MB,解压后878MB,整个数据有1206个小文件,所有数据的格式均是json格式。
2、数据样例:
[{"beCommentWeiboId":"","beForwardWeiboId":"","catchTime":"1387157643","commentCount":"682","content":"喂!2014。。。2014!喂。。。","createTime":"1387086483","info1":"","info2":"","info3":"","mlevel":"","musicurl":[],"pic_list":["http://ww1.sinaimg.cn/square/47119b17jw1ebkc9b07x9j218g0xcair.jpg","http://ww4.sinaimg.cn/square/47119b17jw1ebkc9ebakij218g0xc113.jpg","http://ww2.sinaimg.cn/square/47119b17jw1ebkc9hml7dj218g0xcgt6.jpg","http://ww3.sinaimg.cn/square/47119b17jw1ebkc9kyakyj218g0xcqb3.jpg"],"praiseCount":"1122","reportCount":"671","source":"iPhone客户端","userId":"1192336151","videourl":[],"weiboId":"3655768039404271","weiboUrl":"http://weibo.com/1192336151/AnoMrDstN"}]
2、字段描述
总共19个字段
beCommentWeiboId 是否评论 string
beForwardWeiboId 是否是转发微博 string
catchTime 抓取时间 string
commentCount 评论次数 int
content 内容 string
createTime 创建时间 string
info1 信息字段1 string
info2信息字段2 string
info3信息字段3 string
mlevel no sure string
musicurl 音乐链接 string
pic_list 照片列表(可以有多个) string
praiseCount 点赞人数 int
reportCount 转发人数 int
source 数据来源 string
userId 用户id string
videourl 视频链接 string
weiboId 微博id string
weiboUrl 微博网址 string
3、功能需求
建表的时候 建外部表
数据的存储目录: hdfs://hadoop01:9000/data/weibo
1、数据处理:针对数据问题,请给出对应的解决方案(15分)
数据文件过多:要合并,请给出解决方案
2、组织数据(10分)
(创建Hive表weibo_json(json string),表只有一个字段,导入所有数据,并验证查询前5条数据)
(解析完weibo_j