summaryrefslogtreecommitdiffstats
path: root/Bugzilla/DB/Schema/Mysql.pm
diff options
context:
space:
mode:
Diffstat (limited to 'Bugzilla/DB/Schema/Mysql.pm')
-rw-r--r--Bugzilla/DB/Schema/Mysql.pm13
1 files changed, 12 insertions, 1 deletions
diff --git a/Bugzilla/DB/Schema/Mysql.pm b/Bugzilla/DB/Schema/Mysql.pm
index dff626097..fa6e2d5ba 100644
--- a/Bugzilla/DB/Schema/Mysql.pm
+++ b/Bugzilla/DB/Schema/Mysql.pm
@@ -96,5 +96,16 @@ sub _get_create_index_ddl {
return($sql);
} #eosub--_get_create_index_ddl
-#------------------------------------------------------------------------------
+#--------------------------------------------------------------------
+
+# MySQL has a simpler ALTER TABLE syntax than ANSI.
+sub get_alter_column_ddl {
+
+ my ($self, $table, $column, $new_def) = @_;
+
+ my $new_ddl = $self->get_type_ddl($new_def);
+
+ return (("ALTER TABLE $table CHANGE COLUMN $column $column $new_ddl"));
+}
+
1;