Issues

ZF-2597: Possibility to choose column in fetchCol

Description

Add possibility to choose column in function fetchCol I would like to choose for example index 3 or 'name' now it allways select first column


$connection->fetchCol($sql, $bind , $index);

Comments

I think, that fetchCol() is intended for sql queries like this:


SELECT nickname FROM Users;

Defined column is not good way to do this, you should optimize your queries to select just column you need.

Please categorize/fix as needed.

This doesn't appear to have been fixed in 1.5.0. Please update if this is not correct.

Reassigning as Ralph is the maintainer of Zend_Db

As noted in the comments, there is an easy way to accomplish this.