[ 
https://issues.apache.org/jira/browse/HIVE-3884?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Dilip Joseph updated HIVE-3884:
-------------------------------

    Attachment: describe_test_table.png

Output of DESCRIBE test_table for the following table:

CREATE TABLE test_table(
    col1 INT COMMENT 'col1 one line comment',
    col2 STRING COMMENT 'col2 very long comment that is greater than 80 chars 
and is likely to spill into multiple lines',
    col3 STRING COMMENT 'col3 very long multi-line comment where each line is 
very long by itself and is likely to spill
into multiple lines.  Lorem ipsum dolor sit amet, consectetur adipiscing elit. 
Proin in dolor nisl, sodales
adipiscing tortor. Integer venenatis',
    col4 INT COMMENT 'col4 one line comment',
    col5_VeryLongColumnNameThatMessesUpAlignment INT COMMENT 'col5 one line 
comment',
    col6 STRING COMMENT 'col6 one line comment'
);
                
> Better align columns in DESCRIBE table_name output to make more human-readable
> ------------------------------------------------------------------------------
>
>                 Key: HIVE-3884
>                 URL: https://issues.apache.org/jira/browse/HIVE-3884
>             Project: Hive
>          Issue Type: Improvement
>          Components: CLI
>    Affects Versions: 0.9.0
>            Reporter: Dilip Joseph
>            Priority: Minor
>         Attachments: describe_test_table.png
>
>
> If a table contains very long comments or very long column names, the output 
> of DESCRIBE table_name is not aligned nicely.  The attached screenshot shows 
> the following two problems:
> 1. Rows with long column names do not align well with other columns.
> 2. Rows with long comments wrap to the next line, and make it hard to read 
> the output.  The wrapping behavior depends on the width of the user's 
> terminal width.
> It will be nice to have a DESCRIBE PRETTY table_name command that will 
> produce nicely formatted output that avoids the two problems mentioned above. 
>  It is better to introduce a new DESCRIBE PRETTY command rather than change 
> the behavior of the existing DESCRIBE or DESCRIBE FORMATTED commands, so that 
> we avoid breaking any scripts that automatically parse the output.
> Since the pretty formatting depends on the current terminal width, we need a 
> new hive conf parameter to tell the CLI to auto-detect the current terminal 
> width or to use a fixed width (needed for unit tests).

--
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

Reply via email to