Comma to Column Converter
Convert comma-separated values to a column list instantly. Supports custom delimiters, deduplication, sorting, and reverse column-to-comma conversion.
About
Comma-delimited strings are the default interchange format for spreadsheets, log files, and API query parameters. Manually splitting them into one-item-per-line columns introduces transcription errors and wastes time that compounds across hundreds of records. This tool parses an input string by a configurable delimiter (comma , by default), trims surrounding whitespace from each token, and outputs a vertical column. It also handles edge cases: consecutive delimiters producing empty tokens, trailing delimiters, and mixed whitespace. The reverse operation - column back to comma string - is equally supported. Optional deduplication uses a hash-set pass in O(n) time, and lexicographic sorting follows the Unicode default collation. Note: the tool treats the delimiter literally; regular-expression patterns are not supported to avoid ReDoS vectors in user-supplied input.
Formulas
The conversion is a deterministic string-split operation. Given an input string S and a delimiter character d, the output column C is defined as:
Where split(S, d) produces an array of n tokens, trim removes leading and trailing whitespace from each token, and join concatenates them with a newline character. When deduplication is enabled, a Set filter is applied before joining, reducing the array to unique elements in O(n) average time. The reverse operation inverts the axes: split by newline, join by d.
Where S = input string, d = delimiter character, C = output column, n = number of resulting tokens.
Reference Data
| Delimiter | Symbol | Common Use Case | Unicode Codepoint | Escape Sequence |
|---|---|---|---|---|
| Comma | , | CSV files, SQL IN clauses, email lists | U+002C | None |
| Semicolon | ; | European CSV, Outlook contacts | U+003B | None |
| Pipe | | | Unix pipelines, database exports | U+007C | None |
| Tab | \t | TSV files, spreadsheet paste | U+0009 | \t |
| Space | Shell arguments, word splitting | U+0020 | None | |
| Colon | : | PATH variable, /etc/passwd | U+003A | None |
| Newline (LF) | \n | Unix line endings | U+000A | \n |
| Newline (CRLF) | \r\n | Windows line endings | U+000D + U+000A | \r\n |
| Tilde | ~ | Legacy mainframe exports | U+007E | None |
| Caret | ^ | Windows CMD escape delimiter | U+005E | None |
| Slash | / | URL path segments, file paths | U+002F | None |
| Backslash | \ | Windows file paths | U+005C | \\ |
| Ampersand | & | URL query parameters | U+0026 | & |
| Hash | # | Color codes, Markdown headings | U+0023 | None |
| Double Quote | " | JSON string boundaries | U+0022 | \" |