http://www.mediawiki.org/wiki/Special:Code/MediaWiki/58256

Revision: 58256
Author:   maxsem
Date:     2009-10-28 14:10:19 +0000 (Wed, 28 Oct 2009)

Log Message:
-----------
Create FTS3 table in installer, if possible

Modified Paths:
--------------
    branches/sqlite/config/Installer.php

Modified: branches/sqlite/config/Installer.php
===================================================================
--- branches/sqlite/config/Installer.php        2009-10-28 13:35:45 UTC (rev 
58255)
+++ branches/sqlite/config/Installer.php        2009-10-28 14:10:19 UTC (rev 
58256)
@@ -1268,7 +1268,7 @@
                        print " done.</li>\n";
                        
                
-                       if ($conf->DBtype == 'ibm_db2') {
+                       if ( $conf->DBtype == 'ibm_db2' ) {
                                // Now that table creation is done, make sure 
everything is committed
                                // Do this before doing inserts through API
                                if ($wgDatabase->lastError()) {
@@ -1279,6 +1279,10 @@
                                        print "<li>MediaWiki tables 
successfully created</li>\n";
                                        $wgDatabase->commit();
                                }
+                       } elseif ( $conf->DBtype == 'sqlite' ) {
+                               // Ensure proper searchindex format. We have to 
do that separately because
+                               // if SQLite is compiled without the FTS3 
module, table creation syntax will be invalid.
+                               sqlite_setup_searchindex();
                        }
 
                        print "<li>Initializing statistics...</li>\n";



_______________________________________________
MediaWiki-CVS mailing list
MediaWiki-CVS@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to