Is there a way to get the total number of rows in Zend db select like with using SQL_CALC_FOUND_ROWS in a regular mysql query. I haven't been able to find a similar functionality for this apart from running the same query without the limit clause.
views:
20answers:
2
A:
Because no one else has anything better to offer I'll suggest to see this post on a ZF forum. It's from 2008 and ZF may have been upgraded since then.
Alin Purcaru
2010-10-23 08:45:42
A:
$db->select()
->from($tableName, array(
new Zend_Db_Expr('SQL_CALC_FOUND_ROWS id'),
'name',
'price'
));
Tomáš Fejfar
2010-10-23 10:55:16