You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hbase.apache.org by ashishkshukladb <as...@gmail.com> on 2013/11/25 12:17:00 UTC

How to get Metadata information in Hbase

I want to get the metadata information in Hbase. My basic purpose is to -

1.get the information about tables like how many tables and name of tables.

2.get the columnfamilies name in each table.

3.get the columns names and their data types in each columnfamily.

Is there any tool or command by using which we can get the above information
??




--
View this message in context: http://apache-hbase.679495.n3.nabble.com/How-to-get-Metadata-information-in-Hbase-tp4053044.html
Sent from the HBase User mailing list archive at Nabble.com.

Re: How to get Metadata information in Hbase

Posted by James Taylor <jt...@salesforce.com>.
One other tool option for you is to use Phoenix. You use SQL to create a
table and define the columns through standard DDL. Your columns make up the
allowed KeyValues for your table and the metadata is surfaced through the
standard JDBC metadata APIs (with column family mapping to table catalog).

Thanks,
James


On Mon, Nov 25, 2013 at 10:51 AM, Jean-Marc Spaggiari <
jean-marc@spaggiari.org> wrote:

> >1.get the information about tables like how many tables and name of
> tables.
> You can use HBaseAdmin from the API. admin.getTableNames()
>
> > 2.get the columnfamilies name in each table.
> From the table you can get the descriptor to get the families:
> table.getTableDescriptor();
>
> >3.get the columns names and their data types in each columnfamily.
> to get the ALL the column names, 2 options. 1) You keep track of them in
> your application using constans... 2) you run a full scan map reduce job.
>
> JM
>
>
> 2013/11/25 Ted Yu <yu...@gmail.com>
>
> > bq. 3.get the columns names and their data types in each columnfamily.
> >
> > Each columnfamily can have arbitrarily many columns. There is no tool
> which
> > returns the above information.
> >
> >
> > On Tue, Nov 26, 2013 at 12:26 AM, Asaf Mesika <as...@gmail.com>
> > wrote:
> >
> > > bin/hbase shell
> > > In there:
> > > Type help and you'll get along
> > >
> > > On Monday, November 25, 2013, ashishkshukladb wrote:
> > >
> > > > I want to get the metadata information in Hbase. My basic purpose is
> > to -
> > > >
> > > > 1.get the information about tables like how many tables and name of
> > > tables.
> > > >
> > > > 2.get the columnfamilies name in each table.
> > > >
> > > > 3.get the columns names and their data types in each columnfamily.
> > > >
> > > > Is there any tool or command by using which we can get the above
> > > > information
> > > > ??
> > > >
> > > >
> > > >
> > > >
> > > > --
> > > > View this message in context:
> > > >
> > >
> >
> http://apache-hbase.679495.n3.nabble.com/How-to-get-Metadata-information-in-Hbase-tp4053044.html
> > > > Sent from the HBase User mailing list archive at Nabble.com.
> > > >
> > >
> >
>

Re: How to get Metadata information in Hbase

Posted by Jean-Marc Spaggiari <je...@spaggiari.org>.
>1.get the information about tables like how many tables and name of tables.
You can use HBaseAdmin from the API. admin.getTableNames()

> 2.get the columnfamilies name in each table.
>From the table you can get the descriptor to get the families:
table.getTableDescriptor();

>3.get the columns names and their data types in each columnfamily.
to get the ALL the column names, 2 options. 1) You keep track of them in
your application using constans... 2) you run a full scan map reduce job.

JM


2013/11/25 Ted Yu <yu...@gmail.com>

> bq. 3.get the columns names and their data types in each columnfamily.
>
> Each columnfamily can have arbitrarily many columns. There is no tool which
> returns the above information.
>
>
> On Tue, Nov 26, 2013 at 12:26 AM, Asaf Mesika <as...@gmail.com>
> wrote:
>
> > bin/hbase shell
> > In there:
> > Type help and you'll get along
> >
> > On Monday, November 25, 2013, ashishkshukladb wrote:
> >
> > > I want to get the metadata information in Hbase. My basic purpose is
> to -
> > >
> > > 1.get the information about tables like how many tables and name of
> > tables.
> > >
> > > 2.get the columnfamilies name in each table.
> > >
> > > 3.get the columns names and their data types in each columnfamily.
> > >
> > > Is there any tool or command by using which we can get the above
> > > information
> > > ??
> > >
> > >
> > >
> > >
> > > --
> > > View this message in context:
> > >
> >
> http://apache-hbase.679495.n3.nabble.com/How-to-get-Metadata-information-in-Hbase-tp4053044.html
> > > Sent from the HBase User mailing list archive at Nabble.com.
> > >
> >
>

Re: How to get Metadata information in Hbase

Posted by Ted Yu <yu...@gmail.com>.
bq. 3.get the columns names and their data types in each columnfamily.

Each columnfamily can have arbitrarily many columns. There is no tool which
returns the above information.


On Tue, Nov 26, 2013 at 12:26 AM, Asaf Mesika <as...@gmail.com> wrote:

> bin/hbase shell
> In there:
> Type help and you'll get along
>
> On Monday, November 25, 2013, ashishkshukladb wrote:
>
> > I want to get the metadata information in Hbase. My basic purpose is to -
> >
> > 1.get the information about tables like how many tables and name of
> tables.
> >
> > 2.get the columnfamilies name in each table.
> >
> > 3.get the columns names and their data types in each columnfamily.
> >
> > Is there any tool or command by using which we can get the above
> > information
> > ??
> >
> >
> >
> >
> > --
> > View this message in context:
> >
> http://apache-hbase.679495.n3.nabble.com/How-to-get-Metadata-information-in-Hbase-tp4053044.html
> > Sent from the HBase User mailing list archive at Nabble.com.
> >
>

Re: How to get Metadata information in Hbase

Posted by Asaf Mesika <as...@gmail.com>.
bin/hbase shell
In there:
Type help and you'll get along

On Monday, November 25, 2013, ashishkshukladb wrote:

> I want to get the metadata information in Hbase. My basic purpose is to -
>
> 1.get the information about tables like how many tables and name of tables.
>
> 2.get the columnfamilies name in each table.
>
> 3.get the columns names and their data types in each columnfamily.
>
> Is there any tool or command by using which we can get the above
> information
> ??
>
>
>
>
> --
> View this message in context:
> http://apache-hbase.679495.n3.nabble.com/How-to-get-Metadata-information-in-Hbase-tp4053044.html
> Sent from the HBase User mailing list archive at Nabble.com.
>