hive UDF
来源:互联网 发布:人工智能机器人在哪做 编辑:程序博客网 时间:2024/05/17 15:19
use mwd;--prepare data, c_ip 为左补足0转换后值-- ETL: spv datacreate temporary function row_sequence as 'com.mwd.hive.udf.RowSequence';create temporary function parse_agent as 'com.mwd.hive.udf.HdfsRegexParseUdf';create temporary function uri_to_map as 'com.mwd.hive.udf.GenericUDFUriToMap';insert into table wdlog_ready_spv PARTITION (import_time='20131111') select row_sequence(), cur_date, concat_ws(' ', cur_date, cur_time), cs_uri_query, printf('%s%s%s%s', lpad(split(c_ip,'\\\.')[0],3,'0'), lpad(split(c_ip,'\\\.')[1],3,'0'), lpad(split(c_ip,'\\\.')[2],3,'0'), lpad(split(c_ip,'\\\.')[3],3,'0')), agent, if(instr(cs_uri_query, '&\\;') > 0, uri_to_map(cs_uri_query,'&\\;', '=','/user/searchdata','/user/mediadata'), uri_to_map(cs_uri_query, '&', '=','/user/searchdata','/user/mediadata')), parse_agent(agent,'/user/reg_data') from wdlog where import_time='20131111' and cs_uri_query is not null;drop temporary function parse_agent;drop temporary function uri_to_map;drop temporary function row_sequence;
0 0
- hive udf
- hive-udf
- hive UDF
- hive UDF
- hive UDF
- hive udf
- hive udf
- Hive UDF
- HIVE UDF
- hive udf
- hive UDF
- 开发hive UDF函数
- Hive UDF 开发
- HIVE UDF整理
- hive UDF开发注意事项
- hive开发UDF随记
- HIVE 自定义函数 UDF
- HIVE UDF函数(一)
- spring配置hibernate需要的包
- BlockingQueue详解
- Q8.4
- Viewport在开发手机Web中的应用
- XMPP协议TLS、SASL、资源绑定和服务器回调详细流程
- hive UDF
- 基于Spring框架的Shiro配置
- 数据库建表的各徙关系-- 一对多/多对一/一对一/多对多 关系分析
- AsyncTask
- java实现单例模式
- 重新Adapter 用listView实现Ios tabview效果
- leetcode: Trapping Rain Water
- 2014年开源PHP框架排行
- Java的反射机制