You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@phoenix.apache.org by kylin <ks...@redhat.com> on 2014/12/10 07:40:25 UTC
A question for how map exist HBase table to Phoenix table
Dear Experts
Thanks for your time and attention.
I am try to use Phoenix on top of HBase, which HBase contain some exist
tables, I am confused about how map HBase table to a Phoenix one.
* is there any examples or documents for this?
I have done some test, as [1] figure, I use the following DDL to create
mapping table:
CREATE TABLE IF NOT EXISTS \"Customer\" (ROW_ID VARCHAR PRIMARY KEY,
\"sales\".\"amount\" VARCHAR, \"sales\".\"product\" VARCHAR,
\"customer\".\"city\" VARCHAR, \"customer\".\"name\" VARCHAR)
This can map fine, but the mapped column only are qualifier like
ROW_ID/VARCHAR amount/VARCHAR product/VARCHAR city/VARCHAR name/VARCHAR
So my another question:
* Is there a way to customize column name during mapping? also any
documents or example?
Thanks very much.
Kylin
[1] http://ksoong.org/hbase-datamodel/
--
JBoss By Redhat
Mobile: +86 18611907049
ksoong.org
Re: A question for how map exist HBase table to Phoenix table
Posted by Ravi Kiran <ma...@gmail.com>.
Hi Kylin,
Just to confirm, are you saying that columns aren't being mapped to
column family correctly ? Can you please validate it from any SQL Client (
http://phoenix.apache.org/download.html#SQL-Client) .
Regards
Ravi
On Tue, Dec 9, 2014 at 10:40 PM, kylin <ks...@redhat.com> wrote:
> Dear Experts
>
> Thanks for your time and attention.
>
> I am try to use Phoenix on top of HBase, which HBase contain some exist
> tables, I am confused about how map HBase table to a Phoenix one.
>
> * is there any examples or documents for this?
>
> I have done some test, as [1] figure, I use the following DDL to create
> mapping table:
>
> CREATE TABLE IF NOT EXISTS \"Customer\" (ROW_ID VARCHAR PRIMARY KEY,
> \"sales\".\"amount\" VARCHAR, \"sales\".\"product\" VARCHAR,
> \"customer\".\"city\" VARCHAR, \"customer\".\"name\" VARCHAR)
>
> This can map fine, but the mapped column only are qualifier like
>
> ROW_ID/VARCHAR amount/VARCHAR product/VARCHAR city/VARCHAR name/VARCHAR
>
> So my another question:
>
> * Is there a way to customize column name during mapping? also any
> documents or example?
>
> Thanks very much.
>
> Kylin
>
> [1] http://ksoong.org/hbase-datamodel/
>
>
> --
> JBoss By Redhat
> Mobile: +86 18611907049
> ksoong.org
>
>