Permalink
Browse files

never upgraded choice tables to six choices!

  • Loading branch information...
1 parent 6673b08 commit 23877f9407888fd26cc2648c895e327596525cf5 moodler committed Oct 24, 2002
Showing with 7 additions and 1 deletion.
  1. +6 −0 mod/choice/db/mysql.php
  2. +1 −1 mod/choice/version.php
@@ -8,6 +8,12 @@ function choice_upgrade($oldversion) {
execute_sql(" ALTER TABLE `choice` CHANGE `answer1` `answer1` VARCHAR( 255 )");
execute_sql(" ALTER TABLE `choice` CHANGE `answer2` `answer2` VARCHAR( 255 )");
}
+ if ($oldversion < 2002102400) {
+ execute_sql(" ALTER TABLE `choice` ADD `answer3` varchar(255) NOT NULL AFTER `answer2`");
+ execute_sql(" ALTER TABLE `choice` ADD `answer4` varchar(255) NOT NULL AFTER `answer3`");
+ execute_sql(" ALTER TABLE `choice` ADD `answer5` varchar(255) NOT NULL AFTER `answer4`");
+ execute_sql(" ALTER TABLE `choice` ADD `answer6` varchar(255) NOT NULL AFTER `answer5`");
+ }
return true;
}
@@ -5,7 +5,7 @@
// This fragment is called by /admin/index.php
////////////////////////////////////////////////////////////////////////////////
-$module->version = 2002090800;
+$module->version = 2002102400;
$module->cron = 0;
?>

0 comments on commit 23877f9

Please sign in to comment.