@@创建普通表
create table tab5 (key int, value string) row format delimited fields terminated by '\t';
@@创建分区表
create table partition_tab2(col1 string,col2 string)
partitioned by (province string) row format delimited fields terminated by ',';
@@增加具体分区
create table tab5 (key int, value string) row format delimited fields terminated by '\t';
@@创建分区表
create table partition_tab2(col1 string,col2 string)
partitioned by (province string) row format delimited fields terminated by ',';
@@增加具体分区
alter table partition_tab2 add partition (province='liaoning');
@@加载数据
LOAD DATA LOCAL INPATH '/home/hadoop/tab5Load.txt' INTO TABLE tab5;
LOAD DATA LOCAL INPATH 'hdfs://172.10.10.144:9000/tmp/tab1.txt' OVERWRITE INTO TABLE tab1;