1001Ferramentas
Converters

CSV ↔ PSV Converter

Convert CSV (comma-separated) files to PSV (pipe-separated |) and vice versa, with quote and newline handling.

Saída:

CSV to PSV, when the comma gets in the way

PSV is CSV with a pipe in place of the comma. It exists for a practical reason: text data is full of commas — addresses, descriptions, decimal values in many locales — and each one forces the field into quotes. Switching the separator to a character that almost never appears in content makes the file far more readable and cuts the chance of an import going wrong.

The page converts both ways, so it serves both for producing the pipe-separated file and for bringing back a PSV received from another system. The reader understands the full CSV rules, so a quoted field containing a comma is read as one value, doubled quotes become a literal quote, and a line break inside a quoted field does not split the record. On output, a field is only quoted when it contains the new separator, a quote or a line break — which in practice leaves almost everything unquoted.

PSV turns up regularly in banking and ERP integrations, and in mainframe exports, where the pipe is a long-standing convention. Keep in mind there is no formal specification for the format: the agreement about quoting and escaping varies from system to system, so confirm with the destination documentation whether it expects quotes in any particular case.

Frequently asked questions

Why not use a semicolon?
It is the most common alternative in several locales, not least because Excel expects it by default there. The pipe wins on one count: semicolons still appear in running text, especially in technical descriptions, while the pipe practically never does.
Does Excel open PSV?
Not directly on a double click. You have to import through the data wizard and choose the pipe as the delimiter, or rename the file to .txt, which makes Excel open the wizard automatically.
What if the content contains a pipe?
Then the field comes out quoted, exactly as CSV does with the comma. The rule does not disappear when the separator changes — it simply gets triggered far less often, which is the point of the format.

Related Tools