Zend_Db_Table_Abstract::delete PHP Method

delete() public method

Deletes existing rows.
public delete ( array | string $where ) : integer
$where array | string SQL WHERE clause(s).
return integer The number of rows deleted.
    public function delete($where)
    {
        $tableSpec = ($this->_schema ? $this->_schema . '.' : '') . $this->_name;
        return $this->_db->delete($tableSpec, $where);
    }

Usage Example

Example #1
0
 /**
  * delete row(s)         
  * 
  * @param  array $data 
  * @return int
  */
 public function delete($id)
 {
     //delete permission of the resource
     $permissions = new Controlmodule_Model_DbTable_Permissions();
     $permissions->delete("resource_id=" . (int) $id);
     return parent::delete('id = ' . (int) $id);
 }
All Usage Examples Of Zend_Db_Table_Abstract::delete