Backing out 24448, 24455, 24456 for the moment.
authorBrion Vibber <brion@users.mediawiki.org>
Tue, 31 Jul 2007 14:40:35 +0000 (14:40 +0000)
committerBrion Vibber <brion@users.mediawiki.org>
Tue, 31 Jul 2007 14:40:35 +0000 (14:40 +0000)
Try not to slip in schema changes while everyone else is drinking pls :D

includes/Article.php
includes/Title.php
maintenance/archives/patch-page_key.sql [deleted file]
maintenance/tables.sql
maintenance/updaters.inc

index 2595299..48422f5 100644 (file)
@@ -262,7 +262,6 @@ class Article {
                                'page_id',
                                'page_namespace',
                                'page_title',
-                               'page_key',
                                'page_restrictions',
                                'page_counter',
                                'page_is_redirect',
@@ -1002,7 +1001,6 @@ class Article {
         * @private
         */
        function insertOn( $dbw ) {
-               global $wgContLang;
                wfProfileIn( __METHOD__ );
 
                $page_id = $dbw->nextSequenceValue( 'page_page_id_seq' );
@@ -1010,7 +1008,6 @@ class Article {
                        'page_id'           => $page_id,
                        'page_namespace'    => $this->mTitle->getNamespace(),
                        'page_title'        => $this->mTitle->getDBkey(),
-                       'page_key'          => $wgContLang->caseFold($this->mTitle->getDBkey()),
                        'page_counter'      => 0,
                        'page_restrictions' => '',
                        'page_is_redirect'  => 0, # Will set this shortly...
index 338fc0f..7a459bd 100644 (file)
@@ -2126,7 +2126,7 @@ class Title {
         *      be a redirect
         */
        private function moveOverExistingRedirect( &$nt, $reason = '' ) {
-               global $wgUseSquid, $wgContLang;
+               global $wgUseSquid;
                $fname = 'Title::moveOverExistingRedirect';
                $comment = wfMsgForContent( '1movedto2_redir', $this->getPrefixedText(), $nt->getPrefixedText() );
 
@@ -2156,7 +2156,6 @@ class Title {
                                'page_touched'   => $dbw->timestamp($now),
                                'page_namespace' => $nt->getNamespace(),
                                'page_title'     => $nt->getDBkey(),
-                               'page_key'       => $wgContLang->caseFold($nt->getDBkey()),
                                'page_latest'    => $nullRevId,
                        ),
                        /* WHERE */ array( 'page_id' => $oldid ),
@@ -2204,7 +2203,7 @@ class Title {
         * @param Title &$nt the new Title
         */
        private function moveToNewTitle( &$nt, $reason = '' ) {
-               global $wgUseSquid, $wgContLang;
+               global $wgUseSquid;
                $fname = 'MovePageForm::moveToNewTitle';
                $comment = wfMsgForContent( '1movedto2', $this->getPrefixedText(), $nt->getPrefixedText() );
                if ( $reason ) {
@@ -2227,7 +2226,6 @@ class Title {
                                'page_touched'   => $now,
                                'page_namespace' => $nt->getNamespace(),
                                'page_title'     => $nt->getDBkey(),
-                               'page_key'       => $wgContLang->caseFold($nt->getDBkey()),
                                'page_latest'    => $nullRevId,
                        ),
                        /* WHERE */ array( 'page_id' => $oldid ),
diff --git a/maintenance/archives/patch-page_key.sql b/maintenance/archives/patch-page_key.sql
deleted file mode 100644 (file)
index ce72a6a..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-ALTER TABLE /*$wgDBprefix*/page
-       ADD page_key VARCHAR(255) BINARY NOT NULL;
-ALTER TABLE /*$wgDBprefix*/page
-       ADD INDEX name_key (page_namespace, page_key);
-
index db8c036..e9d6afb 100644 (file)
@@ -190,9 +190,6 @@ CREATE TABLE /*$wgDBprefix*/page (
   -- Spaces are transformed into underscores in title storage.
   page_title varchar(255) binary NOT NULL,
   
-  -- page_title in uppercase.  Used for case-insensitive title searching.
-  page_key varchar(255) binary NOT NULL,
-
   -- Comma-separated set of permission keys indicating who
   -- can move or edit the page.
   page_restrictions tinyblob NOT NULL,
@@ -227,7 +224,6 @@ CREATE TABLE /*$wgDBprefix*/page (
 
   PRIMARY KEY page_id (page_id),
   UNIQUE INDEX name_title (page_namespace,page_title),
-  INDEX name_key (page_namespace, page_key),
   
   -- Special-purpose indexes
   INDEX (page_random),
index 9391fc2..2b04740 100644 (file)
@@ -82,7 +82,6 @@ $wgNewFields = array(
        array( 'oldimage',      'oi_metadata',      'patch-oi_metadata.sql'),
        array( 'archive',       'ar_page',          'patch-archive-ar_page.sql'),
        array( 'image',         'img_sha1',         'patch-img_sha1.sql' ),
-       array( 'page',          'page_key',         'patch-page_key.sql' ),
 );
 
 # For extensions only, should be populated via hooks