TSV to XLSX — why tab-separated exports are safer than CSV
Analytics pipelines prefer .tsv because a tab rarely appears inside a log line. That removes most quoting rules, and the conversion into a worksheet becomes a clean mapping of fields to cells. The trade-off is that the workbook inherits the same flatness: no types, no formatting, no formulas.
Cell formatting, colours, column widths and merged ranges are dropped; only stored values survive.
Processed on your device. Files aren’t sent anywhere.
One delimiter, fewer conventions
Before blaming the workbook, look at the original export in an editor that can reveal tab characters. A visually aligned report may contain spaces instead. The route expects actual tab separators; adding a workbook container cannot identify columns from the way a document happened to look on screen. Keep a small representative source alongside the result when handing the import to someone else.
- A tab separates fields; there is no quoting layer to honour.
- A comma inside a value is just a character and needs no escaping.
- A quote character inside a value is stored literally, not doubled.
- Consecutive tabs mean empty fields, which become empty cells.
- A trailing tab at the end of a line produces a blank cell that is trimmed.
Questions
Is a tab-delimited file safer than CSV?
Does the converter detect dates?
Can I get several sheets from one TSV?
What if the file has comment lines?
From fields to cells
| TSV field | Worksheet cell | Note |
|---|---|---|
| Widget, 3, plain (tab-separated) | three cells | positions preserved |
| a, empty, b (two adjacent tabs) | a, empty, b | interior blank kept |
| value with , comma | one cell | no quoting needed |
| trailing tab | trimmed | used range ends at data |
Where the sheet name comes from
A delimited file has no sheet names, so the workbook gets a generic one. With every-sheet selected, only one sheet appears, because there is nothing to split: the file is a single table. Multi-sheet output is a spreadsheet-to-spreadsheet feature, not a CSV or TSV feature.
Numbers, dates and blanks
A database dump usually carries ISO dates and integer columns. The converter writes them as text because the source has no type metadata, so Excel treats them as text until you convert the column. Empty cells stay empty inside a row; dropping an interior blank would shift every later column one position left.
Verifying the result
Compare three numbers: the line count of the source, the row count in the report, and the row count Excel shows. They should agree. Then open one long text field and confirm it did not split.
When a TSV is not a table
If the export has preamble lines, remove them before converting; otherwise they become worksheet rows and every later column header is wrong.
A log file with a delimiter is not a table. It may have comment lines, repeated headers or a trailing summary row, and a converter cannot tell those apart from data.
Practical note for pipeline exports
Limits worth knowing
- Convert the .tsv file and download the .xlsx.
- Check the row count against the source line count.
- Convert numeric and date columns inside Excel.
- Rename the sheet if the generic name matters.