Last modified: 2007-06-05 00:28:59 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 10104 - Database->getLag uses mysqlisms, not overridden for pgsql
Database->getLag uses mysqlisms, not overridden for pgsql
Product: MediaWiki
Classification: Unclassified
Database (Other open bugs)
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
: patch, patch-need-review
Depends on:
  Show dependency treegraph
Reported: 2007-06-02 02:24 UTC by Chuck Adams
Modified: 2007-06-05 00:28 UTC (History)
2 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Description Chuck Adams 2007-06-02 02:24:39 UTC
Special:Contributions (and other pages I'm told) call Database->getLag, which runs a sql command of SHOW PROCESSLIST which is a mysqlism.  I overrode it with a stub in DatabasePostgres.php to make it work:

Index: includes/DatabasePostgres.php
--- includes/DatabasePostgres.php       (revision 22629)
+++ includes/DatabasePostgres.php       (working copy)
@@ -1178,7 +1178,12 @@
                return true;

+       function getLag() {
+               wfDebug( "Function getLag() not written for DatabasePostgres.php yet");
+               return false;
+       }

 } // end DatabasePostgres class

Comment 1 Tim Starling 2007-06-03 09:29:30 UTC
MySQL-specific code should be in DatabaseMysql, not in the parent class. The parent class should contain database-independent code and stubs only. 
Comment 2 Rob Church 2007-06-04 21:43:40 UTC
Stub functions returning 0 added for Oracle and PostgreSQL in r22721. DatabaseMysql doesn't seem to exist any more; there is no clean parent class. :(

Note You need to log in before you can comment on or make changes to this bug.