MySQL

The world's most popular open source database

Contact a MySQL Representative


  • MySQL.com
  • Developer Zone
  • Partners & Solutions
  • Customer Login
  • DevZone
  • Downloads
  • Documentation
  • Articles
  • Forums
  • Bugs
  • Forge
  • Blogs
 
  • Pages

    • About
  • Archives

    • December 2008
    • November 2008
    • October 2008
    • August 2008
    • July 2008
    • June 2008
    • May 2008
    • April 2008
  • Categories

    • MySQL 5.1 Features (2)
    • MySQL 6.0 New Features (4)
    • MySQL 6.x New Features (1)
    • News (6)
    • Personal Opinion (4)
    • Tiny Tweaks (10)



New Features In MySQL 6.x

« The Roadmap
Tiny Tweak: BINARY and VARBINARY »

Tiny Tweak: Future Reserved Words

Suppose you create a table like this:
CREATE TABLE t (current_role INT);
It works in MySQL 5.1. But it might fail in MySQL 7.0.

The problem is that CURRENT_ROLE might be a reserved word if we implement “Roles” as described in the worklog task description
Roles and the warning is right there in the description: “CURRENT_ROLE is a new reserved word”. The task description might change before we implement it, and your application might change too, after all MySQL 7.0 alpha is far from imminent. But if you have an inkling of our plans for reserved words later, maybe you’ll want to avoid using them now.

These words are marked as “possibly reserved” in some future version:
ARRAY AUDIT BOOLEAN CIDR CONNECT CUBE CURRENT CURRENT_CATALOG CURRENT_PATH CURRENT_ROLE CYCLE DEFAULT DENSE_RANK EXCEPT FOR GET INET INTERSECT MACADDR MERGE NEW NONE OLD OVER PARTITION RANK RESIGNAL ROWNUM ROWNUM ROW_NUMBER ROWS SESSION_USER SIGNAL START SOME SYSTEM_USER TRUNC UNKNOWN WINDOW

A longer list, including words that are in standard SQL or other vendors’ products, can be found in the article SQL Naming Conventions.

This entry was posted on Monday, May 19th, 2008 at 12:38 am and is filed under Tiny Tweaks. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

Leave a Reply

New Features In MySQL 6.x is proudly powered by WordPress MU running on Blogs.mysql.com.
Entries (RSS) and Comments (RSS).