Good day.

It turned out that you need to find out the number of elements in the table, but output them using limit & offset .

Example of exhaust in json:

 { count: 106, data: [ { name: "Вася" }, { name: "Пупкин"} ] } 

Tried it differently. The last option is:

 $routesColl = Doctrine_Query::create() ->select('r.*') ->from('Routes r') ->addSelect('count(r.id) as count') ->where('r.creator=?', SessionManager::getInstance()->getUid()) ->offset($offset) ->limit($limit) ->orderBy('count DESC') ->execute(); 

But ... exhaust, unfortunately, not the same :-(

    0