- distributed, column-oriented persistent multidimensional sorted map
- storing column-family into memory/disc
- disc = hdfs or filesystem
- column family has 'veracity' - version of the record based on timestamp
- Value = Table + RowKey + Family + Column + Timestamp
data is sparse - a lot of column has null values
fast retrieving data by 'key of the row' + 'column name'
contains from: (HBase HMaster) *---> (HBase Region Server)
SQL for Hbase - Phoenix SQL
start/stop hbase
$HBASE_HOME/bin/start-hbase.sh
$HBASE_HOME/bin/stop-hbase.sh
$HBASE_HOME/bin/hbase shell
- list of the tables
list
- create table
create table 'mytable1'
- delete table
drop table 'mytable1'
disable table 'mytable1'
- iterate through a table, iterate with range
scan 'my_space:mytable1'
scan 'my_space:mytable1', {STARTROW=>"00223cfd-8b50-979d29164e72:1220", STOPROW=>"00223cfd-8b50-979d29164e72:1520"}
- save results into a file
echo " scan 'my_space:mytable1', {STARTROW=>"00223cfd-8b50-979d29164e72:1220", STOPROW=>"00223cfd-8b50-979d29164e72:1520"} " | hbase shell > out.txt
- insert data
put 'mytable1', 'row0015', 'cf:MyColumnFamily2', 'my value 01'
- read data
get 'mytable1', 'row0015'