Just reiterating with JGray says -- usually, when you need a secondary index, you can get away with denormalizing and duplicating your data.
On Mon, Aug 17, 2009 at 9:30 AM, Jonathan Gray<[email protected]> wrote: > This is possible by checking the values in your client, through server-side > filters (see org.apache.hadoop.hbase.filter), or with secondary indexing (as > described in my previous e-mail). > > In the first two cases, you are doing a full table scan so it is very > inefficient. That's the same as it would be in an RDBMS if you were not > using secondary indexes, however. > > HBase has limited secondary indexing support, but do not expect the > flexibility and performance you get from an RDBMS secondary index. > > If this is central to your usage of HBase, make sure that HBase is what you > want and take another look at your schema to see if there might be a better > design to prevent needing heavy indexing or table scanning. > > JG > > Rocks wrote: >> >> Thanks for you answer. >> however, what i want to do just likes "where" keyword of SQL in RDBMS. Is >> it impossible in hbase ? >> >> On Mon, Aug 17, 2009 at 2:58 PM, Ryan Rawson <[email protected]> wrote: >> >>> hey, >>> >>> That isn't how hbase (or even rdbms) work. Instead you can retrieve >>> rows based on their row key. Otherwise you will have to read the >>> entire table to find just that 1 row. Yes this is as inefficient as it >>> sounds. >>> >>> If you frequently have this issue, you may need to build and maintain >>> secondary indexes. Unlike relational dbs, there is no built in support >>> for this, you have to write your app to handle this. >>> >>> -yran >>> >>> >>> >>> On Sun, Aug 16, 2009 at 11:51 PM, lei wang<[email protected]> >>> wrote: >>>> >>>> Hi, if a know a cell in a hbase for its column:<qualifer>:value, i need >>> >>> to >>>> >>>> know which row key it belongs to. I searched the HBase api several >>>> times, >>>> but i can not find the right method to solve my problem. Thanks for >>>> one's >>>> suggestion to me. >>>> >> > -- http://www.roadtofailure.com -- The Fringes of Scalability, Social Media, and Computer Science
