ZF-6748: If index of row equals count of rows in seek(), exception is needed.

Issue Type: Bug Created: 2009-05-20T09:02:02.000+0000 Last Updated: 2011-08-04T09:48:55.000+0000 Status: Resolved Fix version(s): - 1.8.3 (09/Jun/09)

Reporter: Andrey V. Gorobets (andrey_most) Assignee: Satoru Yoshida (satoruyoshida) Tags: - Zend_Db_Table

Related issues: Attachments:


When you use index of Row equals count of rows in set, I didn't recieve exception. Need change condition in method seek of Zend_Db_Table_Rowset_Abstract class (Zend/Db/Table/Rowset/Abstract.php). ... (Line 325) if ($position < 0 || $position >= $this->_count) { .....


Posted by old of Satoru Yoshida ( on 2009-05-29T14:02:23.000+0000

Solved in SVN r15817

Posted by C Snover (snover) on 2009-07-14T12:28:27.000+0000

This patch has broken getRow after an iteration through the rowset.

<pre class="highlight">
$table = new Zend_Db_Table($config);
$rowset = $table->fetchAll($table->select()->limit(3));
foreach($rowset as $row) {}
$rowset->getRow(0); // exception, because $rowset->_pointer is now 3

Have you found an issue?

See the Overview section for more details.


© 2006-2018 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.