drop index src_index_2 on src

drop index src_index_3 on src

drop index src_index_4 on src

drop index src_index_5 on src

drop index src_index_6 on src

drop index src_index_7 on src

drop index src_index_8 on src

drop index src_index_9 on src

drop table `_t`


create index src_index_2 on table src(key) as 'compact' WITH DEFERRED REBUILD

desc extended default__src_src_index_2__
key	string	
_bucketname	string	
_offsets	array<bigint>	
	 	 
Detailed Table Information	Table(tableName:default__src_src_index_2__, dbName:default, owner:null, createTime:1366741979, lastAccessTime:0, retention:0, sd:StorageDescriptor(cols:[FieldSchema(name:key, type:string, comment:null), FieldSchema(name:_bucketname, type:string, comment:), FieldSchema(name:_offsets, type:array<bigint>, comment:)], location:hdfs://mgrover-bigtop-centos-1.ent.cloudera.com:17020/user/hive/warehouse/default__src_src_index_2__, inputFormat:org.apache.hadoop.mapred.TextInputFormat, outputFormat:org.apache.hadoop.hive.ql.io.IgnoreKeyTextOutputFormat, compressed:false, numBuckets:-1, serdeInfo:SerDeInfo(name:null, serializationLib:org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe, parameters:{serialization.format=1}), bucketCols:[], sortCols:[Order(col:key, order:1)], parameters:{}, skewedInfo:SkewedInfo(skewedColNames:[], skewedColValues:[], skewedColValueLocationMaps:{}), storedAsSubDirectories:false), partitionKeys:[], parameters:{transient_lastDdlTime=1366741979}, viewOriginalText:null, viewExpandedText:null, tableType:INDEX_TABLE)	


create index src_index_3 on table src(key) as 'compact' WITH DEFERRED REBUILD in table src_idx_src_index_3

desc extended src_idx_src_index_3
key	string	
_bucketname	string	
_offsets	array<bigint>	
	 	 
Detailed Table Information	Table(tableName:src_idx_src_index_3, dbName:default, owner:null, createTime:1366741980, lastAccessTime:0, retention:0, sd:StorageDescriptor(cols:[FieldSchema(name:key, type:string, comment:null), FieldSchema(name:_bucketname, type:string, comment:), FieldSchema(name:_offsets, type:array<bigint>, comment:)], location:hdfs://mgrover-bigtop-centos-1.ent.cloudera.com:17020/user/hive/warehouse/src_idx_src_index_3, inputFormat:org.apache.hadoop.mapred.TextInputFormat, outputFormat:org.apache.hadoop.hive.ql.io.IgnoreKeyTextOutputFormat, compressed:false, numBuckets:-1, serdeInfo:SerDeInfo(name:null, serializationLib:org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe, parameters:{serialization.format=1}), bucketCols:[], sortCols:[Order(col:key, order:1)], parameters:{}, skewedInfo:SkewedInfo(skewedColNames:[], skewedColValues:[], skewedColValueLocationMaps:{}), storedAsSubDirectories:false), partitionKeys:[], parameters:{transient_lastDdlTime=1366741980}, viewOriginalText:null, viewExpandedText:null, tableType:INDEX_TABLE)	


create index src_index_4 on table src(key) as 'compact' WITH DEFERRED REBUILD ROW FORMAT DELIMITED FIELDS TERMINATED BY '\t' STORED AS TEXTFILE

desc extended default__src_src_index_4__
key	string	
_bucketname	string	
_offsets	array<bigint>	
	 	 
Detailed Table Information	Table(tableName:default__src_src_index_4__, dbName:default, owner:null, createTime:1366741981, lastAccessTime:0, retention:0, sd:StorageDescriptor(cols:[FieldSchema(name:key, type:string, comment:null), FieldSchema(name:_bucketname, type:string, comment:), FieldSchema(name:_offsets, type:array<bigint>, comment:)], location:hdfs://mgrover-bigtop-centos-1.ent.cloudera.com:17020/user/hive/warehouse/default__src_src_index_4__, inputFormat:org.apache.hadoop.mapred.TextInputFormat, outputFormat:org.apache.hadoop.hive.ql.io.IgnoreKeyTextOutputFormat, compressed:false, numBuckets:-1, serdeInfo:SerDeInfo(name:null, serializationLib:org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe, parameters:{serialization.format=	, field.delim=


create index src_index_5 on table src(key) as 'compact' WITH DEFERRED REBUILD ROW FORMAT DELIMITED FIELDS TERMINATED BY '\t' ESCAPED BY '\\'

desc extended default__src_src_index_5__
key	string	
_bucketname	string	
_offsets	array<bigint>	
	 	 
Detailed Table Information	Table(tableName:default__src_src_index_5__, dbName:default, owner:null, createTime:1366741982, lastAccessTime:0, retention:0, sd:StorageDescriptor(cols:[FieldSchema(name:key, type:string, comment:null), FieldSchema(name:_bucketname, type:string, comment:), FieldSchema(name:_offsets, type:array<bigint>, comment:)], location:hdfs://mgrover-bigtop-centos-1.ent.cloudera.com:17020/user/hive/warehouse/default__src_src_index_5__, inputFormat:org.apache.hadoop.mapred.TextInputFormat, outputFormat:org.apache.hadoop.hive.ql.io.IgnoreKeyTextOutputFormat, compressed:false, numBuckets:-1, serdeInfo:SerDeInfo(name:null, serializationLib:org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe, parameters:{escape.delim=\, serialization.format=	, field.delim=


create index src_index_6 on table src(key) as 'compact' WITH DEFERRED REBUILD STORED AS RCFILE

desc extended default__src_src_index_6__
key	string	
_bucketname	string	
_offsets	array<bigint>	
	 	 
Detailed Table Information	Table(tableName:default__src_src_index_6__, dbName:default, owner:null, createTime:1366741982, lastAccessTime:0, retention:0, sd:StorageDescriptor(cols:[FieldSchema(name:key, type:string, comment:null), FieldSchema(name:_bucketname, type:string, comment:), FieldSchema(name:_offsets, type:array<bigint>, comment:)], location:hdfs://mgrover-bigtop-centos-1.ent.cloudera.com:17020/user/hive/warehouse/default__src_src_index_6__, inputFormat:org.apache.hadoop.hive.ql.io.RCFileInputFormat, outputFormat:org.apache.hadoop.hive.ql.io.RCFileOutputFormat, compressed:false, numBuckets:-1, serdeInfo:SerDeInfo(name:null, serializationLib:org.apache.hadoop.hive.serde2.columnar.ColumnarSerDe, parameters:{serialization.format=1}), bucketCols:[], sortCols:[Order(col:key, order:1)], parameters:{}, skewedInfo:SkewedInfo(skewedColNames:[], skewedColValues:[], skewedColValueLocationMaps:{}), storedAsSubDirectories:false), partitionKeys:[], parameters:{transient_lastDdlTime=1366741982}, viewOriginalText:null, viewExpandedText:null, tableType:INDEX_TABLE)	


create index src_index_7 on table src(key) as 'compact' WITH DEFERRED REBUILD in table src_idx_src_index_7 STORED AS RCFILE
 
desc extended src_idx_src_index_7
key	string	
_bucketname	string	
_offsets	array<bigint>	
	 	 
Detailed Table Information	Table(tableName:src_idx_src_index_7, dbName:default, owner:null, createTime:1366741983, lastAccessTime:0, retention:0, sd:StorageDescriptor(cols:[FieldSchema(name:key, type:string, comment:null), FieldSchema(name:_bucketname, type:string, comment:), FieldSchema(name:_offsets, type:array<bigint>, comment:)], location:hdfs://mgrover-bigtop-centos-1.ent.cloudera.com:17020/user/hive/warehouse/src_idx_src_index_7, inputFormat:org.apache.hadoop.hive.ql.io.RCFileInputFormat, outputFormat:org.apache.hadoop.hive.ql.io.RCFileOutputFormat, compressed:false, numBuckets:-1, serdeInfo:SerDeInfo(name:null, serializationLib:org.apache.hadoop.hive.serde2.columnar.ColumnarSerDe, parameters:{serialization.format=1}), bucketCols:[], sortCols:[Order(col:key, order:1)], parameters:{}, skewedInfo:SkewedInfo(skewedColNames:[], skewedColValues:[], skewedColValueLocationMaps:{}), storedAsSubDirectories:false), partitionKeys:[], parameters:{transient_lastDdlTime=1366741983}, viewOriginalText:null, viewExpandedText:null, tableType:INDEX_TABLE)	


create index src_index_8 on table src(key) as 'compact' WITH DEFERRED REBUILD IDXPROPERTIES ("prop1"="val1", "prop2"="val2")
 
desc extended default__src_src_index_8__
key	string	
_bucketname	string	
_offsets	array<bigint>	
	 	 
Detailed Table Information	Table(tableName:default__src_src_index_8__, dbName:default, owner:null, createTime:1366741983, lastAccessTime:0, retention:0, sd:StorageDescriptor(cols:[FieldSchema(name:key, type:string, comment:null), FieldSchema(name:_bucketname, type:string, comment:), FieldSchema(name:_offsets, type:array<bigint>, comment:)], location:hdfs://mgrover-bigtop-centos-1.ent.cloudera.com:17020/user/hive/warehouse/default__src_src_index_8__, inputFormat:org.apache.hadoop.mapred.TextInputFormat, outputFormat:org.apache.hadoop.hive.ql.io.IgnoreKeyTextOutputFormat, compressed:false, numBuckets:-1, serdeInfo:SerDeInfo(name:null, serializationLib:org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe, parameters:{serialization.format=1}), bucketCols:[], sortCols:[Order(col:key, order:1)], parameters:{}, skewedInfo:SkewedInfo(skewedColNames:[], skewedColValues:[], skewedColValueLocationMaps:{}), storedAsSubDirectories:false), partitionKeys:[], parameters:{transient_lastDdlTime=1366741983}, viewOriginalText:null, viewExpandedText:null, tableType:INDEX_TABLE)	


create index src_index_9 on table src(key) as 'compact' WITH DEFERRED REBUILD TBLPROPERTIES ("prop1"="val1", "prop2"="val2")
 
desc extended default__src_src_index_9__
key	string	
_bucketname	string	
_offsets	array<bigint>	
	 	 
Detailed Table Information	Table(tableName:default__src_src_index_9__, dbName:default, owner:null, createTime:1366741984, lastAccessTime:0, retention:0, sd:StorageDescriptor(cols:[FieldSchema(name:key, type:string, comment:null), FieldSchema(name:_bucketname, type:string, comment:), FieldSchema(name:_offsets, type:array<bigint>, comment:)], location:hdfs://mgrover-bigtop-centos-1.ent.cloudera.com:17020/user/hive/warehouse/default__src_src_index_9__, inputFormat:org.apache.hadoop.mapred.TextInputFormat, outputFormat:org.apache.hadoop.hive.ql.io.IgnoreKeyTextOutputFormat, compressed:false, numBuckets:-1, serdeInfo:SerDeInfo(name:null, serializationLib:org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe, parameters:{serialization.format=1}), bucketCols:[], sortCols:[Order(col:key, order:1)], parameters:{}, skewedInfo:SkewedInfo(skewedColNames:[], skewedColValues:[], skewedColValueLocationMaps:{}), storedAsSubDirectories:false), partitionKeys:[], parameters:{prop2=val2, prop1=val1, transient_lastDdlTime=1366741984}, viewOriginalText:null, viewExpandedText:null, tableType:INDEX_TABLE)	


create table `_t`(`_i` int, `_j` int)

create index x on table `_t`(`_j`) as 'compact' WITH DEFERRED REBUILD

alter index x on `_t` rebuild
Deleted /user/hive/warehouse/default___t_x__


create index x2 on table `_t`(`_i`,`_j`) as 'compact' WITH DEFERRED
REBUILD

alter index x2 on `_t` rebuild
Deleted /user/hive/warehouse/default___t_x2__


drop index src_index_2 on src

drop index src_index_3 on src

drop index src_index_4 on src

drop index src_index_5 on src

drop index src_index_6 on src

drop index src_index_7 on src

drop index src_index_8 on src

drop index src_index_9 on src

drop table `_t`
