Check SQL reserved words by DB
Search for the keyword and check its reserved status, use, meaning, and quotation examples in the target DB.
Open SQL reserved words/keywords listConclusion: Search short common names by DB before adopting them
Do not treat order, group, user, and key as universally usable or unusable; check the classification for the target DB. For new designs, consider specific names such as display_order, user_group, user_account, and record_key.
Compound names do not completely prevent future additions of reserved words.
Examples of identifiers with the same name as keywords
CREATE TABLE sample (
order INTEGER,
group VARCHAR(30),
user VARCHAR(50),
key VARCHAR(50)
);
The Parser may read an Identifier as an SQL grammar Keyword.
Do not treat four terms as equivalent.
Compare classifications by word and by DB.
| Account to check | Confirmation details | judgment |
|---|---|---|
| order/group | Syntax keywords | Prioritize Rename. |
| user | Database and context differences | Check in the target database |
| key | Handling of MySQL and similar systems | Also check the Version |
Make naming more specific.
- Change order to display_order or sort_order.
- Change group to user_group or permission_group.
- Make generic names specific, such as user to user_account and key to external_key.
Steps to use the list to isolate conflicts
- Extract Identifiers such as Table names, Column names, and Aliases from around the Error position.
- Select the DB in use, search for the target term, and check its reserved status and quoting examples.
- List source and destination classifications when comparing databases.
- Rename new schemas to names that indicate their purpose, and compare quotes and impact scope for existing schemas.
- Run DDL, queries, and ORM-generated SQL against the real database, and verify them with the target version.
Read by distinguishing reserved words, keywords, and unsupported items
| Display | meaning | Judgment as an identifier |
|---|---|---|
| Reserved word | Reserved with special meaning in SQL grammar | Avoid unquoted usage and prioritize renaming |
| Context-dependent | It has special meaning depending on its syntactic position | Check the usage context and generated SQL |
| Non-reserved keyword | A keyword, but normally usable as an identifier | Be mindful of future version differences and portability |
| Not applicable | Comparison results not treated as keywords in the recorded database | This does not guarantee future safety |
Do not conclude "it is prohibited because it is a keyword" or "it is absolutely safe because it is not on the list." Check reservation status, usage context, version, and the destination database separately.
Do not confuse identifier quotes with string quotes
| DB | Identifier examples | Additional information |
|---|---|---|
| MySQL | `order` | When ANSI_QUOTES is enabled, the meaning of double quotes changes. |
| PostgreSQL | "order" | Quoted Identifiers preserve case. |
| SQL Server | [order] | For double quotation marks, also check the QUOTED_IDENTIFIER setting |
| Oracle | "order" | Consider case sensitivity and always-quoted Quoted Identifiers. |
SELECT "display_order" FROM "purchase_order";
-- 'display_order' is a string Literal, not an Identifier Quote
Quote is effective as a temporary compatibility measure for an existing Schema, but it leaves costs for readability, ORM settings, case sensitivity, and DB migration. For a new design, first consider Rename to a clear non-reserved word.
What you can check with the current SQL reserved words and keywords list
| Item | Current support | Boundaries and precautions |
|---|---|---|
| Database and version | SQL:2023, Oracle 21c, PostgreSQL 18, MySQL 8.0, SQL Server 2025 (17.x), SQLite 3.x | Switching to arbitrary versions and displaying version differences are not supported. |
| search | Partial matches on words, meanings, and categories; case-insensitive search | Exact-match-only mode, regular expressions, and batch schema scanning are unsupported |
| Category | Reserved words, context-dependent keywords, non-reserved keywords, and unsupported items | Does not fully reproduce every Context classification in official PostgreSQL tables. |
| comparison | Select one word and compare classifications and quoting examples for two databases. | Comparison of all DB matrices and histories of additions, deletions, and reservations is not supported |
| Identifiers | Check one name and copy database-specific quoting examples. | Do not perform DDL parsing, ORM SQL parsing, or rename execution |
| Privacy | Process searches and identifier checks in the browser | There is no feature to save or send input DDL or schemas. |
The list is a starting point for checking. Also perform final verification using official documentation and a test environment that support the edition, version, SQL mode, and session settings of the database you actually use.
Related tools and primary sources
- Check syntax and Tokens with SQL Formatter
- Check SQLite Schema with SQL DB Viewer
- Replace sensitive information before sharing with the SQL masking tool
- Compare before and after an upgrade with text diff comparison
- MySQL 8.0 Reference Manual: Keywords and Reserved Words
- PostgreSQL 18: SQL Key Words
- Microsoft Learn: Reserved Keywords (Transact-SQL)
- Oracle Database 21c: Reserved Words and Keywords
- SQLite: SQL Keywords
Reserved word data was checked against the official documentation for the versions listed above on 2026-08-03. After a DB update, prioritize the latest official list.
Replace generic names with business-specific meanings.
Names that reveal their purpose make SQL reviews easier.
After changes, check not only DDL but also whether the same name is handled correctly in actual queries, ORM-generated SQL, and the destination database.
- Search candidate terms as a list
- Also compare in the migration target DB
- Create Rename candidates
- Test the migration
Evaluate clarity of meaning as well as avoidance of reserved words.
Frequently asked questions
- Is a word safe if it is not on the list?
- Cannot guarantee. Consider Version, extensions, context-dependent words, and reserved words added in the future, and also check official documentation and the actual DB.
- Does quoting always solve it?
- Even if syntactically usable, issues with case sensitivity, ORM, migration, and maintenance remain. For new designs, prioritize Rename as a candidate.
- Can Schemas be inspected in bulk?
- The current Tool is a list for searching and comparing one word at a time. It has no automatic DDL or Schema scanning.