0

I want to create a reduced version of an HBase Table via Hbase shell. For example: HBase Table 'test' is already present in HBase with following info:

TableName: 'test'
ColumnFamily: 'f'
Columns: 'f:col1', 'f:col2', 'f:col3', 'f:col4'

I want to create another table in HBase 'test_reduced' which looks like this

TableName: 'test_reduced'
ColumnFamily: 'f'
Columns: 'f:col1', 'f:col3'

How can we do this via HBase shell ? I know how to copy the table using snapshot command So I am mainly looking for dropping column names in HBase Table.

Sachin Jain
  • 21,353
  • 33
  • 103
  • 168

1 Answers1

0

can't do it. you need to use Hbase Client API.

1- read the table in.

2- only "put" columns you want into your new table.

Cloudera came close by enabling users to perform "Partial HBase table copies" with "CopyTable" function, but that will allow you to change column_family names only ... (I am not sure you are using cloudera), but even that, is not what you are looking for.

for your ref: http://blog.cloudera.com/blog/2012/06/online-hbase-backups-with-copytable-2/