Getting a readable table out of a CSV export
A CSV file is a table with the lines taken out: one row per line, with commas, semicolons or tabs between the values. Opened in a text editor it is hard to read and printed from one it is worse. Set as a PDF, the values go back into columns, the header row is repeated at the top of every page, and the result can be attached, printed or archived as it is.
Updated
Which tool you need
A statement or transactions exported from a bank
CSV to PDF reads the export as it is. A file from a European bank often uses semicolons, which the separator detection handles without being told.
A spreadsheet with a dozen or more columns
Choose landscape and a narrow margin before anything else. If the columns are still cramped, a smaller text size gives each one more room.
The first line of the file is data, not column names
Turn off First row is the header, so the first row is set like the others and nothing repeats at the top of each page.
Several CSV files that should end up in one PDF
Convert each one, then join the PDFs with Merge PDF in the order you want them.
What the table does with your values
Each column is as wide as its longest values allow, within the page. A long value wraps onto a second line inside its own cell rather than pushing the table off the edge, and a column that holds only numbers is right-aligned, so the units line up for reading down.
Values are set exactly as the file has them. Nothing is calculated, rounded or reformatted, so a date or an amount looks the way the program that exported it wrote it.
The header row, and the shading between rows
The header sits on a shaded band in bold, and every other row of the body is lightly shaded, so a long row can be followed across the page by eye. The header repeats at the top of each page only while it takes no more than a third of the page; a header of many long column names, wrapped tall in narrow columns, is set once at the start instead, so every page still has room for rows.
With the font set to Monospaced, every digit is the same width, so a right-aligned column of amounts with the same number of decimals lines up place by place.
How large an export it will take
The file can be up to 20 MB, with up to 1,048,576 rows, the same ceiling a spreadsheet has, and up to 2,048 columns. A file with more columns than that is refused with its column count named, before anything is set.
For a long export, the page count is usually what stops it first: one PDF here holds at most 10,000 pages, which at the starting text size is reached well before a million rows.
What to know before you start
- A very wide table is narrowed to fit the page, which can make small columns hard to read.
- Formulas, colors and formatting from a spreadsheet are not part of a CSV and cannot appear.
- A value in a script above the chosen Fonts level, or an emoji, prints as a replacement mark.
- More than 2,048 columns, or a table that would run past 10,000 pages, is refused rather than cut short.