cvs: pear(MDB_1) /MDB/MDB mssql.php
| From: | Lukas Smith | Date: | Wed, 10 Dec 2003 18:10:06 +0000 |
| Subject: | cvs: pear(MDB_1) /MDB/MDB mssql.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-14772@lists.php.net to get a copy of this message | ||
lsmith Wed Dec 10 13:10:06 2003 EDT
Modified files: (Branch: MDB_1)
/pear/MDB/MDB mssql.php
Log:
- fixed bug in fetchInto() that was introduced in version 1.6.4.15
Index: pear/MDB/MDB/mssql.php
diff -u pear/MDB/MDB/mssql.php:1.6.4.16 pear/MDB/MDB/mssql.php:1.6.4.17
--- pear/MDB/MDB/mssql.php:1.6.4.16 Wed Dec 10 13:03:46 2003
+++ pear/MDB/MDB/mssql.php Wed Dec 10 13:10:05 2003
@@ -43,7 +43,7 @@
// | Author: Frank M. Kromann <frank@kromann.info> |
// +----------------------------------------------------------------------+
//
-// $Id: mssql.php,v 1.6.4.16 2003/12/10 18:03:46 lsmith Exp $
+// $Id: mssql.php,v 1.6.4.17 2003/12/10 18:10:05 lsmith Exp $
//
require_once('MDB/Common.php');
@@ -1212,16 +1212,17 @@
*/
function fetchInto($result, $fetchmode = MDB_FETCHMODE_DEFAULT, $rownum = NULL)
{
- if ($rownum == NULL) {
+ if (is_null($rownum)) {
++$this->highest_fetched_row[$result];
} else {
+ $this->highest_fetched_row[$result] =
+ max($this->highest_fetched_row[$result], $rownum);
if (isset($this->limits[$result])) {
- $row = $rownum + $this->limits[$result][0];
+ $rownum = $rownum + $this->limits[$result][0];
}
if (!@mssql_data_seek($result, $rownum)) {
return(NULL);
}
- $this->highest_fetched_row[$result] = max($this->highest_fetched_row[$result],
$rownum);
}
if ($fetchmode == MDB_FETCHMODE_DEFAULT) {
$fetchmode = $this->fetchmode;