This tutorial describes how to fetch a single row and specific columns from the table using the HBase shell and will practice with some examples.
Reading Data From HBase Table using Get command
Use get
to retrieve the data from a single row and it’s columns. The syntax for command get is as follows.
Syntax: get ‘<namespace>:<table_name>’, ‘<row_key>’, ‘<column_key>’
Example:
Below command returns ‘2’ with all columns
This again returns ‘2’ but with just columns specified ‘office:age’ and ‘office:name’
Alternatively, this command returns the same result
Other commands to explore
Next, Let’s see how to enable or disable a table.