--创建表语句
create table luce(
gridid varchar(20),
height varchar(20),
gridx varchar(20),
gridy varchar(20),
ltescrsrp varchar(20),
objectid varchar(20),
calibrategridid varchar(20),
imsicount varchar(20),
mrcount varchar(20),
weakcoverage varchar(20),
p_hour varchar(20),
p_city varchar(20),
p_loctype varchar(20),
Longitude varchar(20),
Latitude varchar(20)
)
row format delimited fields terminated by ','
stored as textfile
插入分区表
INSERT OVERWRITE TABLE 分区表 partition(p_hour='2018030212',p_city='571',p_loctype='LC')
select gridid,0,gridx,gridy,objectid,ltescrsrp,calibrategridid,imsicount,mrcount from luce_calibrategid;