I am developing a web app using zend framework in which I want to enable my users to search from other users using zend fetchAll function. But its returning complete column and I want several values only. Here is my sample code:
$query=$table->select('id')->where("name LIKE ?",'%'.$str.'%')->limit(10);
$model=new Application_Model_Users();
$rowset=$model->getDbTable()->fetchAll($query)->toArray();
I want to get only name and some other columns. Its returning all columns including password too.:p
1 Answer