ZF-6620: Zend_Application Db Resource - set fetch mode via config

Issue Type: Improvement Created: 2009-05-12T03:13:13.000+0000 Last Updated: 2010-10-20T19:11:00.000+0000 Status: Resolved Fix version(s): - 1.11.0 (02/Nov/10)

Reporter: David Caunt (dcaunt) Assignee: Ramon Henrique Ornelas (ramon) Tags: - Zend_Application

  • Zend_Db

Related issues: Attachments: - ZF-6620.patch


At the moment I have to do something like this to fetch objects rather than arrays from the database

<pre class="highlight"> 
protected function _initFetch(){

    $db = $this->getResource('db');



It would be great if the existing Db resource could take another config line like this

resources.db.fetchMode = 5


Posted by Clement Roux (stealth35) on 2010-09-26T12:30:51.000+0000

hi, try this patch :…


Posted by Ramon Henrique Ornelas (ramon) on 2010-09-26T16:46:16.000+0000

Improvement in patch and was added tests units.

Posted by Ramon Henrique Ornelas (ramon) on 2010-09-26T20:52:27.000+0000

Patch v2 validation of fetch_mode supported by adapters.

Posted by Ramon Henrique Ornelas (ramon) on 2010-10-20T19:10:58.000+0000

Fixed in trunk r23192, applied to release branch 1.11 r23193.

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.