SQL Identifier Quotes
TextEverything runs locally in your browser — nothing is uploaded
Two jobs, each matching a real situation. Adding quotes: moving MySQL-style SQL to Postgres or Oracle. MySQL identifiers are case-insensitive by default, while Postgres folds unquoted identifiers to lower case — a column called `userID` arrives as `userid` and the statement fails with “column does not exist”. Double quotes are what preserve the original casing. Removing quotes: turning Postgres’ exported `"users"` and `"userID"` back into bare identifiers, which read better and paste cleanly into older tools that choke on quotes. ⚠️ The rule that matters most: nothing inside string literals or comments is touched. A naive implementation that quotes every word turns `INSERT INTO t VALUES ('active')` into `'"active"'` — two extra quotes stored in the data, with the statement still executing perfectly, so the mistake surfaces only when someone reads the data back. A small scanner is used instead, and strings, comments and already-quoted identifiers are skipped whole. When a quote cannot be removed, it stays. `"user id"` (a space), `"order"` (a reserved word) and `"2fa"` (leading digit) are all invalid bare identifiers. The quotes are kept and the count is reported, rather than emitting SQL that cannot run.
Features
- Add double quotes to table names, column names and aliases in bulk
- Or strip existing double quotes and backticks (backticks become double quotes, which all three engines accept)
- ⚠️ Nothing inside string literals is touched, including strings using the `''` escape
- Nothing inside `--` line comments or `/* */` block comments is touched
- SQL keywords are never quoted (quoting `select` would turn it into a column name)
- Non-ASCII identifiers are quoted too, so Chinese and accented table names survive
- When removing quotes, names that cannot be written bare keep theirs, and the count is reported
- Each row is copyable, and the explanation never ends up in the copied text
How to use
- Paste a SQL statement
- Choose Add double quotes or Remove double quotes
- The result updates as you type; copy it out
FAQ
- Will the contents of string literals be changed?
- No, and that is the most important rule here. The word `active` in `INSERT INTO t VALUES ('active')` is data, not an identifier; quoting it produces `'"active"'`, and those two extra quotes really are stored in the database. Worse, the statement still executes, so the problem only shows up when the data is read back. Comments are skipped whole for the same reason.
- Why are keywords left unquoted?
- Because quoting `select` turns it from a keyword into a column name called select, and the statement immediately means something else. A built-in keyword table covers the common ones; a rare keyword that is missing from it could make the statement fail with “column does not exist”, which shows up the moment you run it — it will not silently change the meaning.
- Why do some quotes survive removal?
- Because the name would be invalid without them. Three cases: a space or special character (`"user id"` would split into two words), a reserved word (`"order"` would collide with `ORDER BY`), and a leading digit (`"2fa"` is not a valid identifier). The quotes stay and the tool tells you how many such names there were — emitting SQL that cannot run would be far worse than leaving a few quotes in place.
Related tools
Text Cleaner
TextClean up a column pasted out of a log or spreadsheet: deduplicate, sort, drop blank lines, trim whitespace and strip line numbers, all in your browser.
Case Converter
TextConvert identifiers between fourteen naming styles. Words are split correctly first, so acronyms such as HTTPServer come out right, all in your browser.
JSON Formatter
FormatFormat, validate and minify JSON in a collapsible tree with syntax highlighting and line numbers. Search, edit, delete or convert to Python dicts.
Text Diff
TextCompare two blocks of text online and highlight added, removed and unchanged lines, so only the lines that changed are marked. Runs in your browser.
Word Counter
TextCount Chinese characters and English words separately, alongside characters, lines, real UTF-8 bytes, reading and speaking time, and SMS segment counts.
Chinese Converter
TextConvert Chinese between simplified and traditional characters, leaning on common words first and the most usual form for the rest, all in your browser.