ALTER TABLE `minibbtable_forums` RENAME `forums` ; ALTER TABLE `forums` CHANGE `forum_id` `id_forum` INT( 10 ) NOT NULL AUTO_INCREMENT; ALTER TABLE `forums` CHANGE `forum_name` `name` MEDIUMTEXT NOT NULL; ALTER TABLE `forums` CHANGE `forum_desc` `rule` MEDIUMTEXT NOT NULL; ALTER TABLE `forums` ADD `logo` MEDIUMTEXT NOT NULL AFTER `rule` ; ALTER TABLE `forums` CHANGE `forum_order` `pos` INT( 10 ) NOT NULL DEFAULT '0'; ALTER TABLE `forums` DROP `forum_icon` , DROP `topics_count` , DROP `posts_count` , DROP `forum_group` ; ALTER TABLE `forums` ADD `hide` ENUM( 'show' , 'hide' ) DEFAULT 'show' NOT NULL AFTER `pos`; ALTER TABLE `minibbtable_topics` RENAME `themes` ; ALTER TABLE `themes` CHANGE `topic_id` `id_theme` INT( 10 ) NOT NULL AUTO_INCREMENT; ALTER TABLE `themes` CHANGE `topic_title` `name` TINYTEXT NOT NULL; ALTER TABLE `themes` DROP `topic_poster`; ALTER TABLE `themes` CHANGE `topic_poster_name` `author` TINYTEXT; ALTER TABLE `themes` ADD `id_author` INT NOT NULL AFTER `author` ; ALTER TABLE `themes` ADD `last_author` TINYTEXT NOT NULL AFTER `id_author` ; ALTER TABLE `themes` ADD `id_last_author ` INT NOT NULL AFTER `last_author` ; ALTER TABLE `themes` ADD `hide` ENUM( 'hide', 'show', 'lock') DEFAULT 'show' NOT NULL AFTER `id_last_author` ; ALTER TABLE `themes` CHANGE `topic_time` `time` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00' ALTER TABLE `themes` DROP `topic_views` , DROP `topic_status` , DROP `topic_last_post_id` , DROP `posts_count` , DROP `sticky` , DROP `topic_last_post_time` ; ALTER TABLE `themes` CHANGE `forum_id` `id_forum` INT( 10 ) NOT NULL DEFAULT '1'; ALTER TABLE `minibbtable_posts` RENAME `posts` ; ALTER TABLE `posts` CHANGE `post_id` `id_post` INT( 10 ) NOT NULL AUTO_INCREMENT; ALTER TABLE `posts` DROP `forum_id` ; ALTER TABLE `posts` CHANGE `topic_id` `topic_id` INT( 10 ) NOT NULL DEFAULT '1' AFTER post_status; ALTER TABLE `posts` CHANGE `post_text` `post_text` TEXT NOT NULL AFTER id_post; ALTER TABLE `posts` CHANGE `post_text` `name` TEXT NOT NULL ; ALTER TABLE `posts` ADD `url` TINYTEXT NOT NULL AFTER `name` ; ALTER TABLE `posts` ADD `putfile` TINYTEXT NOT NULL AFTER `url` ; ALTER TABLE `posts` CHANGE `poster_id` `poster_id` INT( 10 ) NOT NULL DEFAULT '0' AFTER poster_name; ALTER TABLE `posts` CHANGE `poster_name` `author` TINYTEXT NOT NULL; ALTER TABLE `posts` CHANGE `poster_id` `id_author` INT( 10 ) NOT NULL DEFAULT '0' ; ALTER TABLE `posts` ADD `hide` ENUM( 'show', 'hide', 'lock' ) DEFAULT 'show' NOT NULL AFTER `id_author` ; ALTER TABLE `posts` CHANGE `post_time` `time` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00'; ALTER TABLE `posts` ADD `parent_post` INT NOT NULL AFTER `time` ; ALTER TABLE `posts` DROP `poster_ip` , DROP `post_status` ; ALTER TABLE `posts` CHANGE `topic_id` `id_theme` INT( 10 ) NOT NULL DEFAULT '1'; ALTER TABLE `minibbtable_users` RENAME `authors` ; ALTER TABLE `authors` CHANGE `user_id` `id_author` INT( 10 ) NOT NULL AUTO_INCREMENT; ALTER TABLE `authors` CHANGE `username` `name` TINYTEXT NOT NULL ; ALTER TABLE `authors` DROP `user_regdate` ; ALTER TABLE `authors` CHANGE `user_password` `passw` TINYTEXT NOT NULL; ALTER TABLE `authors` CHANGE `user_email` `email` TINYTEXT NOT NULL ; ALTER TABLE `authors` ADD `sendmail` ENUM( 'yes', 'no' ) DEFAULT 'no' NOT NULL AFTER `email` ; ALTER TABLE `authors` CHANGE `user_website` `url` TINYTEXT NOT NULL AFTER sendmail ; ALTER TABLE `authors` CHANGE `user_icq` `icq` TINYTEXT NOT NULL ; ALTER TABLE `authors` DROP `user_occ` , DROP `user_from` , DROP `user_viewemail` , DROP `user_sorttopics` , DROP `user_newpwdkey` , DROP `user_newpasswd` , DROP `language` , DROP `activity` , DROP `num_topics` , DROP `user_custom1` , DROP `user_custom2` , DROP `user_custom3` ; ALTER TABLE `authors` CHANGE `user_interest` `about` TINYTEXT NOT NULL ; ALTER TABLE `authors` ADD `photo` TINYTEXT NOT NULL AFTER `about` ; ALTER TABLE `authors` ADD `time` DATETIME NOT NULL AFTER `photo` ; ALTER TABLE `authors` ADD `last_time` DATETIME NOT NULL AFTER `time` ; ALTER TABLE `authors` CHANGE `num_posts` `themes` INT( 10 ) UNSIGNED NOT NULL DEFAULT '0'; ALTER TABLE `authors` ADD `statususer` ENUM( '', 'moderator', 'admin', 'wait' ) NOT NULL AFTER `themes` ; DROP TABLE `minibbtable_banned` , `minibbtable_send_mails` ; CREATE TABLE `archive_number` ( `id_theme` int(11) NOT NULL default '0' ); INSERT INTO `archive_number` VALUES (0); CREATE TABLE `archive_posts` ( `id_post` int(11) NOT NULL auto_increment, `name` text NOT NULL, `url` tinytext NOT NULL, `putfile` tinytext NOT NULL, `author` tinytext NOT NULL, `id_author` int(6) NOT NULL default '0', `hide` enum('show','hide','lock') NOT NULL default 'show', `time` datetime NOT NULL default '0000-00-00 00:00:00', `parent_post` int(11) NOT NULL default '0', `id_theme` int(11) NOT NULL default '0', PRIMARY KEY (`id_post`), FULLTEXT KEY `search` (`name`,`author`) ); CREATE TABLE `archive_themes` ( `id_theme` int(11) NOT NULL auto_increment, `name` tinytext NOT NULL, `author` tinytext NOT NULL, `id_author` int(6) NOT NULL default '0', `last_author` tinytext NOT NULL, `id_last_author` int(6) NOT NULL default '0', `hide` enum('show','hide','lock') NOT NULL default 'show', `time` datetime NOT NULL default '0000-00-00 00:00:00', `number` int(11) NOT NULL default '0', `id_forum` int(2) NOT NULL default '0', PRIMARY KEY (`id_theme`), FULLTEXT KEY `search` (`name`,`author`) ); CREATE TABLE `links` ( `id_links` int(11) NOT NULL auto_increment, `name` tinytext NOT NULL, `url` tinytext NOT NULL, `hide` enum('show','hide') NOT NULL default 'show', `pos` tinyint(4) NOT NULL default '0', `part` tinyint(4) NOT NULL default '0', PRIMARY KEY (`id_links`) ); CREATE TABLE `personally` ( `id_personally` int(11) NOT NULL auto_increment, `id_theme` int(11) NOT NULL default '0', `id_first` int(11) NOT NULL default '0', `id_second` int(11) NOT NULL default '0', PRIMARY KEY (`id_personally`), KEY `id_theme` (`id_theme`), KEY `id_first` (`id_first`), KEY `id_second` (`id_second`) ) ENGINE=MyISAM DEFAULT CHARSET=cp1251; CREATE TABLE `rss` ( `id_rss` int(11) NOT NULL auto_increment, `id_theme` int(11) default NULL, `name` tinytext NOT NULL, `post` tinytext NOT NULL, `author` tinytext NOT NULL, `hide` enum('show','hide','lock') NOT NULL default 'show', `putdate` datetime NOT NULL default '0000-00-00 00:00:00', `id_forum` int(2) NOT NULL default '0', PRIMARY KEY (`id_rss`) ); CREATE TABLE `settings` ( `name_forum` tinytext NOT NULL, `number_themes` int(3) NOT NULL default '0', `size_file` int(10) NOT NULL default '0', `size_photo` int(10) NOT NULL default '0', `send_mail` enum('yes','no') NOT NULL default 'no', `email` tinytext NOT NULL, `show_struct_switch` enum('yes','no') NOT NULL default 'yes', `show_forum_switch` enum('yes','no') NOT NULL default 'yes', `hello` tinytext NOT NULL, `cooktime` int(10) NOT NULL default '0', `skin` tinytext NOT NULL, `show_personally` enum('yes','no') NOT NULL default 'no', `user_email_required` enum('yes','no') NOT NULL default 'no', `email_distribution` enum('yes','no') NOT NULL default 'no', `registration_required` enum('yes','no') NOT NULL default 'no', `type_crypt` enum('PLAIN','MD5','PASSWORD','OLD_PASSWORD') NOT NULL default 'MD5', `confirm_registration` enum('yes','no') NOT NULL default 'no' ); INSERT INTO `settings` VALUES ('SoftTime-форум', 30, 824288, 824288, 'no', 'somebody@someone.ru', 'yes', 'yes', 'Доброго времени суток,', 4, 'base', 'yes', 'no', 'no', 'no', 'MD5', 'no'); CREATE TABLE `last_time` ( `id_author` int(11) NOT NULL auto_increment, `now1` datetime NOT NULL default '0000-00-00 00:00:00', `last_time1` datetime NOT NULL default '0000-00-00 00:00:00', `now2` datetime NOT NULL default '0000-00-00 00:00:00', `last_time2` datetime NOT NULL default '0000-00-00 00:00:00', `now3` datetime NOT NULL default '0000-00-00 00:00:00', `last_time3` datetime NOT NULL default '0000-00-00 00:00:00', `now5` datetime NOT NULL default '0000-00-00 00:00:00', `last_time5` datetime NOT NULL default '0000-00-00 00:00:00', `now6` datetime NOT NULL default '0000-00-00 00:00:00', `last_time6` datetime NOT NULL default '0000-00-00 00:00:00', PRIMARY KEY (`id_author`) );