![Antiguo](http://static.forosdelweb.com/fdwtheme/images/statusicon/post_old.gif)
17/05/2014, 13:21
|
![Avatar de Italico76](http://static.forosdelweb.com/customavatars/avatar175649_11.gif) | | | Fecha de Ingreso: abril-2007
Mensajes: 3.303
Antigüedad: 17 años, 10 meses Puntos: 292 | |
Respuesta: No muestra datos completos fetchRow() Segun el manual de ZEND, debes cambiar el modo:
Código PHP:
Ver original$select->setFetchMode(Zend_Db::FETCH_NUM); $rows = $stmt->fetchAll();
Cita: Changing the Fetch Mode
By default, the statement object returns rows of the result set as associative arrays, mapping column names to column values. You can specify a different format for the statement class to return rows, just as you can in the Adapter class. You can use the setFetchMode() method of the statement object to specify the fetch mode. Specify the fetch mode using Zend_Db class constants FETCH_ASSOC, FETCH_NUM, FETCH_BOTH, FETCH_COLUMN, and FETCH_OBJ. See this chapter for more information on these modes. Subsequent calls to the statement methods fetch() or fetchAll() use the fetch mode that you specify.
Example #7 Setting the fetch mode
$stmt = $db->query('SELECT * FROM bugs');
$stmt->setFetchMode(Zend_Db::FETCH_NUM);
$rows = $stmt->fetchAll();
echo $rows[0][0];
__________________ Salu2! |