Deletes existing rows.

@return int The number of rows deleted.
337071
public function delete()
    {
        $where = $this->_getWhereQuery();

        /**
         * Execute the DELETE (this may throw an exception)
         */
        $result = $this->_getTable()->delete($where);

        /**
         * Reset all fields to null to indicate that the row is not there
         */
        $this->_data = array_combine(
            array_keys($this->_data),
            array_fill(0, count($this->_data), null)
        );

        return $result;
    }
137346
public function delete()
    {
        $data = $this->getData();
        if (isset($this->currentId))
            unset($data[$this->currentKey]);
        elseif($this->documentEntries)
            $data = array_diff_key($data,$this->documentEntries);
        else
            $data = [];
        $this->documentEntries = array_values($data);
        return $this->databaseDocument->put($this->documentEntries) ? true : false;
    }
43057
public function delete() {
		if ($this->dbId()) {
			$this->db()->query('DELETE FROM `'.$this->table().'` WHERE `'.$this->idVar().'` = ?', [$this->dbId()]);
		} else {
			throw new Exception('Cannot delete. No ID was given.');
		}
		return $this;
	}
394238
public function delete () : bool
	{
        $dbObject  = Database::getInstance();
		$sqlQuery  = "DELETE FROM ".static::$tableName." WHERE id=";
		$sqlQuery .= $dbObject->escapeValue($this->id)." LIMIT 1";
		$dbObject->query($sqlQuery);
		static::$affectedRows = $dbObject->affectedRows();
		return ($dbObject->affectedRows() == 1) ? TRUE : FALSE;
	}
385635
public function count()
    {
        if ($this->numberOfRows === null) {
            if (is_array($this->rows)) {
                $this->numberOfRows = count($this->rows);
            } else {
                $this->numberOfRows = $this->query->count();
            }
        }
        return $this->numberOfRows;
    }
649154
public function destroy()
    {
        $table   = $this->_builder->table;
        $where   = $this->_builder->where;

        $builder = new Builder();
        $builder->prefix = "delete";
        $builder->fields = "";
        $builder->table  = $table;
        $builder->where  = $where;

        $cls = $this->_cls;
        return $cls::executePrepared($builder, $this->_vals)->rowCount()>0;
    }
1011160
public function delete()
    {
        $data = $this->sendRequest($this->getUri(), 'delete');

        return new Result($data, $this->getUri(), $this->client, get_called_class());
    }
262883
public function delete()
	{
		$query = $this->getDeleteQuery();

		$query->where($this->morphType, $this->getAttribute($this->morphType));

		return $query->delete();
	}
566397
public function delete_many()
        {
            // Build and return the full DELETE statement by concatenating
            // the results of calling each separate builder method.
            $query = $this->_joinIfNotEmpty(" ", array(
                "DELETE FROM",
                $this->_quoteIdentifier($this->_table_name),
                $this->_buildWhere(),
            ));

            return self::_execute($query, $this->_values, $this->_connection_name);
        }
671563
public function delete()
    {
        try {
            parent::delete();
            $query = 'DELETE FROM ' . $this->table . ' WHERE userID = ?';
            $stmt = $this->pdo->prepare($query);
            $stmt->execute(array($this->userID));
            return $stmt->rowCount() > 0;
        } catch(\PDOException $e) {
            return false;
        }
    }
750454
public function delete(): IResult
    {
        $builder = new DeleteBuilder($this);
        $sql = $builder->build();
        $result = $this->execute($sql);
        $this->__init();
        return $result;
    }
383765
public int deleteAll() throws SQLException {

		int count = 0;

		if (isTableExists()) {
			DeleteBuilder<GeometryIndex, GeometryIndexKey> db = deleteBuilder();
			PreparedDelete<GeometryIndex> deleteQuery = db.prepare();
			count = delete(deleteQuery);
		}

		return count;
	}
1050016
public function countRows() {
        try {
            $query = $this->db->prepare($this->q->get());
            $this->bindValues($query);
            $query->execute();
            $this->clear();

            return $query->rowCount();
        } catch(\PDOException $e) {
            $this->setError('d', $e->getMessage());
            return false;
        }
    }
144486
public function delete(): int
    {
        $this->builder->setDeleteAction();
        $sql = $this->builder->buildSql();
        $this->builder = new QueryBuilder($this->pdo);
        return $this->execSql($sql);
    }
239904
public function delete()
    {
        $query = $this->getDeleteQuery();

        $query->where($this->morphType, $this->morphClass);

        return $query->delete();
    }
1138133
public function delete()
    {
        $i = 0;
        foreach ($this->_models as $model) {
            $i += $this->dropTable($model);
        }

        return $i;
    }
806567
public function delete()
    {
        $query = $this->createQuery();
        $query->setAction('delete');
        $query->where($query->buildAndSet([$this->getTableKey(), '=', $this->id]));
        $result = $this->database->query($query);

        return $result ? true : false;
    }