hbase安装之hbase的shell操作

1.进入 HBase 客户端命令行

  [atguigu@hadoop102 hbase]$ bin/hbase shell

2.查看帮助命令 hbase(main):001:0> help

3.查看当前数据库中有哪些表 hbase(main):002:0> list

4.创建表 hbase(main):002:0> create 'student','info'

5.插入数据到表 hbase(main):003:0> put 'student','1001','info:sex','male'

6.  扫描查看表数据 hbase(main):008:0> scan 'student

7.查看表结构 hbase(main):011:0> describe ‘student’

8.更新指定字段的数据 hbase(main):012:0> put 'student','1001','info:name','Nick'

9.查看“指定行”或“指定列族:列”的数据 hbase(main):014:0> get 'student','1001'

10.统计表数据行数 hbase(main):021:0> count 'student'

11.删除数据

  删除某 rowkey 的全部数据: hbase(main):016:0> deleteall 'student','1001'

  删除某 rowkey 的某一列数据:hbase(main):017:0> delete 'student','1002','info:sex'

原文地址:https://www.cnblogs.com/fengchuiguobanxia/p/15268705.html