Index: /veekun/trunk/script/base.sql
===================================================================
--- /veekun/trunk/script/base.sql (revision 406)
+++ /veekun/trunk/script/base.sql (revision 420)
@@ -15,4 +15,6 @@
 
 DROP TABLE IF EXISTS edits;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE edits (
   id int(10) unsigned NOT NULL auto_increment,
@@ -20,8 +22,9 @@
   user_id int(10) unsigned NOT NULL default '0',
   `time` int(10) unsigned NOT NULL default '0',
-  old_content text NOT NULL,
+  old_content mediumtext NOT NULL,
   PRIMARY KEY  (id),
   KEY POSTID USING BTREE (post_id)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -30,4 +33,6 @@
 
 DROP TABLE IF EXISTS error_log;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE error_log (
   id int(10) unsigned NOT NULL auto_increment,
@@ -41,4 +46,5 @@
   PRIMARY KEY  (id)
 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -47,4 +53,6 @@
 
 DROP TABLE IF EXISTS forums;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE forums (
   id int(10) unsigned NOT NULL auto_increment,
@@ -57,5 +65,6 @@
   description varchar(255) NOT NULL,
   PRIMARY KEY  (id)
-) ENGINE=InnoDB DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC;
+) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -64,4 +73,6 @@
 
 DROP TABLE IF EXISTS group_permissions;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE group_permissions (
   group_id int(10) unsigned NOT NULL default '0',
@@ -70,5 +81,6 @@
   polarity enum('allow','deny') default NULL,
   PRIMARY KEY  USING BTREE (group_id,permission,scope)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -77,4 +89,6 @@
 
 DROP TABLE IF EXISTS groups;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE groups (
   id int(10) unsigned NOT NULL auto_increment,
@@ -83,4 +97,5 @@
   UNIQUE KEY id (id)
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -89,4 +104,6 @@
 
 DROP TABLE IF EXISTS messages;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE messages (
   id int(10) unsigned NOT NULL auto_increment,
@@ -95,7 +112,8 @@
   `time` int(10) unsigned NOT NULL default '0',
   `subject` tinytext NOT NULL,
-  message text NOT NULL,
-  PRIMARY KEY  (id)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+  message mediumtext NOT NULL,
+  PRIMARY KEY  (id)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -104,4 +122,6 @@
 
 DROP TABLE IF EXISTS posts;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE posts (
   id int(10) unsigned NOT NULL auto_increment,
@@ -111,10 +131,11 @@
   `time` int(10) unsigned NOT NULL default '0',
   format enum('bbcode','raw','html') NOT NULL default 'raw',
-  content text NOT NULL,
+  content mediumtext NOT NULL,
   last_edit_id int(10) unsigned NOT NULL default '0',
   PRIMARY KEY  (id),
   KEY THREAD USING BTREE (thread_id),
   KEY `USER` USING BTREE (user_id)
-) ENGINE=InnoDB DEFAULT CHARSET=latin1 ROW_FORMAT=FIXED;
+) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=FIXED;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -123,12 +144,15 @@
 
 DROP TABLE IF EXISTS sessions;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE sessions (
   id varchar(72) NOT NULL default '',
   user_id int(10) unsigned NOT NULL default '0',
   time_expires int(10) unsigned default NULL,
-  `data` text,
+  `data` mediumtext,
   PRIMARY KEY  USING BTREE (id),
   KEY USER_ID USING BTREE (user_id)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -137,4 +161,6 @@
 
 DROP TABLE IF EXISTS shoutbox;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE shoutbox (
   id int(10) unsigned NOT NULL auto_increment,
@@ -143,7 +169,8 @@
   ip int(10) unsigned NOT NULL default '0',
   `time` int(10) unsigned NOT NULL default '0',
-  content text NOT NULL,
-  PRIMARY KEY  (id)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+  content mediumtext NOT NULL,
+  PRIMARY KEY  (id)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -152,4 +179,6 @@
 
 DROP TABLE IF EXISTS threads;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE threads (
   id int(10) unsigned NOT NULL auto_increment,
@@ -165,5 +194,6 @@
   PRIMARY KEY  (id),
   KEY FORUMID USING BTREE (forum_id)
-) ENGINE=InnoDB DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC;
+) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -172,4 +202,6 @@
 
 DROP TABLE IF EXISTS thread_views;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE thread_views (
   thread_id int(10) unsigned NOT NULL,
@@ -178,4 +210,5 @@
   PRIMARY KEY  (thread_id,user_id)
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -184,4 +217,6 @@
 
 DROP TABLE IF EXISTS user_groups;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE user_groups (
   user_id int(10) unsigned NOT NULL default '0',
@@ -191,5 +226,6 @@
   KEY user_id USING BTREE (user_id),
   KEY group_id USING BTREE (group_id)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -198,4 +234,6 @@
 
 DROP TABLE IF EXISTS users;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE users (
   id int(10) unsigned NOT NULL auto_increment,
@@ -218,9 +256,10 @@
   pm_icon enum('bead','bellossom','dream','duskull','eatmail','gorgeous','letter','magnemite','pika','retro','slakoth','vee','wailmer','wingull','zigzagoon') NOT NULL default 'letter',
   custom_title varchar(32) NOT NULL,
-  signature text NOT NULL,
+  signature mediumtext NOT NULL,
   is_dumb tinyint(1) NOT NULL default '0',
   PRIMARY KEY  (id),
   UNIQUE KEY `NAME` (`name`)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
 
Index: /veekun/trunk/script/gallery.sql
===================================================================
--- /veekun/trunk/script/gallery.sql (revision 406)
+++ /veekun/trunk/script/gallery.sql (revision 420)
@@ -15,4 +15,6 @@
 
 DROP TABLE IF EXISTS creators;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE creators (
   id int(10) unsigned NOT NULL auto_increment,
@@ -22,4 +24,5 @@
   PRIMARY KEY  (id)
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -28,4 +31,6 @@
 
 DROP TABLE IF EXISTS gallery;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE gallery (
   id int(10) unsigned NOT NULL auto_increment,
@@ -37,5 +42,5 @@
   `hash` varchar(32) NOT NULL default '',
   title varchar(48) NOT NULL default '',
-  description text NOT NULL,
+  description mediumtext NOT NULL,
   height smallint(5) unsigned NOT NULL default '0',
   width smallint(5) unsigned NOT NULL default '0',
@@ -45,5 +50,6 @@
   PRIMARY KEY  (id),
   UNIQUE KEY filename (filename)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -52,4 +58,6 @@
 
 DROP TABLE IF EXISTS gallery_keywords;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE gallery_keywords (
   id int(10) unsigned NOT NULL auto_increment,
@@ -59,5 +67,6 @@
   PRIMARY KEY  (id),
   UNIQUE KEY keyword (keyword)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -66,4 +75,6 @@
 
 DROP TABLE IF EXISTS item_keywords;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE item_keywords (
   itemid int(10) unsigned NOT NULL default '0',
@@ -72,5 +83,6 @@
   KEY itemid (itemid),
   KEY keywordid (keywordid)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
 
Index: /veekun/trunk/script/pokedex.sql
===================================================================
--- /veekun/trunk/script/pokedex.sql (revision 410)
+++ /veekun/trunk/script/pokedex.sql (revision 420)
@@ -15,4 +15,6 @@
 
 DROP TABLE IF EXISTS abilities;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE abilities (
   id tinyint(3) unsigned NOT NULL default '0',
@@ -22,4 +24,5 @@
   PRIMARY KEY  (id)
 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -161,4 +164,6 @@
 
 DROP TABLE IF EXISTS berries;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE berries (
   id int(10) unsigned NOT NULL auto_increment,
@@ -176,4 +181,5 @@
   PRIMARY KEY  (id)
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -255,4 +261,6 @@
 
 DROP TABLE IF EXISTS contest_effects;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE contest_effects (
   id tinyint(4) NOT NULL default '0',
@@ -263,4 +271,5 @@
   PRIMARY KEY  (id)
 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -311,4 +320,6 @@
 
 DROP TABLE IF EXISTS evo_chains;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE evo_chains (
   id tinyint(3) unsigned NOT NULL default '0',
@@ -317,5 +328,6 @@
   baby_item varchar(12) NOT NULL,
   PRIMARY KEY  (id)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -581,4 +593,6 @@
 
 DROP TABLE IF EXISTS flavor_text;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE flavor_text (
   pokemon_id smallint(5) unsigned NOT NULL default '0',
@@ -587,4 +601,5 @@
   PRIMARY KEY  USING BTREE (pokemon_id,generation)
 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -4088,4 +4103,6 @@
 
 DROP TABLE IF EXISTS items;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE items (
   id int(10) unsigned NOT NULL,
@@ -4129,4 +4146,5 @@
   PRIMARY KEY  (id)
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -4585,4 +4603,6 @@
 
 DROP TABLE IF EXISTS locations;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE locations (
   id int(10) unsigned NOT NULL auto_increment,
@@ -4593,4 +4613,5 @@
   PRIMARY KEY  (id)
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -4688,4 +4709,6 @@
 
 DROP TABLE IF EXISTS location_sections;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE location_sections (
   id int(10) unsigned NOT NULL auto_increment,
@@ -4694,4 +4717,5 @@
   PRIMARY KEY  (id)
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -4849,4 +4873,6 @@
 
 DROP TABLE IF EXISTS location_encounters;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE location_encounters (
   location_id int(10) unsigned NOT NULL,
@@ -4860,4 +4886,5 @@
   max_level tinyint(3) unsigned NOT NULL default '0'
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -11523,4 +11550,6 @@
 
 DROP TABLE IF EXISTS machines;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE machines (
   id tinyint(3) unsigned NOT NULL default '0',
@@ -11530,5 +11559,6 @@
   location tinytext NOT NULL,
   PRIMARY KEY  (id,generation)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -11816,8 +11846,10 @@
 
 DROP TABLE IF EXISTS moves;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE moves (
   id smallint(3) NOT NULL default '0',
   `name` varchar(30) NOT NULL default '',
-  name_jp tinyblob NOT NULL,
+  name_jp varchar(7) default NULL,
   name_romaji varchar(16) NOT NULL default '',
   `type` varchar(8) NOT NULL default '',
@@ -11835,11 +11867,12 @@
   move_effect_id int(10) unsigned NOT NULL,
   blurb_rusa tinytext NOT NULL,
-  blurb_dp tinytext character set utf8 NOT NULL,
+  blurb_dp tinytext NOT NULL,
   contest_type enum('cute','tough','smart','cool','beauty') NOT NULL default 'cute',
   contest_effect_id tinyint(4) NOT NULL default '0',
-  notes text,
+  notes mediumtext,
   XXX_new_flags char(13) default NULL,
   PRIMARY KEY  (id)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -12335,11 +12368,14 @@
 
 DROP TABLE IF EXISTS move_effects;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE move_effects (
   id int(10) unsigned NOT NULL,
   priority tinyint(4) NOT NULL,
   short_description varchar(128) NOT NULL,
-  description text NOT NULL,
+  description mediumtext NOT NULL,
   PRIMARY KEY  (id)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -12614,4 +12650,6 @@
 
 DROP TABLE IF EXISTS pokemon;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE pokemon (
   id smallint(3) NOT NULL default '0',
@@ -12621,5 +12659,5 @@
   `name` varchar(20) NOT NULL default '',
   alt_form varchar(16) NOT NULL,
-  name_jp tinyblob NOT NULL,
+  name_jp varchar(5) default NULL,
   name_romaji varchar(16) NOT NULL default '',
   evo_chain_id smallint(3) unsigned NOT NULL default '0',
@@ -12646,5 +12684,5 @@
   gender_rate tinyint(3) unsigned NOT NULL default '0',
   base_happiness tinyint(3) unsigned NOT NULL,
-  notes text,
+  notes mediumtext,
   flags set('baby','dpfem','dpfemback') NOT NULL default '',
   real_pokemon_id int(10) unsigned NOT NULL,
@@ -12657,5 +12695,6 @@
   KEY HP (stat_hp),
   KEY REALID USING BTREE (real_pokemon_id)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -13173,4 +13212,6 @@
 
 DROP TABLE IF EXISTS pokemon_abilities;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE pokemon_abilities (
   pokemon_id int(10) unsigned NOT NULL,
@@ -13181,4 +13222,5 @@
   KEY abilityid USING BTREE (ability_id)
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -13966,4 +14008,6 @@
 
 DROP TABLE IF EXISTS pokemon_breeds;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE pokemon_breeds (
   pokemon_id int(10) unsigned NOT NULL,
@@ -13972,5 +14016,6 @@
   KEY breed (breed),
   KEY pokeid USING BTREE (pokemon_id)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -14634,4 +14679,6 @@
 
 DROP TABLE IF EXISTS pokemon_items;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE pokemon_items (
   pokemon_id smallint(5) unsigned NOT NULL,
@@ -14642,4 +14689,5 @@
   KEY item (item_id)
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -14882,4 +14930,6 @@
 
 DROP TABLE IF EXISTS pokemon_moves;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE pokemon_moves (
   pokemon_id smallint(5) unsigned NOT NULL default '0',
@@ -14893,5 +14943,6 @@
   KEY MOVEID USING BTREE (move_id),
   KEY VERSION USING BTREE (versions)
-) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
@@ -54114,4 +54165,6 @@
 
 DROP TABLE IF EXISTS types;
+SET @saved_cs_client     = @@character_set_client;
+SET character_set_client = utf8;
 CREATE TABLE `types` (
   `name` varchar(8) NOT NULL default '',
@@ -54125,4 +54178,5 @@
   PRIMARY KEY  (`name`)
 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+SET character_set_client = @saved_cs_client;
 
 --
