[TikiWiki-commits] [Git][tikiwiki/tiki][master] [FIX] Database update: reduce tiki_comments index prefix length.
"Victor Emanouilov \(@kroky\) via TikiWiki-cvs" <[email protected]>
| Newsgroups | gmane.comp.cms.tiki.cvs |
|---|---|
| Message-ID | <692f0afec01a6_2a17c6904808a@gitlab-sidekiq-low-urgency-cpu-bound-v2-656c558bb4-ltncr.mail> |
Victor Emanouilov pushed to branch master at Tiki Wiki CMS Groupware / Tiki Commits: bb85d1d3 by Boss Ibrahim Mussa Gregoire at 2025-12-02T15:42:58+00:00 [FIX] Database update: reduce tiki_comments index prefix length. --- * [FIX] Database update: reduce index prefix length. See merge request tikiwiki/tiki!9148 - - - - - 2 changed files: - db/tiki.sql - + installer/schema/20251128_reduce_tiki_comments_index_prefix_lenght_tiki.sql Changes: ===================================== db/tiki.sql ===================================== @@ -724,14 +724,14 @@ CREATE TABLE `tiki_comments` ( `approved` char(1) NOT NULL default 'y', `locked` char(1) NOT NULL default 'n', PRIMARY KEY (`threadId`), - UNIQUE KEY `no_repeats` (`parentId`, `userName`(40), `title`(43), `commentDate`, `message_id`(40), `in_reply_to`(40)), + UNIQUE KEY `no_repeats` (`parentId`, `userName`(20), `title`(30), `commentDate`, `message_id`(30), `in_reply_to`(30)), KEY `title` (`title`(191)), KEY `data` (`data`(191)), KEY `hits` (hits), KEY `tc_pi` (`parentId`), KEY `objectType` (object(160), `objectType`), KEY `commentDate` (`commentDate`), - KEY `threaded` (message_id(89), in_reply_to(88), `parentId`), + KEY `threaded` (message_id(40), in_reply_to(40), `parentId`), KEY `idx_slvn_commentDate` (`commentDate`) ) ENGINE=MyISAM AUTO_INCREMENT=1 ; ===================================== installer/schema/20251128_reduce_tiki_comments_index_prefix_lenght_tiki.sql ===================================== @@ -0,0 +1,4 @@ +ALTER TABLE `tiki_comments` DROP INDEX `threaded`; +ALTER TABLE `tiki_comments` ADD KEY `threaded` (`message_id`(40),`in_reply_to`(40),`parentId`); +ALTER TABLE tiki_comments DROP INDEX no_repeats; +ALTER TABLE tiki_comments ADD UNIQUE KEY no_repeats ( parentId, userName(20), title(30), commentDate, message_id(30), in_reply_to(30)); \ No newline at end of file View it on GitLab: https://gitlab.com/tikiwiki/tiki/-/commit/bb85d1d32b5c80e898b2f30dd09bd7ff75f8aca4 -- View it on GitLab: https://gitlab.com/tikiwiki/tiki/-/commit/bb85d1d32b5c80e898b2f30dd09bd7ff75f8aca4 You're receiving this email because of your account on gitlab.com. _______________________________________________ TikiWiki-cvs mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/tikiwiki-cvs