Ejemplo n.º 1
0
Archivo: Dao.php Proyecto: eryx/labs
 public function getCount($where)
 {
     $db = $this->getAdapter();
     $select = $db->select();
     $cols = $this->_getCols();
     $select->from($this->_name, 'count(*) as count');
     Core_Dao::buildSelectWhere($select, $where);
     try {
         $rs = $db->fetchRow($select);
     } catch (Exception $e) {
         throw $e;
     }
     return (int) $rs['count'];
 }