flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kurt Young (Jira)" <j...@apache.org>
Subject [jira] [Commented] (FLINK-14784) CsvTableSink miss delimiter when row start with null member
Date Fri, 15 Nov 2019 01:15:00 GMT

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

Kurt Young commented on FLINK-14784:
------------------------------------

[~Leonard Xu] Thanks for reporting and fixing this bug, I will take a look shortly. 

> CsvTableSink miss delimiter when row start with null member
> -----------------------------------------------------------
>
>                 Key: FLINK-14784
>                 URL: https://issues.apache.org/jira/browse/FLINK-14784
>             Project: Flink
>          Issue Type: Bug
>          Components: Table SQL / API
>    Affects Versions: 1.9.1
>            Reporter: Leonard Xu
>            Assignee: Leonard Xu
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 1.10.0
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> {code:java}
> //
> public String map(Row row) {
>    StringBuilder builder = new StringBuilder();
>    Object o;
>    for (int i = 0; i < row.getArity(); i++) {
>       if (builder.length() != 0) {
>          builder.append(fieldDelim);
>       }
>       if ((o = row.getField(i)) != null) {
>          builder.append(o);
>       }
>    }
>    return builder.toString();
> }{code}
> when row start with null member,  result string  will miss delimiter.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Mime
View raw message