
diff -r e3d7322305bf -r 5e1f1e916419 punbb/schema-work.sql
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/punbb/schema-work.sql	Sat Apr 05 23:56:45 2008 -0400
@@ -0,0 +1,549 @@
+    case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}bans (
+					id INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
+					username VARCHAR(200),
+					ip VARCHAR(255),
+					email VARCHAR(80),
+					message VARCHAR(255),
+					expire INT(10) UNSIGNED,
+					ban_creator INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					PRIMARY KEY (id)
+        ) ENGINE = MyISAM CHARACTER SET utf8
+      
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}bans (
+					id SERIAL,
+					username VARCHAR(200),
+					ip VARCHAR(255),
+					email VARCHAR(80),
+					message VARCHAR(255),
+					expire INT,
+					ban_creator INT NOT NULL DEFAULT 0,
+					PRIMARY KEY (id)
+        )
+
+    case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}categories (
+					id INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
+					cat_name VARCHAR(80) NOT NULL DEFAULT 'New Category',
+					disp_position INT(10) NOT NULL DEFAULT 0,
+					PRIMARY KEY (id)
+					) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}categories (
+					id SERIAL,
+					cat_name VARCHAR(80) NOT NULL DEFAULT 'New Category',
+					disp_position INT NOT NULL DEFAULT 0,
+					PRIMARY KEY (id)
+					)
+
+		case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}censoring (
+					id INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
+					search_for VARCHAR(60) NOT NULL DEFAULT '',
+					replace_with VARCHAR(60) NOT NULL DEFAULT '',
+					PRIMARY KEY (id)
+					) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}censoring (
+					id SERIAL,
+					search_for VARCHAR(60) NOT NULL DEFAULT '',
+					replace_with VARCHAR(60) NOT NULL DEFAULT '',
+					PRIMARY KEY (id)
+					)
+
+		case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}config (
+					conf_name VARCHAR(255) NOT NULL DEFAULT '',
+					conf_value TEXT,
+					PRIMARY KEY (conf_name)
+					) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}config (
+					conf_name VARCHAR(255) NOT NULL DEFAULT '',
+					conf_value TEXT,
+					PRIMARY KEY (conf_name)
+					)
+
+		case 'sqlite':
+			CREATE TABLE {{TABLE_PREFIX}}config (
+					conf_name VARCHAR(255) NOT NULL DEFAULT '',
+					conf_value TEXT,
+					PRIMARY KEY (conf_name)
+					)
+
+		case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}extensions (
+					id VARCHAR(50) NOT NULL DEFAULT '',
+					title VARCHAR(255) NOT NULL DEFAULT '',
+					version VARCHAR(25) NOT NULL DEFAULT '',
+					description TEXT,
+					author VARCHAR(50) NOT NULL DEFAULT '',
+					uninstall TEXT,
+					uninstall_note TEXT,
+					disabled TINYINT(1) NOT NULL DEFAULT 0,
+					PRIMARY KEY(id)
+					) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}extensions (
+					id VARCHAR(50) NOT NULL DEFAULT '',
+					title VARCHAR(255) NOT NULL DEFAULT '',
+					version VARCHAR(25) NOT NULL DEFAULT '',
+					description TEXT,
+					author VARCHAR(50) NOT NULL DEFAULT '',
+					uninstall TEXT,
+					uninstall_note TEXT,
+					disabled SMALLINT NOT NULL DEFAULT 0,
+					PRIMARY KEY(id)
+					)
+
+		case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}extension_hooks (
+					id VARCHAR(50) NOT NULL DEFAULT '',
+					extension_id VARCHAR(50) NOT NULL DEFAULT '',
+					code TEXT,
+					installed INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					PRIMARY KEY(id, extension_id)
+					) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}extension_hooks (
+					id VARCHAR(50) NOT NULL DEFAULT '',
+					extension_id VARCHAR(50) NOT NULL DEFAULT '',
+					code TEXT,
+					installed INT NOT NULL DEFAULT 0,
+					PRIMARY KEY(id, extension_id)
+					)
+
+		case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}forum_perms (
+					group_id INT(10) NOT NULL DEFAULT 0,
+					forum_id INT(10) NOT NULL DEFAULT 0,
+					read_forum TINYINT(1) NOT NULL DEFAULT 1,
+					post_replies TINYINT(1) NOT NULL DEFAULT 1,
+					post_topics TINYINT(1) NOT NULL DEFAULT 1,
+					PRIMARY KEY (group_id, forum_id)
+					) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}forum_perms (
+					group_id INT NOT NULL DEFAULT 0,
+					forum_id INT NOT NULL DEFAULT 0,
+					read_forum SMALLINT NOT NULL DEFAULT 1,
+					post_replies SMALLINT NOT NULL DEFAULT 1,
+					post_topics SMALLINT NOT NULL DEFAULT 1,
+					PRIMARY KEY (group_id, forum_id)
+					)
+
+		case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}forums (
+					id INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
+					forum_name VARCHAR(80) NOT NULL DEFAULT 'New forum',
+					forum_desc TEXT,
+					redirect_url VARCHAR(100),
+					moderators TEXT,
+					num_topics MEDIUMINT(8) UNSIGNED NOT NULL DEFAULT 0,
+					num_posts MEDIUMINT(8) UNSIGNED NOT NULL DEFAULT 0,
+					last_post INT(10) UNSIGNED,
+					last_post_id INT(10) UNSIGNED,
+					last_poster VARCHAR(200),
+					sort_by TINYINT(1) NOT NULL DEFAULT 0,
+					disp_position INT(10) NOT NULL DEFAULT 0,
+					cat_id INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					PRIMARY KEY (id)
+					) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}forums (
+					id SERIAL,
+					forum_name VARCHAR(80) NOT NULL DEFAULT 'New forum',
+					forum_desc TEXT,
+					redirect_url VARCHAR(100),
+					moderators TEXT,
+					num_topics INT NOT NULL DEFAULT 0,
+					num_posts INT NOT NULL DEFAULT 0,
+					last_post INT,
+					last_post_id INT,
+					last_poster VARCHAR(200),
+					sort_by SMALLINT NOT NULL DEFAULT 0,
+					disp_position INT NOT NULL DEFAULT 0,
+					cat_id INT NOT NULL DEFAULT 0,
+					PRIMARY KEY (id)
+					)
+
+		case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}groups (
+					g_id INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
+					g_title VARCHAR(50) NOT NULL DEFAULT '',
+					g_user_title VARCHAR(50),
+					g_moderator TINYINT(1) NOT NULL DEFAULT 0,
+					g_mod_edit_users TINYINT(1) NOT NULL DEFAULT 0,
+					g_mod_rename_users TINYINT(1) NOT NULL DEFAULT 0,
+					g_mod_change_passwords TINYINT(1) NOT NULL DEFAULT 0,
+					g_mod_ban_users TINYINT(1) NOT NULL DEFAULT 0,
+					g_read_board TINYINT(1) NOT NULL DEFAULT 1,
+					g_view_users TINYINT(1) NOT NULL DEFAULT 1,
+					g_post_replies TINYINT(1) NOT NULL DEFAULT 1,
+					g_post_topics TINYINT(1) NOT NULL DEFAULT 1,
+					g_edit_posts TINYINT(1) NOT NULL DEFAULT 1,
+					g_delete_posts TINYINT(1) NOT NULL DEFAULT 1,
+					g_delete_topics TINYINT(1) NOT NULL DEFAULT 1,
+					g_set_title TINYINT(1) NOT NULL DEFAULT 1,
+					g_search TINYINT(1) NOT NULL DEFAULT 1,
+					g_search_users TINYINT(1) NOT NULL DEFAULT 1,
+					g_edit_subjects_interval SMALLINT(6) NOT NULL DEFAULT 300,
+					g_post_flood SMALLINT(6) NOT NULL DEFAULT 30,
+					g_search_flood SMALLINT(6) NOT NULL DEFAULT 30,
+					PRIMARY KEY (g_id)
+					) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}groups (
+					g_id SERIAL,
+					g_title VARCHAR(50) NOT NULL DEFAULT '',
+					g_user_title VARCHAR(50),
+					g_moderator SMALLINT NOT NULL DEFAULT 0,
+					g_mod_edit_users SMALLINT NOT NULL DEFAULT 0,
+					g_mod_rename_users SMALLINT NOT NULL DEFAULT 0,
+					g_mod_change_passwords SMALLINT NOT NULL DEFAULT 0,
+					g_mod_ban_users SMALLINT NOT NULL DEFAULT 0,
+					g_read_board SMALLINT NOT NULL DEFAULT 1,
+					g_view_users SMALLINT NOT NULL DEFAULT 1,
+					g_post_replies SMALLINT NOT NULL DEFAULT 1,
+					g_post_topics SMALLINT NOT NULL DEFAULT 1,
+					g_edit_posts SMALLINT NOT NULL DEFAULT 1,
+					g_delete_posts SMALLINT NOT NULL DEFAULT 1,
+					g_delete_topics SMALLINT NOT NULL DEFAULT 1,
+					g_set_title SMALLINT NOT NULL DEFAULT 1,
+					g_search SMALLINT NOT NULL DEFAULT 1,
+					g_search_users SMALLINT NOT NULL DEFAULT 1,
+					g_edit_subjects_interval SMALLINT NOT NULL DEFAULT 300,
+					g_post_flood SMALLINT NOT NULL DEFAULT 30,
+					g_search_flood SMALLINT NOT NULL DEFAULT 30,
+					PRIMARY KEY (g_id)
+        )
+
+    case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}online (
+					user_id INT(10) UNSIGNED NOT NULL DEFAULT 1,
+					ident VARCHAR(200) NOT NULL DEFAULT '',
+					logged INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					idle TINYINT(1) NOT NULL DEFAULT 0,
+					csrf_token VARCHAR(40) NOT NULL DEFAULT '',
+					prev_url VARCHAR(255)
+					) TYPE=HEAP;
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}online (
+					user_id INT NOT NULL DEFAULT 1,
+					ident VARCHAR(200) NOT NULL DEFAULT '',
+					logged INT NOT NULL DEFAULT 0,
+					idle SMALLINT NOT NULL DEFAULT 0,
+					csrf_token VARCHAR(40) NOT NULL DEFAULT '',
+					prev_url VARCHAR(255)
+					)
+
+		case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}posts (
+					id INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
+					poster VARCHAR(200) NOT NULL DEFAULT '',
+					poster_id INT(10) UNSIGNED NOT NULL DEFAULT 1,
+					poster_ip VARCHAR(15),
+					poster_email VARCHAR(80),
+					message TEXT,
+					hide_smilies TINYINT(1) NOT NULL DEFAULT 0,
+					posted INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					edited INT(10) UNSIGNED,
+					edited_by VARCHAR(200),
+					topic_id INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					PRIMARY KEY (id)
+        ) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}posts (
+					id SERIAL,
+					poster VARCHAR(200) NOT NULL DEFAULT '',
+					poster_id INT NOT NULL DEFAULT 1,
+					poster_ip VARCHAR(15),
+					poster_email VARCHAR(80),
+					message TEXT,
+					hide_smilies SMALLINT NOT NULL DEFAULT 0,
+					posted INT NOT NULL DEFAULT 0,
+					edited INT,
+					edited_by VARCHAR(200),
+					topic_id INT NOT NULL DEFAULT 0,
+					PRIMARY KEY (id)
+        )
+
+    case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}ranks (
+					id INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
+					rank VARCHAR(50) NOT NULL DEFAULT '',
+					min_posts MEDIUMINT(8) UNSIGNED NOT NULL DEFAULT 0,
+					PRIMARY KEY (id)
+        ) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}ranks (
+					id SERIAL,
+					rank VARCHAR(50) NOT NULL DEFAULT '',
+					min_posts INT NOT NULL DEFAULT 0,
+					PRIMARY KEY (id)
+        )
+
+		case 'sqlite':
+			CREATE TABLE {{TABLE_PREFIX}}ranks (
+					id INTEGER NOT NULL,
+					rank VARCHAR(50) NOT NULL DEFAULT '',
+					min_posts INTEGER NOT NULL DEFAULT 0,
+					PRIMARY KEY (id)
+        )
+
+    case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}reports (
+					id INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
+					post_id INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					topic_id INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					forum_id INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					reported_by INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					created INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					message TEXT,
+					zapped INT(10) UNSIGNED,
+					zapped_by INT(10) UNSIGNED,
+					PRIMARY KEY (id)
+        ) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}reports (
+					id SERIAL,
+					post_id INT NOT NULL DEFAULT 0,
+					topic_id INT NOT NULL DEFAULT 0,
+					forum_id INT NOT NULL DEFAULT 0,
+					reported_by INT NOT NULL DEFAULT 0,
+					created INT NOT NULL DEFAULT 0,
+					message TEXT,
+					zapped INT,
+					zapped_by INT,
+					PRIMARY KEY (id)
+        )
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}search_cache (
+					id INT NOT NULL DEFAULT 0,
+					ident VARCHAR(200) NOT NULL DEFAULT '',
+					search_data TEXT,
+					PRIMARY KEY (id)
+					)
+
+    case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}search_matches (
+					post_id INT NOT NULL DEFAULT 0,
+					word_id INT NOT NULL DEFAULT 0,
+					subject_match SMALLINT NOT NULL DEFAULT 0
+					)
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}search_words (
+					id SERIAL,
+					word VARCHAR(20) NOT NULL DEFAULT '',
+					PRIMARY KEY (word)
+					)
+
+		case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}subscriptions (
+					user_id INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					topic_id INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					PRIMARY KEY (user_id, topic_id)
+					) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}subscriptions (
+					user_id INT NOT NULL DEFAULT 0,
+					topic_id INT NOT NULL DEFAULT 0,
+					PRIMARY KEY (user_id, topic_id)
+					)
+
+    case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}topics (
+					id INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
+					poster VARCHAR(200) NOT NULL DEFAULT '',
+					subject VARCHAR(255) NOT NULL DEFAULT '',
+					posted INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					first_post_id INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					last_post INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					last_post_id INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					last_poster VARCHAR(200),
+					num_views MEDIUMINT(8) UNSIGNED NOT NULL DEFAULT 0,
+					num_replies MEDIUMINT(8) UNSIGNED NOT NULL DEFAULT 0,
+					closed TINYINT(1) NOT NULL DEFAULT 0,
+					sticky TINYINT(1) NOT NULL DEFAULT 0,
+					moved_to INT(10) UNSIGNED,
+					forum_id INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					PRIMARY KEY (id)
+        ) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}topics (
+					id SERIAL,
+					poster VARCHAR(200) NOT NULL DEFAULT '',
+					subject VARCHAR(255) NOT NULL DEFAULT '',
+					posted INT NOT NULL DEFAULT 0,
+					first_post_id INT NOT NULL DEFAULT 0,
+					last_post INT NOT NULL DEFAULT 0,
+					last_post_id INT NOT NULL DEFAULT 0,
+					last_poster VARCHAR(200),
+					num_views INT NOT NULL DEFAULT 0,
+					num_replies INT NOT NULL DEFAULT 0,
+					closed SMALLINT NOT NULL DEFAULT 0,
+					sticky SMALLINT NOT NULL DEFAULT 0,
+					moved_to INT,
+					forum_id INT NOT NULL DEFAULT 0,
+					PRIMARY KEY (id)
+        )
+
+		case 'mysql':
+		case 'mysqli':
+			CREATE TABLE {{TABLE_PREFIX}}users (
+					id INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
+					group_id INT(10) UNSIGNED NOT NULL DEFAULT 4,
+					username VARCHAR(200) NOT NULL DEFAULT '',
+					password VARCHAR(40) NOT NULL DEFAULT '',
+					salt VARCHAR(12),
+					email VARCHAR(80) NOT NULL DEFAULT '',
+					title VARCHAR(50),
+					realname VARCHAR(40),
+					url VARCHAR(100),
+					jabber VARCHAR(80),
+					icq VARCHAR(12),
+					msn VARCHAR(80),
+					aim VARCHAR(30),
+					yahoo VARCHAR(30),
+					location VARCHAR(30),
+					signature TEXT,
+					disp_topics TINYINT(3) UNSIGNED,
+					disp_posts TINYINT(3) UNSIGNED,
+					email_setting TINYINT(1) NOT NULL DEFAULT 1,
+					save_pass TINYINT(1) NOT NULL DEFAULT 1,
+					notify_with_post TINYINT(1) NOT NULL DEFAULT 0,
+					auto_notify TINYINT(1) NOT NULL DEFAULT 0,
+					show_smilies TINYINT(1) NOT NULL DEFAULT 1,
+					show_img TINYINT(1) NOT NULL DEFAULT 1,
+					show_img_sig TINYINT(1) NOT NULL DEFAULT 1,
+					show_avatars TINYINT(1) NOT NULL DEFAULT 1,
+					show_sig TINYINT(1) NOT NULL DEFAULT 1,
+					timezone FLOAT NOT NULL DEFAULT 0,
+					dst TINYINT(1) NOT NULL DEFAULT 0,
+					time_format INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					date_format INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					language VARCHAR(25) NOT NULL DEFAULT 'English',
+					style VARCHAR(25) NOT NULL DEFAULT 'Oxygen',
+					num_posts INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					last_post INT(10) UNSIGNED,
+					registered INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					registration_ip VARCHAR(15) NOT NULL DEFAULT '0.0.0.0',
+					last_visit INT(10) UNSIGNED NOT NULL DEFAULT 0,
+					admin_note VARCHAR(30),
+					activate_string VARCHAR(80),
+					activate_key VARCHAR(8),
+					PRIMARY KEY (id)
+        ) ENGINE = MyISAM CHARACTER SET utf8
+
+		case 'pgsql':
+			CREATE TABLE {{TABLE_PREFIX}}users (
+					id SERIAL,
+					group_id INT NOT NULL DEFAULT 4,
+					username VARCHAR(200) NOT NULL DEFAULT '',
+					password VARCHAR(40) NOT NULL DEFAULT '',
+					salt VARCHAR(12),
+					email VARCHAR(80) NOT NULL DEFAULT '',
+					title VARCHAR(50),
+					realname VARCHAR(40),
+					url VARCHAR(100),
+					jabber VARCHAR(80),
+					icq VARCHAR(12),
+					msn VARCHAR(80),
+					aim VARCHAR(30),
+					yahoo VARCHAR(30),
+					location VARCHAR(30),
+					signature TEXT,
+					disp_topics SMALLINT,
+					disp_posts SMALLINT,
+					email_setting SMALLINT NOT NULL DEFAULT 1,
+					save_pass SMALLINT NOT NULL DEFAULT 1,
+					notify_with_post SMALLINT NOT NULL DEFAULT 0,
+					auto_notify SMALLINT NOT NULL DEFAULT 0,
+					show_smilies SMALLINT NOT NULL DEFAULT 1,
+					show_img SMALLINT NOT NULL DEFAULT 1,
+					show_img_sig SMALLINT NOT NULL DEFAULT 1,
+					show_avatars SMALLINT NOT NULL DEFAULT 1,
+					show_sig SMALLINT NOT NULL DEFAULT 1,
+					timezone REAL NOT NULL DEFAULT 0,
+					dst SMALLINT NOT NULL DEFAULT 0,
+					time_format INT NOT NULL DEFAULT 0,
+					date_format INT NOT NULL DEFAULT 0,
+					language VARCHAR(25) NOT NULL DEFAULT 'English',
+					style VARCHAR(25) NOT NULL DEFAULT 'Oxygen',
+					num_posts INT NOT NULL DEFAULT 0,
+					last_post INT,
+					registered INT NOT NULL DEFAULT 0,
+					registration_ip VARCHAR(15) NOT NULL DEFAULT '0.0.0.0',
+					last_visit INT NOT NULL DEFAULT 0,
+					admin_note VARCHAR(30),
+					activate_string VARCHAR(80),
+					activate_key VARCHAR(8),
+					PRIMARY KEY (id)
+        )
+
+		case 'mysql':
+		case 'mysqli':
+			// mysql
+			ALTER TABLE {{TABLE_PREFIX}}online ADD UNIQUE INDEX {{TABLE_PREFIX}}online_user_id_ident_idx(user_id,ident(25));
+			ALTER TABLE {{TABLE_PREFIX}}online ADD INDEX {{TABLE_PREFIX}}online_user_id_idx(user_id);
+			ALTER TABLE {{TABLE_PREFIX}}posts ADD INDEX {{TABLE_PREFIX}}posts_topic_id_idx(topic_id);
+			ALTER TABLE {{TABLE_PREFIX}}posts ADD INDEX {{TABLE_PREFIX}}posts_multi_idx(poster_id, topic_id);
+			ALTER TABLE {{TABLE_PREFIX}}posts ADD FULLTEXT {{TABLE_PREFIX}}posts_message_idx(message);
+			ALTER TABLE {{TABLE_PREFIX}}reports ADD INDEX {{TABLE_PREFIX}}reports_zapped_idx(zapped);
+			ALTER TABLE {{TABLE_PREFIX}}topics ADD INDEX {{TABLE_PREFIX}}topics_forum_id_idx(forum_id);
+			ALTER TABLE {{TABLE_PREFIX}}topics ADD INDEX {{TABLE_PREFIX}}topics_moved_to_idx(moved_to);
+			ALTER TABLE {{TABLE_PREFIX}}topics ADD INDEX {{TABLE_PREFIX}}topics_last_post_idx(last_post);
+			ALTER TABLE {{TABLE_PREFIX}}topics ADD INDEX {{TABLE_PREFIX}}topics_first_post_id_idx(first_post_id);
+			ALTER TABLE {{TABLE_PREFIX}}topics ADD FULLTEXT {{TABLE_PREFIX}}topics_subject_idx(subject);
+			ALTER TABLE {{TABLE_PREFIX}}users ADD INDEX {{TABLE_PREFIX}}users_registered_idx(registered);
+			ALTER TABLE {{TABLE_PREFIX}}users ADD INDEX {{TABLE_PREFIX}}users_username_idx(username(8));
+      
+      // pgsql
+			CREATE UNIQUE INDEX {{TABLE_PREFIX}}online_user_id_ident_idx ON {{TABLE_PREFIX}}online(user_id,ident);
+			CREATE INDEX {{TABLE_PREFIX}}online_user_id_idx ON {{TABLE_PREFIX}}online(user_id);
+			CREATE INDEX {{TABLE_PREFIX}}posts_topic_id_idx ON {{TABLE_PREFIX}}posts(topic_id);
+			CREATE INDEX {{TABLE_PREFIX}}posts_multi_idx ON {{TABLE_PREFIX}}posts(poster_id, topic_id);
+			CREATE INDEX {{TABLE_PREFIX}}reports_zapped_idx ON {{TABLE_PREFIX}}reports(zapped);
+			CREATE INDEX {{TABLE_PREFIX}}search_matches_word_id_idx ON {{TABLE_PREFIX}}search_matches(word_id);
+			CREATE INDEX {{TABLE_PREFIX}}search_matches_post_id_idx ON {{TABLE_PREFIX}}search_matches(post_id);
+			CREATE INDEX {{TABLE_PREFIX}}topics_forum_id_idx ON {{TABLE_PREFIX}}topics(forum_id);
+			CREATE INDEX {{TABLE_PREFIX}}topics_moved_to_idx ON {{TABLE_PREFIX}}topics(moved_to);
+			CREATE INDEX {{TABLE_PREFIX}}topics_last_post_idx ON {{TABLE_PREFIX}}topics(last_post);
+			CREATE INDEX {{TABLE_PREFIX}}topics_first_post_id_idx ON {{TABLE_PREFIX}}topics(first_post_id);
+			CREATE INDEX {{TABLE_PREFIX}}users_registered_idx ON {{TABLE_PREFIX}}users(registered);
+			CREATE INDEX {{TABLE_PREFIX}}users_username_idx ON {{TABLE_PREFIX}}users(username);
+			CREATE INDEX {{TABLE_PREFIX}}search_cache_ident_idx ON {{TABLE_PREFIX}}search_cache(ident);
+			CREATE INDEX {{TABLE_PREFIX}}search_words_id_idx ON {{TABLE_PREFIX}}search_words(id);
+




