Drop unused patch-random-dateindex.sql

This patch was introduced in r1161 (February 2003) but it wasn't
mentioned in the patch-list.txt and checking git history since initial
version (phase3) didn't return any mention of it since then.

It clearly can't be ran on any modern mediawiki setup.

Change-Id: Ic5a8f0699dd31a181c31582be4958522ce3483b3
This commit is contained in:
Amir Sarabadani 2021-03-27 09:53:02 +01:00
parent 81ba51eb0e
commit f21644c8fe

View file

@ -1,54 +0,0 @@
-- patch-random-dateindex.sql
-- 2003-02-09
--
-- This patch does two things:
-- * Adds cur_random column to replace random table
-- (Requires change to SpecialRandom.php)
-- random table no longer needs refilling
-- Note: short-term duplicate results *are* possible, but very unlikely on large wiki
--
-- * Adds inverse_timestamp columns to cur and old and indexes
-- to allow descending timestamp sort in history, contribs, etc
-- (Requires changes to Article.php, DatabaseFunctions.php,
-- ... )
-- cur_timestamp inverse_timestamp
-- 99999999999999 - 20030209222556 = 79969790777443
-- 99999999999999 - 20030211083412 = 79969788916587
--
-- We won't need this on MySQL 4; there will be a removal patch later.
-- Indexes:
-- cur needs (cur_random) for random sort
-- cur and old need (namespace,title,timestamp) index for history,watchlist,rclinked
-- cur and old need (user,timestamp) index for contribs
-- cur and old need (user_text,timestamp) index for contribs
ALTER TABLE /*$wgDBprefix*/cur
DROP INDEX cur_user,
DROP INDEX cur_user_text,
ADD COLUMN cur_random real unsigned NOT NULL,
ADD COLUMN inverse_timestamp char(14) binary NOT NULL default '',
ADD INDEX (cur_random),
ADD INDEX name_title_timestamp (cur_namespace,cur_title,inverse_timestamp),
ADD INDEX user_timestamp (cur_user,inverse_timestamp),
ADD INDEX usertext_timestamp (cur_user_text,inverse_timestamp);
UPDATE /*$wgDBprefix*/cur SET
inverse_timestamp=99999999999999-cur_timestamp,
cur_random=RAND();
ALTER TABLE /*$wgDBprefix*/old
DROP INDEX old_user,
DROP INDEX old_user_text,
ADD COLUMN inverse_timestamp char(14) binary NOT NULL default '',
ADD INDEX name_title_timestamp (old_namespace,old_title,inverse_timestamp),
ADD INDEX user_timestamp (old_user,inverse_timestamp),
ADD INDEX usertext_timestamp (old_user_text,inverse_timestamp);
UPDATE /*$wgDBprefix*/old SET
inverse_timestamp=99999999999999-old_timestamp;
-- If leaving wiki publicly accessible in read-only mode during
-- the upgrade, comment out the below line; leave 'random' table
-- in place until the new software is installed.
DROP TABLE /*$wgDBprefix*/random;