Works pretty well. Thanks for the examples.
On Mon, Sep 9, 2013 at 2:04 AM, Nicolas Liochon <[email protected]> wrote: > Here is an example on trunk. IIRC, with 0.94, you may have to disable the > table before updating the definition. > > hbase(main):007:0> create 't2', {NAME => 'f1', VERSIONS => 5} > 0 row(s) in 0.2820 seconds > > => Hbase::Table - t2 > > > hbase(main):008:0> describe 't2' > DESCRIPTION > ENABLED > 't2', {NAME => 'f1', DATA_BLOCK_ENCODING => 'NONE', BLOOMFILTER => 'ROW', > REPLICATION_SCOPE => '0', VERSIONS => '5' > true > , COMPRESSION => 'NONE', MIN_VERSIONS => '0', TTL => '2147483647', > KEEP_DELETED_CELLS => 'false', BLOCKSIZE => > '655 > 36', IN_MEMORY => 'false', ENCODE_ON_DISK => 'true', BLOCKCACHE => > 'true'} > > 1 row(s) in 0.0050 seconds > > > > hbase(main):011:0> alter 't2', { NAME => 'f1', VERSIONS => 2 } > Updating all regions with the new schema... > 0/1 regions updated. > 1/1 regions updated. > Done. > 0 row(s) in 2.2480 seconds > > > hbase(main):012:0> describe 't2' > DESCRIPTION > ENABLED > 't2', {NAME => 'f1', DATA_BLOCK_ENCODING => 'NONE', BLOOMFILTER => 'ROW', > REPLICATION_SCOPE => '0', VERSIONS => '2' > true > , COMPRESSION => 'NONE', MIN_VERSIONS => '0', TTL => '2147483647', > KEEP_DELETED_CELLS => 'false', BLOCKSIZE => > '655 > 36', IN_MEMORY => 'false', ENCODE_ON_DISK => 'true', BLOCKCACHE => > 'true'} > > 1 row(s) in 0.0040 seconds > > > > On Mon, Sep 9, 2013 at 10:51 AM, Gaetan Deputier <[email protected] > >wrote: > > > I tried on a simple table using the following commands : > > > > create 't', 'f' > > > > alter 't', NAME => 'f', VERSIONS => 5 > > > > I have this Error : ERROR: Column family datafVERSIONS5 must have a name > > > > I have tried with the syntax from the alter help page but no success. Any > > hints ? > > > > > > I am running Hbase from Cloudera version 0.94.6-cdh4.3.0. > > > > > > On Mon, Sep 9, 2013 at 1:25 AM, Gaetan Deputier <[email protected] > > >wrote: > > > > > Exactly what i was looking for. Thank you very much ! > > > > > > > > > On Mon, Sep 9, 2013 at 12:48 AM, Nicolas Liochon <[email protected] > > >wrote: > > > > > >> There is a comment in this class that is outdated ("Once set, the > > >> parameters that specify a column cannot be changed without deleting > the > > >> column and recreating it. If there is data stored in the column, it > will > > >> be > > >> deleted when the column is deleted."). This is from 2007. I will fix > > this. > > >> > > >> It's possible to alter a table after its definition, and you will not > > lose > > >> any data. See the alter command in the shell: alter 't1', NAME ='f1', > > >> VERSIONS => 5 > > >> > > >> > > >> On Mon, Sep 9, 2013 at 6:32 AM, Ted Yu <[email protected]> wrote: > > >> > > >> > Take a look at HColumnDescriptor#setMaxVersions() > > >> > > > >> > Cheers > > >> > > > >> > On Sun, Sep 8, 2013 at 9:13 PM, Gaetan Deputier < > > >> [email protected] > > >> > >wrote: > > >> > > > >> > > Hello Hbase users, > > >> > > > > >> > > Is it possible to set the max number of row versions of a table > > after > > >> its > > >> > > creation ? > > >> > > > > >> > > Sincerely > > >> > > > > >> > > G. > > >> > > > > >> > > > >> > > > > > > > > >
