From: Jure Kajzer Date: Thu, 5 Nov 2009 18:49:12 +0000 (+0000) Subject: removed x-codeBlob functions and modified blob handling acordingly X-Git-Tag: 1.31.0-rc.0~38962 X-Git-Url: http://git.cyclocoop.org/%22.%24h.%22?a=commitdiff_plain;h=e773c0d23ed0a61fbfa024d1426f03e8a553ee0d;p=lhc%2Fweb%2Fwiklou.git removed x-codeBlob functions and modified blob handling acordingly --- diff --git a/includes/db/DatabaseOracle.php b/includes/db/DatabaseOracle.php index 55c9c05089..6bf3e3fe06 100644 --- a/includes/db/DatabaseOracle.php +++ b/includes/db/DatabaseOracle.php @@ -276,9 +276,9 @@ class DatabaseOracle extends DatabaseBase { function doQuery($sql) { wfDebug("SQL: [$sql]\n"); - if (!mb_check_encoding($sql)) { - throw new MWException("SQL encoding is invalid"); - } +// if (!mb_check_encoding($sql)) { +// throw new MWException("SQL encoding is invalid\n$sql"); +// } //handle some oracle specifics //remove AS column/table/subquery namings @@ -478,8 +478,8 @@ class DatabaseOracle extends DatabaseBase { throw new DBUnexpectedError($this, "Cannot create LOB descriptor: " . $e['message']); } - if (is_object($val)) { - $lob[$col]->writeTemporary($val->getData()); + if ($col_type == 'BLOB') { //is_object($val)) { + $lob[$col]->writeTemporary($val); //->getData()); oci_bind_by_name($stmt, ":$col", $lob[$col], -1, SQLT_BLOB); } else { $lob[$col]->writeTemporary($val); @@ -952,13 +952,14 @@ class DatabaseOracle extends DatabaseBase { return str_replace("'", "''", $s); } +/* function encodeBlob($b) { - return new ORABlob($b); + return $b; //new ORABlob($b); } function decodeBlob($b) { return $b; //return $b->load(); } - +*/ function addQuotes( $s ) { global $wgLang; if (isset($wgLang->mLoaded) && $wgLang->mLoaded)