From e6607783e9d9a2576e91e1c7e0876c9c80abdd60 Mon Sep 17 00:00:00 2001 From: gmcferrin Date: Sat, 12 Jan 2013 01:43:40 -0500 Subject: [PATCH] One last time... --- src/main/java/com/gmail/nossr50/util/Database.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/com/gmail/nossr50/util/Database.java b/src/main/java/com/gmail/nossr50/util/Database.java index 24e0cb8f5..985a73869 100644 --- a/src/main/java/com/gmail/nossr50/util/Database.java +++ b/src/main/java/com/gmail/nossr50/util/Database.java @@ -86,7 +86,7 @@ public class Database { write("CREATE TABLE IF NOT EXISTS `" + tablePrefix + "huds` (" + "`user_id` int(10) unsigned NOT NULL," + "`hudtype` varchar(50) NOT NULL DEFAULT 'STANDARD'," - + "PRIMARY KEY (`user_id`)" + + "PRIMARY KEY (`user_id`)," + "FOREIGN KEY (`user_id`) REFERENCES `" + tablePrefix + "users` (`id`) " + "ON DELETE CASCADE) ENGINE=MyISAM DEFAULT CHARSET=latin1;"); write("CREATE TABLE IF NOT EXISTS `" + tablePrefix + "cooldowns` (" @@ -103,7 +103,7 @@ public class Database { + "`axes` int(32) unsigned NOT NULL DEFAULT '0'," + "`acrobatics` int(32) unsigned NOT NULL DEFAULT '0'," + "`blast_mining` int(32) unsigned NOT NULL DEFAULT '0'," - + "PRIMARY KEY (`user_id`)" + + "PRIMARY KEY (`user_id`)," + "FOREIGN KEY (`user_id`) REFERENCES `" + tablePrefix + "users` (`id`) " + "ON DELETE CASCADE) ENGINE=MyISAM DEFAULT CHARSET=latin1;"); write("CREATE TABLE IF NOT EXISTS `" + tablePrefix + "skills` (" @@ -119,7 +119,7 @@ public class Database { + "`swords` int(10) unsigned NOT NULL DEFAULT '0'," + "`axes` int(10) unsigned NOT NULL DEFAULT '0'," + "`acrobatics` int(10) unsigned NOT NULL DEFAULT '0'," - + "PRIMARY KEY (`user_id`)" + + "PRIMARY KEY (`user_id`)," + "FOREIGN KEY (`user_id`) REFERENCES `" + tablePrefix + "users` (`id`) " + "ON DELETE CASCADE) ENGINE=MyISAM DEFAULT CHARSET=latin1;"); write("CREATE TABLE IF NOT EXISTS `" + tablePrefix + "experience` (" @@ -135,7 +135,7 @@ public class Database { + "`swords` int(10) unsigned NOT NULL DEFAULT '0'," + "`axes` int(10) unsigned NOT NULL DEFAULT '0'," + "`acrobatics` int(10) unsigned NOT NULL DEFAULT '0'," - + "PRIMARY KEY (`user_id`)" + + "PRIMARY KEY (`user_id`)," + "FOREIGN KEY (`user_id`) REFERENCES `" + tablePrefix + "users` (`id`) " + "ON DELETE CASCADE) ENGINE=MyISAM DEFAULT CHARSET=latin1;");