Commit 16469151 164691514f5db35e2b18af34e87089f83eb1b277 by 张浩

commit

1 parent da9593dc
1 use testdb; 1 use testdb;
2 2
3 INSERT OVERWRITE TABLE biz_data_count 3 INSERT INTO TABLE biz_data_count
4 select method,biz_data,count(1) as count,max(timestamp) as timestamp 4 select method,biz_data,count(1) as count,max(timestamp) as timestamp
5 from qa_log 5 from qa_log
6 where method is not null and method!='N/A' and method='${hivevar:mytemp}' 6 where method is not null and method!='N/A' and method='${hivevar:mytemp}'
......
1 use testdb; 1 use testdb;
2 2
3 INSERT OVERWRITE TABLE biz_data_response 3 INSERT INTO TABLE biz_data_response
4 select method,biz_data,uid,timestamp,response 4 select method,biz_data,uid,timestamp,response
5 from qa_log 5 from qa_log
6 where method is not null and method!='N/A' and method='${hivevar:mytemp}'; 6 where method is not null and method!='N/A' and method='${hivevar:mytemp}';
...\ No newline at end of file ...\ No newline at end of file
......
1 use testdb; 1 use testdb;
2 2
3 truncate table biz_data_count;
4 truncate table biz_data_response;
5
3 LOAD DATA INPATH 'hdfs://localhost:8020/input/etl' OVERWRITE INTO TABLE qa_log; 6 LOAD DATA INPATH 'hdfs://localhost:8020/input/etl' OVERWRITE INTO TABLE qa_log;
...\ No newline at end of file ...\ No newline at end of file
......