Trivial MySQL Variable of the Day

Today’s trivial MySQL system variable:

old_alter_table

The interesting bit is that this is a system variable, and shows up in SHOW GLOBAL VARIABLES, but is not documented on the Server System Variables manual page.

Instead, it is documented on the manual page for Server options.

Unfortunately, that documentation is very sparse. It tells us:

old-alter-table is an option that can be set in an option file (such as /etc/my.cnf)

old_alter_table is the name of the variable.

And….that’s it. It is neither a system nor status variable, there is no scope, and no entry for whether or not it is dynamic. These last 2 are baffling, though they show up in other variables in the matrix on the “server options” manual page. The scope is either session or global; there is no NULL — the scope may not be *relevant*, but it still exists.

As well, either the variable can be settable on commandline, or not. There is no meaning to a NULL value in that column.

The most egregious issue is that there is no documentation whatsoever about what the variable does. What happens if I set old_alter_table to ON?

(My guess is that it’s a placeholder for the behavior of ALTER TABLE in 5.0 and earlier, perhaps it disables the use of ALTER TABLE ONLINE? My second guess is that whatever the functionality, it is not implemented yet, similar to date_format).

Comments are closed.