Zend framework : how to extract a column from mysql result set?

Posted by understack on Stack Overflow See other posts from Stack Overflow or by understack
Published on 2010-05-07T20:23:59Z Indexed on 2010/05/07 20:28 UTC
Read the original article Hit count: 156

What would be the best way to extract a column out of mysql results set? My result set is like:

[0] = ('id'=>1, 'name'=>a),
[1] = ('id'=>2, 'name'=>b),
[2] = ('id'=>3, 'name'=>c)

How can I extract 'name' column as an array from this? I can do it using for loop. But wondering if there are any better reusable solution?

© Stack Overflow or respective owner

Related posts about zend-framework

Related posts about php