-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
I would like to read a TSV file using the datafusion-cli. However, when specifying \t as the delimiter I get the error: 🤔 Invalid statement: sql parser error: Delimiter must be a single char
To Reproduce
In bash:
echo "col1\tcol2" > test.tsv
echo "1\t2" >> test.tsv
then in datafusion-cli:
create external table test stored as csv location 'test.tsv' delimiter '\t';
Expected behavior
External table creates successfully with a tab as the delimiter.
Additional context
It seems the problem is that rustyline treats the '\t' as two separate characters. I wouldn't mind having a go at fixing it myself, e.g. by updating the line from rustyline before passing to datafusion. If this is the way to do it, should all instances of \ in a given line be treated as escaped values, or only in the delimiter itself?
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working