From: Alexander Ebert Date: Tue, 8 Aug 2017 11:39:20 +0000 (+0200) Subject: Fixed experimental upgrade path X-Git-Tag: 3.1.0_Alpha_1~63 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e708b422a5f0d4b2b18f52cc8a010510e319ca36;p=GitHub%2FWoltLab%2FWCF.git Fixed experimental upgrade path --- diff --git a/com.woltlab.wcf/package.xml b/com.woltlab.wcf/package.xml index 55660ec4eb..2404d1fda7 100644 --- a/com.woltlab.wcf/package.xml +++ b/com.woltlab.wcf/package.xml @@ -59,15 +59,19 @@ - - + acp/update_com.woltlab.wcf_3.1_pageSearchIndex.php + + + + + diff --git a/com.woltlab.wcf/update_3.1.sql b/com.woltlab.wcf/update_3.1.sql index f9d8815648..692503eff6 100644 --- a/com.woltlab.wcf/update_3.1.sql +++ b/com.woltlab.wcf/update_3.1.sql @@ -18,16 +18,19 @@ ALTER TABLE wcf1_comment ADD COLUMN unfilteredResponses MEDIUMINT(7) NOT NULL DE ALTER TABLE wcf1_comment ADD COLUMN unfilteredResponseIDs VARCHAR(255) NOT NULL DEFAULT ''; ALTER TABLE wcf1_comment ADD COLUMN enableHtml TINYINT(1) NOT NULL DEFAULT 0; ALTER TABLE wcf1_comment ADD COLUMN isDisabled TINYINT(1) NOT NULL DEFAULT 0; --- WARNING: May be slow, use a separate request? -ALTER TABLE wcf1_comment DROP KEY (objectTypeID, objectID, time); --- WARNING: May be slow, use a separate request? + +-- WARNING: May be slow, use a separate request? // the foreign key relies on the index `objectTypeID` +ALTER TABLE wcf1_comment DROP FOREIGN KEY objectTypeID; +ALTER TABLE wcf1_comment DROP KEY objectTypeID; ALTER TABLE wcf1_comment ADD KEY (objectTypeID, objectID, isDisabled, time); +ALTER TABLE wcf1_comment ADD FOREIGN KEY (objectTypeID) REFERENCES wcf1_object_type (objectTypeID) ON DELETE CASCADE; ALTER TABLE wcf1_comment_response ADD COLUMN isDisabled TINYINT(1) NOT NULL DEFAULT 0; --- WARNING: May be slow, use a separate request? -ALTER TABLE wcf1_comment_response DROP KEY (commentID, time); --- WARNING: May be slow, use a separate request? +-- WARNING: May be slow, use a separate request? // the foreign key relies on the index `commentID` +ALTER TABLE wcf1_comment_response DROP FOREIGN KEY commentID; +ALTER TABLE wcf1_comment_response DROP KEY commentID; ALTER TABLE wcf1_comment_response ADD KEY (commentID, isDisabled, time); +ALTER TABLE wcf1_comment_response ADD FOREIGN KEY (commentID) REFERENCES wcf1_comment (commentID) ON DELETE CASCADE; DROP TABLE IF EXISTS wcf1_contact_option; CREATE TABLE wcf1_contact_option ( @@ -94,7 +97,6 @@ CREATE TABLE wcf1_page_box_order ( ALTER TABLE wcf1_paid_subscription_user ADD COLUMN sentExpirationNotification TINYINT(1) NOT NULL DEFAULT 0; -ALTER TABLE wcf1_style ADD isTainted TINYINT(1) NOT NULL DEFAULT 0; ALTER TABLE wcf1_style ADD hasFavicon TINYINT(1) NOT NULL DEFAULT 0; DROP TABLE IF EXISTS wcf1_trophy; diff --git a/wcfsetup/install/files/acp/update_com.woltlab.wcf_3.1_pageSearchIndex.php b/wcfsetup/install/files/acp/update_com.woltlab.wcf_3.1_pageSearchIndex.php new file mode 100644 index 0000000000..52f527d28d --- /dev/null +++ b/wcfsetup/install/files/acp/update_com.woltlab.wcf_3.1_pageSearchIndex.php @@ -0,0 +1,6 @@ +reset(); +SearchIndexManager::getInstance()->createSearchIndices();