[ 
https://issues.apache.org/jira/browse/HIVE-7390?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14180333#comment-14180333
 ] 

Szehon Ho commented on HIVE-7390:
---------------------------------

Hi, it seems the consensus discussion at the time was that old CSV format was 
wrong (always added an extra quote around values no matter what).  And that 
it's valuable to add one extra option for configuring delimiting character in 
these *sv's.  So to summarize:

* Add a new Beeline output format: DSV , and a new Beeline option 
delimiterForDSV to decide what this would use to delimit.  For example if your 
char is | (default), then your data would look like "a|b|c".
* For all the *SV's, use double-quote as quoteChar, ',' as separator. 

However, it seems it will not quote by default as it did before this change.  
If you read the CSV specs, it will quote in these conditions:  when a cell 
contains special characters, such as the delimiter char, a quote char, or spans 
multiple lines.

So whereas CSV would have given "'a','b','c'" in the past, it will now not give 
those and always give "a,b,c".   Hope that helps.

> Make quote character optional and configurable in BeeLine CSV/TSV output
> ------------------------------------------------------------------------
>
>                 Key: HIVE-7390
>                 URL: https://issues.apache.org/jira/browse/HIVE-7390
>             Project: Hive
>          Issue Type: New Feature
>          Components: Clients
>    Affects Versions: 0.13.1
>            Reporter: Jim Halfpenny
>            Assignee: Ferdinand Xu
>              Labels: TODOC14
>             Fix For: 0.14.0
>
>         Attachments: HIVE-7390.1.patch, HIVE-7390.2.patch, HIVE-7390.3.patch, 
> HIVE-7390.4.patch, HIVE-7390.5.patch, HIVE-7390.6.patch, HIVE-7390.7.patch, 
> HIVE-7390.8.patch, HIVE-7390.9.patch, HIVE-7390.patch
>
>
> Currently when either the CSV or TSV output formats are used in beeline each 
> column is wrapped in single quotes. Quote wrapping of columns should be 
> optional and the user should be able to choose the character used to wrap the 
> columns.



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

Reply via email to