* (bug 21030) Fixed schema choices from being overwritten by defining unique field...
authorOverlordQ <overlordq@users.mediawiki.org>
Wed, 7 Oct 2009 08:47:02 +0000 (08:47 +0000)
committerOverlordQ <overlordq@users.mediawiki.org>
Wed, 7 Oct 2009 08:47:02 +0000 (08:47 +0000)
RELEASE-NOTES
config/Installer.php

index 2f2d34b..d13dddf 100644 (file)
@@ -546,6 +546,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN
 * (bug 20524) Hideuser: Show nice error when trying to block hidden user without 
   hideuser right
 * (bug 21026) Fixed file redirects on shared repos on non-English client wikis
+* (bug 21030) Fixed schema choices from being overwritten by defining unique field names per driver.
 
 == API changes in 1.16 ==
 
index 0a3c523..67e390b 100644 (file)
@@ -635,8 +635,8 @@ print "<li style='font-weight:bold;color:green;font-size:110%'>Environment check
 
        ## Postgres specific:
        $conf->DBport      = importPost( "DBport",      "5432" );
-       $conf->DBmwschema  = importPost( "DBmwschema",  "mediawiki" );
        $conf->DBts2schema = importPost( "DBts2schema", "public" );
+       $conf->DBpgschema  = importPost( "DBpgschema",  "mediawiki" );
        
        ## SQLite specific
        $conf->SQLiteDataDir = importPost( "SQLiteDataDir", "" );
@@ -648,8 +648,8 @@ print "<li style='font-weight:bold;color:green;font-size:110%'>Environment check
        ## DB2 specific:
        // New variable in order to have a different default port number
        $conf->DBport_db2   = importPost( "DBport_db2",      "50000" );
-       $conf->DBmwschema   = importPost( "DBmwschema",  "mediawiki" );
        $conf->DBcataloged  = importPost( "DBcataloged",  "cataloged" );
+       $conf->DBdb2schema  = importPost( "DBdb2schema",  "mediawiki" );
 
        // Oracle specific
        $conf->DBprefix_ora     = importPost( "DBprefix_ora" );
@@ -823,9 +823,14 @@ if( $conf->posted && ( 0 == count( $errs ) ) ) {
 
                ## Postgres specific:
                $wgDBport      = $conf->DBport;
-               $wgDBmwschema  = $conf->DBmwschema;
                $wgDBts2schema = $conf->DBts2schema;
 
+               if( $wgDBtype == 'postgres' ) {
+                       $wgDBmwschema = $conf->DBpgschema;
+               } elseif ( $wgDBtype == 'ibm_db2' ) {
+                       $wgDBmwschema = $conf->DBdb2schema;
+               }
+
                if( $conf->DBprefix2 != '' ) {
                        // For MSSQL
                        $wgDBprefix = $conf->DBprefix2;
@@ -1612,7 +1617,7 @@ if( count( $errs ) ) {
 
        <?php database_switcher('postgres'); ?>
        <div class="config-input"><?php aField( $conf, "DBport", "Database port:" ); ?></div>
-       <div class="config-input"><?php aField( $conf, "DBmwschema", "Schema for mediawiki:" ); ?></div>
+       <div class="config-input"><?php aField( $conf, "DBpgschema", "Schema for mediawiki:" ); ?></div>
        <div class="config-input"><?php aField( $conf, "DBts2schema", "Schema for tsearch2:" ); ?></div>
        <div class="config-desc">
                <p>The username specified above (at "DB username") will have its search path set to the above schemas, 
@@ -1655,7 +1660,7 @@ if( count( $errs ) ) {
                aField( $conf, "DBport_db2", "Database port:" );
        ?></div>
        <div class="config-input"><?php
-               aField( $conf, "DBmwschema", "Schema for mediawiki:" );
+               aField( $conf, "DBdb2schema", "Schema for mediawiki:" );
        ?></div>
        <div>Select one:</div>
                <ul class="plain">
@@ -1841,7 +1846,7 @@ function writeLocalSettings( $conf ) {
                $dbsettings =
 "# Postgres specific settings
 \$wgDBport           = \"{$slconf['DBport']}\";
-\$wgDBmwschema       = \"{$slconf['DBmwschema']}\";
+\$wgDBmwschema       = \"{$slconf['DBpgschema']}\";
 \$wgDBts2schema      = \"{$slconf['DBts2schema']}\";";
        } elseif( $conf->DBtype == 'sqlite' ) {
                $dbsettings =
@@ -1855,7 +1860,7 @@ function writeLocalSettings( $conf ) {
                $dbsettings =
 "# DB2 specific settings
 \$wgDBport_db2       = \"{$slconf['DBport_db2']}\";
-\$wgDBmwschema       = \"{$slconf['DBmwschema']}\";
+\$wgDBmwschema       = \"{$slconf['DBdb2schema']}\";
 \$wgDBcataloged      = \"{$slconf['DBcataloged']}\";";
        } elseif( $conf->DBtype == 'oracle' ) {
                $dbsettings =