r89759 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r89758‎ | r89759 | r89760 >
Date:07:15, 9 June 2011
Author:freakolowsky
Status:ok
Tags:
Comment:
* wrapped table and dbname with addQuotes
Modified paths:
  • /branches/REL1_17/phase3/includes/db/DatabaseOracle.php (modified) (history)

Diff [purge]

Index: branches/REL1_17/phase3/includes/db/DatabaseOracle.php
@@ -936,9 +936,9 @@
937937 * Query whether a given table exists (in the given schema, or the default mw one if not given)
938938 */
939939 function tableExists( $table ) {
940 - $table = trim( $this->tableName($table), '"' );
941 - $owner = strtoupper( $this->mDBname );
942 - $SQL = "SELECT 1 FROM all_tables WHERE owner='$owner' AND table_name='$table'";
 940+ $table = $this->addQuotes( trim( $this->tableName($table), '"' ) );
 941+ $owner = $this->addQuotes( strtoupper( $this->mDBname ) );
 942+ $SQL = "SELECT 1 FROM all_tables WHERE owner=$owner AND table_name=$table";
943943 $res = $this->doQuery( $SQL );
944944 if ( $res ) {
945945 $count = $res->numRows();

Follow-up revisions

RevisionCommit summaryAuthorDate
r89761* merge r89759 from REL1_17 into trunk...freakolowsky08:43, 9 June 2011

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r89252* MFT r89250. only the tableExists function ad 1.17 already supports user-dbn...freakolowsky08:46, 1 June 2011

Status & tagging log