Skip to content
This repository has been archived by the owner on Jun 8, 2018. It is now read-only.

NewSQLStructure

Trevor Slocum edited this page Sep 17, 2015 · 9 revisions

To finish upgrading your board, execute the following on your MySQL database. Start from the top, skipping any inapplicable updates based on how outdated your TinyIB installation was.

Note: Your posts table will most likely be named something other than board_posts! Replace the example table names with their actual names before executing.

16 Oct 2014

ALTER TABLE `board_posts` ADD `moderated` TINYINT( 1 ) NOT NULL DEFAULT '1';
ALTER TABLE `board_posts` ADD INDEX (`moderated`);

7th Aug 2015

ALTER TABLE `board_posts` CHANGE `file` `file` TEXT;

21 Aug 2015

ALTER TABLE `board_posts` ADD `stickied` TINYINT( 1 ) NOT NULL DEFAULT '0',
ALTER TABLE `board_posts` ADD INDEX (`stickied`);

15th Sep 2015

ALTER TABLE `board_posts` CHANGE `ip` `ip` VARCHAR(39) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, CHANGE `name` `name` VARCHAR(75) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, CHANGE `tripcode` `tripcode` VARCHAR(10) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, CHANGE `email` `email` VARCHAR(75) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, CHANGE `nameblock` `nameblock` VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, CHANGE `subject` `subject` VARCHAR(75) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, CHANGE `message` `message` TEXT CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, CHANGE `password` `password` VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, CHANGE `file` `file` TEXT CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, CHANGE `file_hex` `file_hex` VARCHAR(75) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, CHANGE `file_original` `file_original` VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, CHANGE `file_size_formatted` `file_size_formatted` VARCHAR(75) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, CHANGE `thumb` `thumb` VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL;
ALTER TABLE `bans` CHANGE `ip` `ip` VARCHAR(39) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL, CHANGE `reason` `reason` TEXT CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL;
Clone this wiki locally