You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@phoenix.apache.org by Gaurav Agarwal <ga...@gmail.com> on 2015/10/06 20:42:11 UTC

Phoenix-issue with secondary index

Hello

We create the table thorugh hbase admin
We inserted the data through phoenix map reduce.
We apply secondary indexes there on the table after inserting data.
but when we do Select * from "Table", it didnot apply indexes there.

Any idea

why

Re: Phoenix-issue with secondary index

Posted by Yuhao Bi <by...@gmail.com>.
Hi there,

We may have encountered the same situation.
In our environment, after creating index on a table, we cannot apply the
index in query too.
Restart HBase and wait for a long time, it still don't work.

Finally, we found that, the index status in system table is building,  so
we manually modified the index status.
And it work.
You can use ALTER INDEX to change the index status to USABLE to check your
query result.
If you got your index work, you can change it to REBUILD to make sure there
is nothing corrupted.

Please see  http://phoenix.apache.org/language/index.html#alter_index


Thanks.
Yuhao Bi

2015-10-07 2:42 GMT+08:00 Gaurav Agarwal <ga...@gmail.com>:

> Hello
>
> We create the table thorugh hbase admin
> We inserted the data through phoenix map reduce.
> We apply secondary indexes there on the table after inserting data.
> but when we do Select * from "Table", it didnot apply indexes there.
>
> Any idea
>
> why
>
>
>