> On July 31, 2014, 10:45 a.m., Lars Francke wrote:
> > beeline/src/java/org/apache/hive/beeline/SeparatedValuesOutputFormat.java, 
> > line 50
> > <https://reviews.apache.org/r/23799/diff/4/?file=646700#file646700line50>
> >
> >     Instead of initializing it here like this you could get rid of the new 
> > parameter and check in getFormattedStr if csvPreference is null. If it is 
> > then check in the opts if DSV is selected and which delimiter was specified.
> >     
> >     That way you wouldn't create a new csvPreference for each row either.
> >     
> >     Either that or pass in the proper delimiter from the start, see my 
> > comment in Beeline

that's a good advice. Is this a possible use case that user changed the 
delimiter after he choose the DSV output format? Also a problem troubles is 
that the format array is initialized when beeline is instantiated.


> On July 31, 2014, 10:45 a.m., Lars Francke wrote:
> > beeline/src/java/org/apache/hive/beeline/BeeLineOpts.java, line 500
> > <https://reviews.apache.org/r/23799/diff/4/?file=646699#file646699line500>
> >
> >     Now, I have no idea how that works myself but it'd be fabulous if we 
> > could specify \001 etc. here as well. It is Hive's default separator after 
> > all. Not sure how that parsing stuff is handled so take this as an optional 
> > idea but by no means necessary.

The "\001" is meaning "Ctrl+A", right? SuperCSV has a limitation for delimiter 
that it has to be a char type, so I am not sure whether "\001" is suitable 
being a separator. At this point, "\001" delimiter may not be easy to fully 
support just using SuperCSV. We can consider this in a new jira if a strong 
need for it. Thanks very much for figuring it out.


- cheng


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/23799/#review49214
-----------------------------------------------------------


On July 31, 2014, 5:34 a.m., cheng xu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/23799/
> -----------------------------------------------------------
> 
> (Updated July 31, 2014, 5:34 a.m.)
> 
> 
> Review request for hive.
> 
> 
> Bugs: HIVE-7390
>     https://issues.apache.org/jira/browse/HIVE-7390
> 
> 
> Repository: hive-git
> 
> 
> Description
> -------
> 
> HIVE-7390: refactor csv output format with in RFC mode and add one more 
> option to support formatting as the csv format in hive cli
> 
> 
> Diffs
> -----
> 
>   beeline/pom.xml 6ec1d1aff3f35c097aa6054aae84faf2d63854f1 
>   beeline/src/java/org/apache/hive/beeline/BeeLine.java 
> 528a98e29c23421f9352bdf7c5edd3a9fae0e3ea 
>   beeline/src/java/org/apache/hive/beeline/BeeLineOpts.java 
> 75f7d38cb97fb753a8f39c19488b9ce0a8d77590 
>   beeline/src/java/org/apache/hive/beeline/SeparatedValuesOutputFormat.java 
> 7853c3f38f3c3fb9ae0b9939c714f1dc940ba053 
>   beeline/src/main/resources/BeeLine.properties 
> 390d062b8dc52dfa790c7351f3db44c1e0dd7e37 
>   
> itests/hive-unit/src/test/java/org/apache/hive/beeline/TestBeeLineWithArgs.java
>  8888bd97aff5959fd9040fc0f0a1f6b782f2aa6f 
>   pom.xml b5a5697e6a3b689c2b244ba0338be541261eaa3d 
> 
> Diff: https://reviews.apache.org/r/23799/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> cheng xu
> 
>

Reply via email to