From: Marcel Werk Date: Sun, 24 Nov 2013 15:04:24 +0000 (+0100) Subject: Fixed user rank issue X-Git-Tag: 2.0.0_RC_3~15 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=d2fbb3b58a63a6650d6ba56a6cafd00a2b30ac28;p=GitHub%2FWoltLab%2FWCF.git Fixed user rank issue Closes #1562 --- diff --git a/wcfsetup/setup/db/install.sql b/wcfsetup/setup/db/install.sql index e5bb8a78d7..ef7dd4260f 100644 --- a/wcfsetup/setup/db/install.sql +++ b/wcfsetup/setup/db/install.sql @@ -1255,7 +1255,7 @@ CREATE TABLE wcf1_user_profile_visitor ( DROP TABLE IF EXISTS wcf1_user_rank; CREATE TABLE wcf1_user_rank ( rankID INT(10) NOT NULL AUTO_INCREMENT PRIMARY KEY, - groupID INT(10), + groupID INT(10) NOT NULL, requiredPoints INT(10) NOT NULL DEFAULT 0, rankTitle VARCHAR(255) NOT NULL DEFAULT '', cssClassName VARCHAR(255) NOT NULL DEFAULT '', @@ -1483,7 +1483,7 @@ ALTER TABLE wcf1_user_profile_menu_item ADD FOREIGN KEY (packageID) REFERENCES w /* SQL_PARSER_OFFSET */ -ALTER TABLE wcf1_user_rank ADD FOREIGN KEY (groupID) REFERENCES wcf1_user_group (groupID) ON DELETE SET NULL; +ALTER TABLE wcf1_user_rank ADD FOREIGN KEY (groupID) REFERENCES wcf1_user_group (groupID) ON DELETE CASCADE; ALTER TABLE wcf1_user_activity_event ADD FOREIGN KEY (objectTypeID) REFERENCES wcf1_object_type (objectTypeID) ON DELETE CASCADE; ALTER TABLE wcf1_user_activity_event ADD FOREIGN KEY (userID) REFERENCES wcf1_user (userID) ON DELETE CASCADE;