create table sales(id int, fname string, state string, zip string, ip string, pid string) Row format delimited fields terminated by '\t';
CREATE INDEX index_ip ON TABLE sales(ip) AS 'org.apache.hadoop.hive.ql.index.compact.CompactIndexHandler' WITH DEFERRED REBUILD;
create index ix_test01 on table test01 (col1) as 'COMPACT'
show index on test01
drop index ix_test01 on test01
create index ix_test02 on table test02 (col2) as 'compact' with deferred rebuild;
alter index ix_test02 on table rebuild
show formatted index on test02
create index ix_test03 on table test03 (col3) as 'bitmap' with deferred rebuild
create index ix_test04 on table test04 (col3) as 'compact' stored as rcfile;
create index ix_test05 on table test05 (col3) as 'compact' row format delimited fields
terminated by '\t' stored as textfile
alter index ix_test06 on test06 partition ( column='col1' ) rebuild
'NoSQL > Hive' 카테고리의 다른 글
hive에서 RDB와 CRUD (0) | 2017.02.25 |
---|---|
impala가 지원하지 않는 기능 (0) | 2017.02.25 |
hive table 통계 정보 수집 (0) | 2017.02.19 |
hive load data (0) | 2017.02.19 |
hive orc file format (0) | 2017.02.18 |