You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Dario Röthlisberger (Jira)" <ji...@apache.org> on 2020/12/03 16:21:00 UTC

[jira] [Created] (CAMEL-15920) Cannot parse CSV if the last (not required) field is empty when using a tab separator

Dario Röthlisberger created CAMEL-15920:
-------------------------------------------

             Summary: Cannot parse CSV if the last (not required) field is empty when using a tab separator
                 Key: CAMEL-15920
                 URL: https://issues.apache.org/jira/browse/CAMEL-15920
             Project: Camel
          Issue Type: Bug
          Components: camel-bindy
    Affects Versions: 3.5.0, Future
            Reporter: Dario Röthlisberger


Parsing a CSV file fails if the following conditions are met:
 * tab separator
 * last field is empty
 * not all fields are required

 

*Example 1*

CSV: "VOA\t12 abc street\tMelbourne\tVIC\t3000\tAustralia\t\t"

The last two fields are empty and the CSV *cannot be parsed.*

*Example 2*
{code:java}
CSV: "VOA\t12 abc street\tMelbourne\tVIC\t3000\tAustralia\t\tNot Empty"
{code}
The last field is not empty and the CSV *can be parsed.*

 

I've just created a test case on current master to demonstrate the bug:

[Camel-Bindy: csv cannot be parsed if (not required) last field is empty and a tab separator is used by darioxz -  Pull Request #1 -  darioxz/camel (github.com)|https://github.com/darioxz/camel/pull/1]

 



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