You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hive.apache.org by "Naveen Gangam (JIRA)" <ji...@apache.org> on 2015/02/24 20:11:05 UTC

[jira] [Updated] (HIVE-9770) Beeline ignores --showHeader for non-tablular output formats i.e csv,tsv,dsv

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

Naveen Gangam updated HIVE-9770:
--------------------------------
    Attachment: HIVE-9755.patch

I have attached a patch that changes the behavior I described above.
{code}
0: jdbc:hive2://localhost:10000> !outputformat csv2
0: jdbc:hive2://localhost:10000> select * from booleantest;
booleantest.name,booleantest.value
true,t
false,f
TRUE,T
FALSE,F
ZERO,0
ONE,1
t,t
T,t
0,0
1,1
f,f
F,f
12 rows selected (0.854 seconds)
0: jdbc:hive2://localhost:10000> !set showHeader false
0: jdbc:hive2://localhost:10000> select * from booleantest;
true,t
false,f
TRUE,T
FALSE,F
ZERO,0
ONE,1
t,t
T,t
0,0
1,1
f,f
F,f
12 rows selected (0.639 seconds)
{code}

I have tested this for other output types too (csv, tsv,tsv2, dsv etc). They all seem to be working as expected.
Could someone please review it? Thank you in advance.

> Beeline ignores --showHeader for non-tablular output formats i.e csv,tsv,dsv
> ----------------------------------------------------------------------------
>
>                 Key: HIVE-9770
>                 URL: https://issues.apache.org/jira/browse/HIVE-9770
>             Project: Hive
>          Issue Type: Bug
>          Components: Beeline
>    Affects Versions: 0.14.0
>            Reporter: Naveen Gangam
>            Assignee: Naveen Gangam
>            Priority: Critical
>             Fix For: 1.2.0
>
>         Attachments: HIVE-9755.patch
>
>
> [root@s1 ~]# beeline --silent=true --showHeader=false --outputformat=table -u "jdbc:hive2://localhost:10000" -e "select * from t1;"
> --------+
> 1
> --------+
> [root@s1 ~]# beeline --silent=true --showHeader=false --outputformat=vertical -u "jdbc:hive2://localhost:10000" -e "select * from t1;"
> t1.c1 1
> [root@s1 ~]# beeline --silent=true --showHeader=false --outputformat=csv -u "jdbc:hive2://localhost:10000" -e "select * from t1;"
> 't1.c1'
> '1'
> [root@s1 ~]# beeline --silent=true --showHeader=false --outputformat=tsv -u "jdbc:hive2://localhost:10000" -e "select * from t1;"
> 't1.c1'
> '1'
> [root@s1 ~]# beeline --silent=true --showHeader=false --outputformat=dsv -u "jdbc:hive2://localhost:10000" -e "select * from t1;"
> t1.c1
> 1
> [root@s1 ~]# beeline --silent=true --showHeader=false --outputformat=csv2 -u "jdbc:hive2://localhost:10000" -e "select * from t1;"
> t1.c1
> 1
> [root@s1 ~]# beeline --silent=true --showHeader=false --outputformat=tsv2 -u "jdbc:hive2://localhost:10000" -e "select * from t1;"
> t1.c1
> 1



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)