Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Commas inside quotes sometimes not ignored #42

Open
BorisVSchmid opened this issue Aug 15, 2018 · 0 comments
Open

Commas inside quotes sometimes not ignored #42

BorisVSchmid opened this issue Aug 15, 2018 · 0 comments

Comments

@BorisVSchmid
Copy link

BorisVSchmid commented Aug 15, 2018

Issue #36 is closed, saying that commas inside quotes are ignored, but in the below example that is not always the case.

Only difference between the three lines below is no space, a space after the first, or a space after the second comma.

(->> "1367-1369,\"[Bailliages of Arras, Avesnes, Aubigny and Quiéry]\",[Artois],"
    (csv/parse-csv))

(->> "1367-1369, \"[Bailliages of Arras, Avesnes, Aubigny and Quiéry]\",[Artois],"
    (csv/parse-csv))

(->> "1367-1369,\"[Bailliages of Arras, Avesnes, Aubigny and Quiéry]\" ,[Artois],"
    (csv/parse-csv))

The first line produces the expected results.

(["1367-1369" "[Bailliages of Arras, Avesnes, Aubigny and Quiéry]" "[Artois]" ""])

But the other two lines seems to have issues. Either some overzealous splitting that didn't respect the double-quoted string, or just swallowing a whole entry.

(["1367-1369" " \"[Bailliages of Arras" " Avesnes" " Aubigny and Quiéry]\"" "[Artois]" ""])

(["1367-1369" " " "[Artois]" ""])

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant