get_counter
Contents
Definition
Returns a counter for the cell value with the specified table/row/column coordinates. A counter should be managed with atomic increment functions (see incr), and the data value should be binary encoded (as long).
Usage
get_counter '[<namespace_name>:]<table_name>',
'<row_key>',
'<column_family>:<column_qualifier>'
Parameter | Description |
---|---|
namespace_name |
A namespace name |
table_name |
A table name |
row_key |
A row key |
column_family |
A column family name |
column_qualifier |
A column qualifier |
Examples
hbase(main):049:0> incr 't4', 'r1', 'cf1:c5', 11 COUNTER VALUE = 3978705112342280269 Took 0.0079 seconds hbase(main):050:0> get 't4','r1','cf1:c5' COLUMN CELL cf1:c5 timestamp=1637328326920, value=7738718M 1 row(s) Took 0.0091 seconds hbase(main):001:0> get_counter 't4', 'r1', 'cf1:c5' COUNTER VALUE = 3978705112342280269 Took 0.4473 seconds