Browse Source

! And adding the description to existing installs. MySQL should work fine, the others I have no way to test.

Signed-off-by: Peter Spicer <[email protected]>
Peter Spicer 11 years ago
parent
commit
40c9aaf46c
3 changed files with 37 additions and 0 deletions
  1. 8 0
      other/upgrade_2-1_mysql.sql
  2. 11 0
      other/upgrade_2-1_postgresql.sql
  3. 18 0
      other/upgrade_2-1_sqlite.sql

+ 8 - 0
other/upgrade_2-1_mysql.sql

@@ -234,6 +234,14 @@ ALTER TABLE {$db_prefix}boards
 ADD COLUMN deny_member_groups varchar(255) NOT NULL DEFAULT '';
 ---#
 
+/******************************************************************************/
+--- Adding support for category descriptions
+/******************************************************************************/
+---# Adding new columns to categories...
+ALTER TABLE {$db_prefix}categories
+ADD COLUMN description text NOT NULL;
+---#
+
 /******************************************************************************/
 --- Adding support for topic unwatch
 /******************************************************************************/

+ 11 - 0
other/upgrade_2-1_postgresql.sql

@@ -295,6 +295,17 @@ upgrade_query("
 ---}
 ---#
 
+/******************************************************************************/
+--- Adding support for category descriptions
+/******************************************************************************/
+---# Adding new columns to categories...
+---{
+upgrade_query("
+	ALTER TABLE {$db_prefix}categories
+	ADD COLUMN description text NOT NULL;");
+---}
+---#
+
 /******************************************************************************/
 --- Adding support for topic unwatch
 /******************************************************************************/

+ 18 - 0
other/upgrade_2-1_sqlite.sql

@@ -267,6 +267,24 @@ $smcFunc['db_alter_table']('{db_prefix}boards', array(
 ---}
 ---#
 
+/******************************************************************************/
+--- Adding support for category descriptions
+/******************************************************************************/
+---# Adding new columns to categories...
+---{
+$smcFunc['db_alter_table']('{db_prefix}log_topics', array(
+	'add' => array(
+		'description' => array(
+			'name' => 'description',
+			'null' => false,
+			'type' => 'text',
+			'auto' => false,
+		),
+	)
+));
+---}
+---#
+
 /******************************************************************************/
 --- Adding support for topic unwatch
 /******************************************************************************/