如何向现有 HBase 表添加新列族? [英] How to add new column family to an existing HBase table?

查看:43
本文介绍了如何向现有 HBase 表添加新列族?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个表

create 'tablename', 'columnfamily1'

现在可以添加另一个列族columnfamily2"吗?方法是什么?

Now is it possible to add another column family 'columnfamily2'? What is the method?

推荐答案

好像

alter 'tablename', 'columnfamily2'

成功了.可以先禁用tablename".但是,即使启用它也能正常工作.

does the trick. One may, disable 'tablename' first. However, it works fine even if enabled.

hbase(main):015:0> alter 'tablename', {NAME=> 'columnfamily2'}
Updating all regions with the new schema...
0/1 regions updated.
1/1 regions updated.
Done.

这篇关于如何向现有 HBase 表添加新列族?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆