| Bug #114874 | Five mistakes in information_schema.keywords.reserved in 8.4+ | ||
|---|---|---|---|
| Submitted: | 3 May 2024 20:17 | Modified: | 30 Jan 0:14 |
| Reporter: | Evan Elias | Email Updates: | |
| Status: | Verified | Impact on me: | |
| Category: | MySQL Server: Information schema | Severity: | S3 (Non-critical) |
| Version: | 8.4, 9.4, 9.5, 9.6 | OS: | Any |
| Assigned to: | CPU Architecture: | Any | |
[6 May 2024 6:04]
MySQL Verification Team
Hello Evan Elias, Thank you for the report and feedback. regards, Umesh
[23 Oct 2025 19:44]
Evan Elias
One more problem row in MySQL 9.4+: EXTERNAL is now a reserved word, but information_schema.keywords incorrectly lists it as non-reserved. mysql> select * from information_schema.keywords where word = 'external'; +----------+----------+ | WORD | RESERVED | +----------+----------+ | EXTERNAL | 0 | +----------+----------+ 1 row in set (0.004 sec) mysql> create table external (id int); ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'external (id int)' at line 1
[30 Jan 0:14]
Evan Elias
Also SETS which is a new reserved word in MySQL 9.6, but is erroneously listed as non-reserved in information_schema.keywords... this seems to keep happening with new reserved words :(

Description: In MySQL 8.4.0, four new reserved words were added to the server: MANUAL PARALLEL QUALIFY TABLESAMPLE These four are now present in information_schema.keywords, but they incorrectly have reserved=0 when it should be 1. Additionally, CUBE (a reserved word added in 8.0) is still reserved in 8.4, but information_schema.keywords incorrectly has reserved=0 for it now. How to repeat: Querying information_schema to show the incorrect data: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 11 Server version: 8.4.0 MySQL Community Server - GPL Copyright (c) 2000, 2024, Oracle and/or its affiliates. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> SELECT * FROM information_schema.keywords where word IN ('cube', 'manual', 'parallel', 'qualify', 'tablesample'); +-------------+----------+ | WORD | RESERVED | +-------------+----------+ | CUBE | 0 | | MANUAL | 0 | | PARALLEL | 0 | | QUALIFY | 0 | | TABLESAMPLE | 0 | +-------------+----------+ 5 rows in set (0.01 sec) Proof these are indeed reserved words: mysql> CREATE TABLE cube (id int); ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'cube (id int)' at line 1 mysql> CREATE TABLE manual (id int); ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'manual (id int)' at line 1 mysql> CREATE TABLE parallel (id int); ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'parallel (id int)' at line 1 mysql> CREATE TABLE qualify (id int); ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'qualify (id int)' at line 1 mysql> CREATE TABLE tablesample (id int); ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'tablesample(id int)' at line 1 Suggested fix: Please set reserved=1 for these five rows