How can I use the HBASE Shell to create a table with pre splitting and compression or other options -
in hbase shell, help file shows there several allowable syntaxes creating table:
create 'tablename', {name => 'colfamily', versions => 5 } create 'tablename', {name => 'cf1'}, {name => 'cf2'} create 'tablename', 'cf1', 'cf2', 'cf3' create 'tablename', 'cf1', {splits => ['10','20','30','40']}
i want create table specify both split , table options, compression => 'snappy' , versions, can't seem figure out syntax or find useful documentation.
what became clear after experimentation shell syntax take set of column family dictionaries, , split dictionary own animal (which makes sense modifies whole table, not particular column family.
so additional useful illustration have be:
create 'tablename', {name => 'colfam', versions => 2, compression => 'snappy'}, {splits => ['333','666','foo']}
note splits dictionary separate column family dictionary; presumably still come in set of column families , end splits dictionary.
hbase
No comments:
Post a Comment