hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Edward J. Yoon" <edwardy...@apache.org>
Subject Object key sort
Date Fri, 19 Dec 2008 04:51:03 GMT
My key is a Segment(x, y). And, put(new Segment(int x, int
y).getBytes(), columnName, data) to table.

Segment.write() {
  out.writeInt(this.x);
  out.writeInt(this.y);
}

Then, key set is :

[ (0, 0),
(1, 0),
(2, 0),
(0, 1),
(1, 1),
...]

Could anyone give me some advice on how to get sorted set as grouped by x?

[ (0, 0),
(0, 1),
(0, 2),
(1, 0),
(1, 1),
...]

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

Mime
View raw message