List Formatter
Turns lines into a comma list, quoted SQL IN clause, JSON array or bullet list, and back again.
Turns a column of values into a SQL IN clause, a JSON array, a quoted list or a bullet list — and takes any of those apart back into lines. The apostrophe handling is the part that matters: O’Brien becomes ’O’’Brien’, which is the SQL standard’s own escape.
Input
Format
Result
values
4
characters out
49
How to use it
Pick the direction
Lines to a list, or a list back to lines. The second reads a JSON array, a SQL IN clause, a quoted list or a delimited one, and says which it detected.
Choose the output shape
The list shows each format by example — a,b or "a", "b" — so you pick by looking rather than by name. Custom lets you set the prefix, suffix and separator yourself.
Check the count
The value count is the sanity check. If it is one short of what you expected, a blank line was dropped or a quoted value swallowed a comma.
Common questions
Why is the apostrophe doubled?
Because that is how SQL escapes it — ’O’’Brien’ is the standard, and it works in every database. Backslash-escaping works only in MySQL, and using it is the usual way a generated IN clause breaks somewhere else.
A value with a comma in it split into two
Only if it was unquoted. Reading a list back, quoted values keep their commas: a, "b, c" is two values, not three. Quote the value in the source and it survives.
Is there a limit on the number of values?
Not here, but there is where you are pasting it. Oracle caps an IN list at 1,000 entries and other databases have their own limits; past a few hundred a temporary table or a join is the better shape anyway.
Feed it from
Duplicate Line Remover
Removes duplicate lines, keeps only duplicates, or counts how many times each line appeared.
Line Sorter & Shuffler
Sorts lines alphabetically, numerically, by length or randomly, with reverse and case options.
Line Numbering
Adds or removes leading line numbers with a start value, step, padding and separator.
Text Splitter
Splits a long text into chunks by line count, character budget or a delimiter, keeping sentences whole.
Next
These accept what this tool produces, so the result can go straight in.
CSV to SQL
Generates CREATE TABLE and INSERT statements from a table, with inferred types and a chosen dialect.
JSON Formatter & Validator
Pretty-prints, minifies and validates JSON, pointing at the exact line and column of a syntax error.
Duplicate Line Remover
Removes duplicate lines, keeps only duplicates, or counts how many times each line appeared.
Line Sorter & Shuffler
Sorts lines alphabetically, numerically, by length or randomly, with reverse and case options.
Find & Replace
Replaces text by literal, whole word or regular expression, with capture groups and a preview of every hit.
Markdown Editor
Edits Markdown with a live preview and exports the rendered HTML, with GFM tables and task lists.