Convert comma separated .CSV text files to plain tab separated text with the free Swiss File Knife for Windows, Mac OS X and Linux.
sfk csvtotab infile.csv [options]
convert csv data to plain tab separated.
default input/output format
- input fields are separated by a comma ","
- input fields can be surrounded by double quotes "
and may contain escaped double quotes as ""
- output fields are separated by TAB characters
- surrounding quotes are stripped, and escaped
quotes are reduced to normal quotes
- if input contains any TABs they are changed to
a single blank character
- input fields cannot contain line breaks
options
-tofile x write output to file x
-insep="x" set input separator to character x
e.g. ; or \t
-outsep="x" change output separator
-quote="x" change quote character, e.g. \x27
uses single quote.
-tabrep="x" change tab replacement character
see alsosfk ascii list of ASCII codes for characters
sfk tabtocsv further conversion examples
web referencehttp://stahlworks.com/sfk-csvtotabexamplessfk csvtotab in.csv -tofile out.txt
convert to tab separated out.txt
sfk filter in.csv -+foo +csvtotab
convert only lines with word "foo"
sfk csvtotab in.csv +filter "-![warning]"
drop all lines with [warning] from output
sfk csvtotab in.csv +view -tab 10
view in.csv in Depeche View for convenient browse
and search of contents, with a tab size of 10.
Within DView press Ctrl+Tab to change tab size
in small steps, or Ctrl+Shift+Tab for large tabs.