<?php
+# $Id$
# See deferred.doc
class SearchUpdate {
function doUpdate()
{
- global $wgDBminWordLen, $wgLang, $wgDisableSearchUpdate;
+ global $wgDBminWordLen, $wgLang, $wgDisableSearchUpdate, $wgIsMySQL;
if( $wgDisableSearchUpdate || !$this->mId ) {
return false;
$lc = SearchEngine::legalSearchChars() . "&#;";
if( $this->mText == false ) {
# Just update the title
- $sql = "UPDATE LOW_PRIORITY searchindex SET si_title='" .
+ $lowpri=$wgIsMySQL?"LOW_PRIORITY":"";
+ $sql = "UPDATE $lowpri searchindex SET si_title='" .
wfStrencode( Title::indexTitle( $this->mNamespace, $this->mTitle ) ) .
"' WHERE si_page={$this->mId}";
wfQuery( $sql, DB_WRITE, "SearchUpdate::doUpdate" );
<?php
+# $Id$
# See deferred.doc
class SiteStatsUpdate {
function doUpdate()
{
+ global $wgIsMySQL;
$a = array();
if ( $this->mViews < 0 ) { $m = "-1"; }
else if ( $this->mGood > 0 ) { $m = "+1"; }
else $m = "";
array_push( $a, "ss_good_articles=(ss_good_articles$m)" );
-
- $sql = "UPDATE LOW_PRIORITY site_stats SET " . implode ( ",", $a ) .
+ $lowpri=$wgIsMySQL?"LOW_PRIORITY":"";
+ $sql = "UPDATE $lowpri site_stats SET " . implode ( ",", $a ) .
" WHERE ss_row_id=1";
wfQuery( $sql, DB_WRITE, "SiteStatsUpdate::doUpdate" );
}
<?php
+# $Id$
# See deferred.doc
-
class ViewCountUpdate {
var $mPageID;
function doUpdate()
{
- global $wgDisableCounters;
+ global $wgDisableCounters, $wgIsMySQL;
if ( $wgDisableCounters ) { return; }
-
- $sql = "UPDATE LOW_PRIORITY cur SET cur_counter=(1+cur_counter)," .
+ $lowpri=$wgIsMySQL?"LOW_PRIORITY":"";
+ $sql = "UPDATE $lowpri cur SET cur_counter=(1+cur_counter)," .
"cur_timestamp=cur_timestamp WHERE cur_id={$this->mPageID}";
$res = wfQuery( $sql, DB_WRITE, "ViewCountUpdate::doUpdate" );
}
}
-
?>