I'm trying to use csvsimple to make a table with a tab-delimited input file.
Here is an tab-separated file generic.tsv to put into a table (these are tabs in my file, not spaces, although StackExchange seems to convert them):
r1c1 r1c2 r1c3
r2c1 r2c2 r2c3
r3c1 r3c2 r3c3
Here is an example tex file to read it in:
\documentclass{article}
\usepackage{csvsimple}
\begin{document}
\begin{tabular}{|l|l|l|}
\hline
Col 1 & Col 2 & Col 3 \\
\hline
\csvreader[no head,
late after line=\\\hline,
separator=tab
]{generic.tsv}{}{\csvcoli & \csvcolii & \csvcoliii}
\end{tabular}
\end{document}
Running this, I get the following:
This is not what I was expecting. If I change the input file to replace the tabs with commas (and get rid of separator=tab in the tex file), then it works as expected:
What can I do to get this to work with a tab-delimited file?


