Mysql generate changelog issues

Description

From http://liquibase.org/forum/index.php?topic=747.0

1) enums
generateChangeLog gives unquoted string in defaultValue:
<column defaultValue="Off" name="toggledOn" type="enum('On','Off')">
which causes syntax err during update, should be
<column defaultValue="'Off'" name="toggledOn" type="enum('On','Off')">

2) composite indexes
generateChangeLog does not preserve column order is composite indexes
columns go in alphabetical order

Environment

None

Activity

Show:
Dan Carleton
April 18, 2011, 9:42 PM
Edited

We ran into the issues with enums, and I believe the following patch fixes them. Basically enum default values need to be quoted, and a null default value is indicated by the string "null".

Dan Carleton
April 18, 2011, 9:58 PM

Hmm, actually I thought I had this but it's not quite right. I'll post another patch soon.

Dan Carleton
April 18, 2011, 11:36 PM

Ok, here's a proper patch for the enum issue:

Nathan Voxland
July 27, 2011, 5:39 AM

Applied your patch, thank you very much

Reporter

Nathan Voxland

Fix versions

Priority

Major
Configure