summaryrefslogtreecommitdiff
path: root/src/sql/mysql
diff options
context:
space:
mode:
Diffstat (limited to 'src/sql/mysql')
-rw-r--r--src/sql/mysql/createTables.sql1
-rw-r--r--src/sql/mysql/updates/update_13_to_14.sql11
2 files changed, 12 insertions, 0 deletions
diff --git a/src/sql/mysql/createTables.sql b/src/sql/mysql/createTables.sql
index eb62d869..42ccfa63 100644
--- a/src/sql/mysql/createTables.sql
+++ b/src/sql/mysql/createTables.sql
@@ -40,6 +40,7 @@ CREATE TABLE IF NOT EXISTS `mana_characters` (
`x` smallint(5) unsigned NOT NULL,
`y` smallint(5) unsigned NOT NULL,
`map_id` tinyint(3) unsigned NOT NULL,
+ `slot` smallint(5) unsigned NOT NULL,
--
PRIMARY KEY (`id`),
UNIQUE KEY `name` (`name`),
diff --git a/src/sql/mysql/updates/update_13_to_14.sql b/src/sql/mysql/updates/update_13_to_14.sql
new file mode 100644
index 00000000..ea5b7e25
--- /dev/null
+++ b/src/sql/mysql/updates/update_13_to_14.sql
@@ -0,0 +1,11 @@
+--
+-- Modify the table `mana_characters` to add the slot field.
+--
+
+ALTER TABLE `mana_characters` ADD COLUMN `slot` smallint(5) unsigned NOT NULL;
+
+-- Update database version.
+UPDATE mana_world_states
+SET value = '14',
+moddate = UNIX_TIMESTAMP()
+WHERE state_name = 'database_version';