Thanks for your replies, guys.
I’m trying to understand that dynamic column feature, not sure how to apply it 
in my case.
Let’s look at the concrete example : suppose I have an existing Hbase table 
“X", which has only one column family “A”. Each record has either one or two or 
three columns with qualifiers “A1”,”A2”, or “A3”, I.e. some records has only 
one column A.A1, or A.A2, or A.A3, some just two, some all three.
How can I create a view using dynamic columns that I can query later ?

Thank you,
Sergey Malov

From: anil gupta <anilgupt...@gmail.com<mailto:anilgupt...@gmail.com>>
Reply-To: "user@phoenix.apache.org<mailto:user@phoenix.apache.org>" 
<user@phoenix.apache.org<mailto:user@phoenix.apache.org>>
Date: Friday, June 26, 2015 at 18:28
To: "user@phoenix.apache.org<mailto:user@phoenix.apache.org>" 
<user@phoenix.apache.org<mailto:user@phoenix.apache.org>>
Subject: Re: create a view on existing production table ?

Hi Sergey,

Since you have hundreds of thousand of columns. You can query your data by 
using dynamic columns features of phoenix. In this way, you wont need to 
predefine 100's of thousands of columns.

Thanks,
Anil Gupta

On Fri, Jun 26, 2015 at 11:34 AM, James Taylor 
<jamestay...@apache.org<mailto:jamestay...@apache.org>> wrote:
Sergey,
It is possible, but maybe in your case it's not feasible.
Thanks,
James


On Friday, June 26, 2015, Sergey Malov 
<sma...@collective.com<mailto:sma...@collective.com>> wrote:
Hi James,
>From you reply I understand that it is NOT possible to create such a view, 
>because each family can have different number of columns, and it could be just 
>one column per family for one PK, and hundreds of thousands for another PK. 
>How can I possibly accommodate it in a view specification, if I need to 
>explicitly define column by name  ?
Or I misunderstand something ?

Thank you,
Sergey

From: James Taylor <jamestay...@apache.org>
Reply-To: "user@phoenix.apache.org" <user@phoenix.apache.org>
Date: Friday, June 26, 2015 at 12:04
To: "user@phoenix.apache.org" <user@phoenix.apache.org>
Subject: Re: create a view on existing production table ?

Hi Sergey,
Yes, you can create a Phoenix view over this HBase table, but you have to 
explicitly list columns by name (i.e. column qualifier) either at view creation 
time or at read time (using dynamic columns). Also, the row key must conform to 
what Phoenix expects if there are multiple columns in your PK.
Thanks,
James

On Wednesday, June 24, 2015, Sergey Malov <sma...@collective.com> wrote:
My apologies if this info can be found somewhere, I don’t see it.
I have a production table “profile” with the following schema :


{NAME => 'edge', BLOOMFILTER => 'ROW', VERSIONS => '2', IN_MEMORY => 'false', 
KEEP_DELETED_CELLS => 'false', DATA_BLOCK_ENCODING => 'FAST_DIFF', COMPRESSION 
=> 'SNAPPY', TTL => '

FOREVER', MIN_VERSIONS => '0', BLOCKCACHE => 'true', BLOCKSIZE => '65536', 
REPLICATION_SCOPE => '1'}

{NAME => 'export', BLOOMFILTER => 'ROW', VERSIONS => '2', IN_MEMORY => 'false', 
KEEP_DELETED_CELLS => 'false', DATA_BLOCK_ENCODING => 'FAST_DIFF', COMPRESSION 
=> 'SNAPPY', TTL =>

 'FOREVER', MIN_VERSIONS => '0', BLOCKCACHE => 'true', BLOCKSIZE => '65536', 
REPLICATION_SCOPE => '1'}

{NAME => 'visitor', BLOOMFILTER => 'ROW', VERSIONS => '2', IN_MEMORY => 
'false', KEEP_DELETED_CELLS => 'false', DATA_BLOCK_ENCODING => 'FAST_DIFF', 
COMPRESSION => 'SNAPPY', TTL =

> 'FOREVER', MIN_VERSIONS => '0', BLOCKCACHE => 'true', BLOCKSIZE => '65536', 
> REPLICATION_SCOPE => '1'}

Each of these families can have variable number of column for a given key, with 
some having hundreds of thousands columns.
Is it possible to create a Phoenix view for such a table ?

Thank you,
Sergey Malov



--
Thanks & Regards,
Anil Gupta

Reply via email to