Skip to content

Bug in CSV encoding strings with doble quotes at the beginning #4

@relonger

Description

@relonger

If you try to insert_rows with string value like:

''The String'' with continuation

(there is 2 single quotes there)
Default Ruby CSV gem encode this string without " quotes, because there isn't any characters required to be encoded. But Clickhouse consider this 2 single quotes as field quotation mark and trigger an error: "comma required before with continuation"

Now there is no way to change CSV generation mode without patching the gem. (Adding :force_quote=>true solves the problem). So the problem is quite unpleasant. Probable you should add CSV options to insert_rows() arguments.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions