Fixed delvote_ips bug with MySQL 5.0.45 - see http://forum.enanocms.org/viewtopic.php?f=5&t=8
authorDan
Fri, 17 Aug 2007 12:35:29 -0400
changeset 94 8fc958168261
parent 93 95c4d91bd954
child 95 1dac77b46f07
Fixed delvote_ips bug with MySQL 5.0.45 - see http://forum.enanocms.org/viewtopic.php?f=5&t=8
schema.sql
upgrade.sql
--- a/schema.sql	Thu Aug 16 20:35:49 2007 -0400
+++ b/schema.sql	Fri Aug 17 12:35:29 2007 -0400
@@ -67,7 +67,7 @@
   wiki_mode tinyint(1) NOT NULL DEFAULT 2,
   delvotes int(10) NOT NULL default 0,
   password varchar(40) NOT NULL DEFAULT '',
-  delvote_ips text NOT NULL
+  delvote_ips text NOT NULL DEFAULT ''
 ) CHARACTER SET `utf8`;
 
 CREATE TABLE {{TABLE_PREFIX}}session_keys(
--- a/upgrade.sql	Thu Aug 16 20:35:49 2007 -0400
+++ b/upgrade.sql	Fri Aug 17 12:35:29 2007 -0400
@@ -5,6 +5,8 @@
 DELETE FROM {{TABLE_PREFIX}}config WHERE config_name='enano_version' OR config_name='enano_beta_version' OR config_name='enano_alpha_version' OR config_name='enano_rc_version';
 INSERT INTO {{TABLE_PREFIX}}config (config_name, config_value) VALUES( 'enano_version', '1.0.1' );
 ---BEGIN 1.0---
+-- Bugfix for MySQL 5.0.45, see http://forum.enanocms.org/viewtopic.php?f=5&t=8
+ALTER TABLE {{TABLE_PREFIX}}pages MODIFY COLUMN delvote_ips text NOT NULL DEFAULT '';
 CREATE TABLE {{TABLE_PREFIX}}page_groups( pg_id mediumint(8) NOT NULL auto_increment, pg_type tinyint(2) NOT NULL DEFAULT 1, pg_name varchar(255) NOT NULL DEFAULT '', pg_target varchar(255) DEFAULT NULL, PRIMARY KEY ( pg_id ) ) CHARACTER SET `utf8` COLLATE `utf8_bin`;
 CREATE TABLE {{TABLE_PREFIX}}page_group_members( pg_member_id int(12) NOT NULL auto_increment, pg_id mediumint(8) NOT NULL, page_id varchar(63) NOT NULL, namespace varchar(63) NOT NULL DEFAULT 'Article', PRIMARY KEY ( pg_member_id ) ) CHARACTER SET `utf8` COLLATE `utf8_bin`;
 CREATE TABLE {{TABLE_PREFIX}}tags( tag_id int(12) NOT NULL auto_increment, tag_name varchar(63) NOT NULL DEFAULT 'bla', page_id varchar(255) NOT NULL, namespace varchar(255) NOT NULL, user mediumint(8) NOT NULL DEFAULT 1, PRIMARY KEY ( tag_id ) ) CHARACTER SET `utf8` COLLATE `utf8_bin`;