cvs: pear /DB/DB common.php mysql.php oci8.php
| From: | Daniel Convissor | Date: | Mon, 21 Feb 2005 20:30:51 +0000 |
| Subject: | cvs: pear /DB/DB common.php mysql.php oci8.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-29640@lists.php.net to get a copy of this message | ||
danielc Mon Feb 21 15:30:51 2005 EDT
Modified files:
/pear/DB/DB common.php mysql.php oci8.php
Log:
* Change name of option from "buffer" to "result_buffering."
* Change default value of result_buffering to to 500.
* To use unbuffered queries in mysql, use 0 instead of 1.
http://cvs.php.net/diff.php/pear/DB/DB/common.php?r1=1.130&r2=1.131&ty=u
Index: pear/DB/DB/common.php
diff -u pear/DB/DB/common.php:1.130 pear/DB/DB/common.php:1.131
--- pear/DB/DB/common.php:1.130 Sun Feb 20 11:29:19 2005
+++ pear/DB/DB/common.php Mon Feb 21 15:30:49 2005
@@ -20,7 +20,7 @@
* @author Daniel Convissor <danielc@php.net>
* @copyright 1997-2005 The PHP Group
* @license http://www.php.net/license/3_0.txt
PHP License 3.0
- * @version CVS: $Id: common.php,v 1.130 2005/02/20 16:29:19 danielc Exp $
+ * @version CVS: $Id: common.php,v 1.131 2005/02/21 20:30:49 danielc Exp $
* @link http://pear.php.net/package/DB
*/
@@ -79,7 +79,7 @@
* @see DB_common::setOption()
*/
var $options = array(
- 'buffer' => 1000,
+ 'result_buffering' => 500,
'persistent' => false,
'ssl' => false,
'debug' => 0,
@@ -514,10 +514,10 @@
* <br />should results be freed automatically when there are no
* more rows?
* </li><li>
- * <var>buffer</var> <kbd>integer</kbd> = <samp>1000</samp>
+ * <var>result_buffering</var> <kbd>integer</kbd> =
<samp>500</samp>
* <br />how many rows of the result set should be buffered?
* <br />In mysql: mysql_unbuffered_query() is used instead of
- * mysql_query() if this value is 1.
+ * mysql_query() if this value is 0.
* <br />In oci8: this value is passed to ocisetprefetch().
* </li><li>
* <var>debug</var> <kbd>integer</kbd> = <samp>0</samp>
http://cvs.php.net/diff.php/pear/DB/DB/mysql.php?r1=1.110&r2=1.111&ty=u
Index: pear/DB/DB/mysql.php
diff -u pear/DB/DB/mysql.php:1.110 pear/DB/DB/mysql.php:1.111
--- pear/DB/DB/mysql.php:1.110 Sun Feb 20 11:29:19 2005
+++ pear/DB/DB/mysql.php Mon Feb 21 15:30:49 2005
@@ -20,7 +20,7 @@
* @author Daniel Convissor <danielc@php.net>
* @copyright 1997-2005 The PHP Group
* @license http://www.php.net/license/3_0.txt
PHP License 3.0
- * @version CVS: $Id: mysql.php,v 1.110 2005/02/20 16:29:19 danielc Exp $
+ * @version CVS: $Id: mysql.php,v 1.111 2005/02/21 20:30:49 danielc Exp $
* @link http://pear.php.net/package/DB
*/
@@ -283,7 +283,7 @@
* Sends a query to the database server
*
* Generally uses mysql_query(). If you want to use
- * mysql_unbuffered_query() set the "buffer" option to 1 using
+ * mysql_unbuffered_query() set the "result_buffering" option to 0 using
* setOptions().
*
* @param string the SQL query string
@@ -312,7 +312,7 @@
}
$this->transaction_opcount++;
}
- if ($this->options['buffer'] == 1) {
+ if (!$this->options['result_buffering']) {
$result = @mysql_unbuffered_query($query, $this->connection);
} else {
$result = @mysql_query($query, $this->connection);
http://cvs.php.net/diff.php/pear/DB/DB/oci8.php?r1=1.99&r2=1.100&ty=u
Index: pear/DB/DB/oci8.php
diff -u pear/DB/DB/oci8.php:1.99 pear/DB/DB/oci8.php:1.100
--- pear/DB/DB/oci8.php:1.99 Sun Feb 20 11:05:12 2005
+++ pear/DB/DB/oci8.php Mon Feb 21 15:30:49 2005
@@ -20,7 +20,7 @@
* @author Daniel Convissor <danielc@php.net>
* @copyright 1997-2005 The PHP Group
* @license http://www.php.net/license/3_0.txt
PHP License 3.0
- * @version CVS: $Id: oci8.php,v 1.99 2005/02/20 16:05:12 danielc Exp $
+ * @version CVS: $Id: oci8.php,v 1.100 2005/02/21 20:30:49 danielc Exp $
* @link http://pear.php.net/package/DB
*/
@@ -285,7 +285,7 @@
* Sends a query to the database server
*
* To determine how many rows of a result set get buffered using
- * ocisetprefetch(), see the "buffer" option in setOptions().
+ * ocisetprefetch(), see the "result_buffering" option in setOptions().
*
* @param string the SQL query string
*
@@ -315,7 +315,7 @@
if (DB::isManip($query)) {
return DB_OK;
} else {
- @ocisetprefetch($result, $this->options['buffer']);
+ @ocisetprefetch($result, $this->options['result_buffering']);
return $result;
}
}
@@ -590,7 +590,7 @@
* Executes a DB statement prepared with prepare().
*
* To determine how many rows of a result set get buffered using
- * ocisetprefetch(), see the "buffer" option in setOptions().
+ * ocisetprefetch(), see the "result_buffering" option in setOptions().
*
* @param resource $stmt a DB statement resource returned from prepare()
* @param mixed $data array, string or numeric data to be used in
@@ -657,7 +657,7 @@
if ($this->manip_query[(int)$stmt]) {
$tmp = DB_OK;
} else {
- @ocisetprefetch($stmt, $this->options['buffer']);
+ @ocisetprefetch($stmt, $this->options['result_buffering']);
$tmp =& new DB_result($this, $stmt);
}
return $tmp;