Reputation: 1827
I want to know is it possible to retrieve existing hbase table's schema ?
I want to know what's column families' name and so on.
if any .net or java code , I will really appreciate to post for me.
Upvotes: 1
Views: 503
Reputation: 1231
Yes, it's possible. You only need to invoke HBaseAdmin.getTableDescriptor:
HBaseAdmin hbaseAdmin = new HBaseAdmin(config);
HTableDescriptor tableDescriptor = hbaseAdmin.getTableDescriptor(tableName)
The tableDescriptor object will contain all information about the table (families, etc).
Upvotes: 1