You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hama.apache.org by "Edward J. Yoon" <ed...@apache.org> on 2008/12/19 05:42:15 UTC

Object key sort

We are store the object to row key.

put(new BlockID(int x, int y).getBytes(), columnName, data);
--
BlockID.readFields() {
  this.x = in.readInt();
  this.y = in.readInt();
}
--
Then, It'll be sorted in Hbase table as describe below. (Hbase
row/column is alphabetical sort. )

0, 0
1, 0
2, 0
0, 1
1, 1
2, 1
..

How can we get a sorted set as grouped by x?

0, 0
0, 1
0, 2
1, 0
1, 1
1, 2


-- 
Best Regards, Edward J. Yoon @ NHN, corp.
edwardyoon@apache.org
http://blog.udanax.org