Bug #20397 Partitions: crash if alter engine
Submitted: 12 Jun 2006 14:35 Modified: 20 Jun 2006 7:16
Reporter: Peter Gulutzan Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Partitions Severity:S3 (Non-critical)
Version:5.1.12-beta-debug OS:Linux (SUSE 10.0)
Assigned to: Mikael Ronström CPU Architecture:Any

[12 Jun 2006 14:35] Peter Gulutzan
Description:
I create a partitioned table.
I try to alter to a nonexistent engine.
Crash.

How to repeat:
mysql> create table t (s1 int) partition by list (s1) (partition p1 values in (1));
Query OK, 0 rows affected (0.00 sec)

mysql> alter table t engine = x;
ERROR 2013 (HY000): Lost connection to MySQL server during query
[13 Jun 2006 12:38] Mikael Ronström
Peter, I always get amazed by your skill in finding bugs.
Should be a simple fix.
[13 Jun 2006 21:20] Mikael Ronström
Choose to treat
ALTER TABLE t1 ENGINE = X;
as if
ALTER TABLE t1;
had been the command
So no reason why a switch to a new storage engine should happen when the
command was in error.
[15 Jun 2006 16:29] Mikael Ronström
Patch will appear in 5.1.12
[20 Jun 2006 7:16] Jon Stephens
Thank you for your bug report. This issue has been committed to our
source repository of that product and will be incorporated into the
next release.

If necessary, you can access the source repository and build the latest
available version, including the bugfix, yourself. More information 
about accessing the source trees is available at
    http://www.mysql.com/doc/en/Installing_source_tree.html

Additional info:

Documented bugfix in 5.1.12 changelog; closed.