[
https://issues.apache.org/jira/browse/HBASE-6592?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jie Huang updated HBASE-6592:
-----------------------------
Attachment: hbase-6592-v2.patch
@Stack, Update the patch file with following changes.
# add test cases for both get and scan.
# add usage examples in scan/get helper.
Here is the usage info for this feature. Anything improper, please let me know.
thanks.
{noformat}
Besides the default 'toStringBinary' format, scan also supports customized
output format for each column.
User can define a CONVERTER, which follows the general column spec of
"cf:qualifier", like "cf:qualifier[:CONVERTER]".
The CONVERTER can be formatted as
1. either "converterFun" alone (e.g, toInt, toString)
2. or a complete pattern of 'c(MyConverterClass).converterFun'.
While using the 1st. CONVERTER definition, it chooses
"org.apache.hadoop.hbase.util.Bytes" as the default class.
Example:
hbase> scan 't1', {COLUMNS => ['cf:qualifier:toInt',
'cf:qualifier:c(org.apache.hadoop.hbase.util.Bytes).toInt'] }
ATTENTION!The above feature cannot be applied on the entire column family,
since it is too confusing to distinguish "cf:qualifier" and "cf:CONVERTER"
{noformat}
> [shell] Add means of custom formatting output by column
> -------------------------------------------------------
>
> Key: HBASE-6592
> URL: https://issues.apache.org/jira/browse/HBASE-6592
> Project: HBase
> Issue Type: New Feature
> Components: shell
> Reporter: stack
> Priority: Minor
> Labels: noob
> Attachments: hbase-6592.patch, hbase-6592-v2.patch,
> hbase-6952-v1.patch
>
>
> See Jacques suggestion toward end of this thread for how we should allow
> adding a custom formatter per column to use outputting column content in
> shell:
> http://search-hadoop.com/m/2WxUB1fuxL11/Printing+integers+in+the+Hbase+shell&subj=Printing+integers+in+the+Hbase+shell
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira