diff options
author | Yohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer> | 2010-09-15 19:54:00 +0200 |
---|---|---|
committer | Yohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer> | 2010-09-15 22:00:58 +0200 |
commit | c4b4c52fc1d26e52da8eda5f93c05e1ff2dd3eb2 (patch) | |
tree | 1bd07525455c4fa9cae936a3b7c6fb8d094efc86 /src/sql | |
parent | fa901d1cb94cdd47cb066402ae7e478154113306 (diff) | |
download | manaserv-c4b4c52fc1d26e52da8eda5f93c05e1ff2dd3eb2.tar.gz manaserv-c4b4c52fc1d26e52da8eda5f93c05e1ff2dd3eb2.tar.bz2 manaserv-c4b4c52fc1d26e52da8eda5f93c05e1ff2dd3eb2.tar.xz manaserv-c4b4c52fc1d26e52da8eda5f93c05e1ff2dd3eb2.zip |
Fixed characters not being returned at character selection when using MySQL.
The table mana_char_equips wasn't created due to an SQL error, this led
the account server to not return the player's characters.
Seen in the logs:
[19:40:41] [ERR] (DALStorage::getCharacter #1) SQL query failure:
Table 'bertram.mana_char_equips' doesn't exist
[19:40:41] [ERR] Failed to get character 11 for account 1.
Resolves: Manasource mantices: 189, 230.
Reviewed-by: Thorbjorn.
Diffstat (limited to 'src/sql')
-rw-r--r-- | src/sql/mysql/createTables.sql | 12 | ||||
-rw-r--r-- | src/sql/mysql/updates/update_10_to_11.sql | 12 |
2 files changed, 12 insertions, 12 deletions
diff --git a/src/sql/mysql/createTables.sql b/src/sql/mysql/createTables.sql index a76cc337..84a35308 100644 --- a/src/sql/mysql/createTables.sql +++ b/src/sql/mysql/createTables.sql @@ -181,14 +181,14 @@ AUTO_INCREMENT=1 ; -- table: `mana_char_equips` -- CREATE TABLE IF NOT EXISTS `mana_char_equips` ( - id int(10) unsigned NOT NULL auto_increment, - owner_id int(10) unsigned NOT NULL, - slot_type tinyint(3) unsigned NOT NULL, - inventory_slot tinyint(3) unsigned NOT NULL, + `id` int(10) unsigned NOT NULL auto_increment, + `owner_id` int(10) unsigned NOT NULL, + `slot_type` tinyint(3) unsigned NOT NULL, + `inventory_slot` tinyint(3) unsigned NOT NULL, -- PRIMARY KEY (`id`), - UNIQUE KEY `owner_id` (`owner_id`, ) - FOREIGN KEY (owner_id) REFERENCES mana_characters(id) + UNIQUE KEY `owner_id` (`owner_id`, `inventory_slot`), + FOREIGN KEY (`owner_id`) REFERENCES `mana_characters` (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; diff --git a/src/sql/mysql/updates/update_10_to_11.sql b/src/sql/mysql/updates/update_10_to_11.sql index 16408f45..5541b1da 100644 --- a/src/sql/mysql/updates/update_10_to_11.sql +++ b/src/sql/mysql/updates/update_10_to_11.sql @@ -35,14 +35,14 @@ DEFAULT CHARSET=utf8; -- table: `mana_char_equips` -- CREATE TABLE IF NOT EXISTS `mana_char_equips` ( - id int(10) unsigned NOT NULL auto_increment, - owner_id int(10) unsigned NOT NULL, - slot_type tinyint(3) unsigned NOT NULL, - inventory_slot tinyint(3) unsigned NOT NULL, + `id` int(10) unsigned NOT NULL auto_increment, + `owner_id` int(10) unsigned NOT NULL, + `slot_type` tinyint(3) unsigned NOT NULL, + `inventory_slot` tinyint(3) unsigned NOT NULL, -- PRIMARY KEY (`id`), - UNIQUE KEY `owner_id` (`owner_id`, ) - FOREIGN KEY (owner_id) REFERENCES mana_characters(id) + UNIQUE KEY `owner_id` (`owner_id`, `inventory_slot`), + FOREIGN KEY (`owner_id`) REFERENCES `mana_characters` (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; |