Hi,
I am using hbase shell to verify some konwleges that I have read from
the post of "Understanding HBase and BigTable"
That post says: "If an application asks for a given row at a given timestamp,
HBase will return cell data where the timestamp is less than or equal to
the one provided."
After some experiments, I feel confused about the concept of "less than" .
Describe details in the following :
1) create table:
create 'table', {NAME=>'cf1', VERSIONS=>3}
2) put some data in one cell with multi-version:
put 'table', 'row1', 'cf1:c1' , 'aaaa', 16
put 'table', 'row1', 'cf1:c1' , 'bbbb', 25
put 'table', 'row1', 'cf1:c1' , 'dddd', 32
3) get data:
get 'table', 'row1', {COLUMN=>'cf1:c1', TIMESTAMP=>19}
The result is NULL.
As the post says, The 'bbbb' with timestamp 16 that "less than" 19 should be
returned,
Why get nothing?
(p.s I write some java code to verify the "less than" concept using
method setTimestamp(19) of class Get, and get same result . )
In addition, one more questions:
When I create table with parameter "VERSIONS=>3", means in one cell
only has not more than three version datas, is right?
If right, when I put more data into same cell, such as:
put 'table', 'row1', 'cf1:c1' ,'ffff', 42
Have four versions or three versions in this cell now?
why I can still retireve the oldest version data with timestamp 16?
hbase(main):022:0> get 'table', 'row1', {COLUMN=>'cf1:c1', TIMESTAMP=>16}
COLUMN CELL
cf1:c1 timestamp=16, value=aaaa
Sorry about the long mail, any help will be appreciated.
--
Pan W <[email protected]>