deletes rows

@param string $where_part
@return int
960334
function DeleteObject($where_part, $table)
    {
        if (!$where_part or !$table or $this->lock_mod_data) {
            return 0;
        }

        $query = "DELETE FROM $table WHERE ".$where_part;

        return $this->Query($query);
    }
1288404
public function delete ($where)
    {
        $complement = Helper::complement($where);
        $this->_fields = array_filter($this->_fields, $complement);
    }
340139
function delete() {

        // if this is an association result or it is limited,
        // create specific result for local rows and execute

        if ( $this->parent_ || isset( $this->limitCount ) ) {

            return $this->primaryResult()->delete();

        }

        return $this->db->delete( $this->table, $this->where, $this->whereParams );

    }
640251
final public function delete( array $where, $table = '', $place_holders = [] ) {
		if ( ! $place_holders ) {
			try {
				$place_holders = $this->get_place_holders( $where );
			} catch ( \Exception $e ) {
				return false;
			}
		}
		return $this->db->delete( $table ?: $this->table, $where, $place_holders );
	}
301237
public function delete($where)
    {
        $tableSpec = ($this->_schema ? $this->_schema . '.' : '') . $this->_name;
        return $this->_db->delete($tableSpec, $where);
    }
824429
function deleteWhere($table_name, $where_with_placeholders, $named_parameters) {

            if (empty($where_with_placeholders) || !$table_name) {
                return false;
            }

            $sql_query = 'DELETE FROM ' . $table_name . ' WHERE ' . $where_with_placeholders;

            Event::dispatch(EventData::forBefore(Event::BEFORE_DELETE, $table_name, $named_parameters, $sql_query));
            try {
                //Run Delete query, collect stats
                $stmt = $this->db_connection->prepare($sql_query);
                if (!empty($named_parameters)) {
                    foreach ($named_parameters as $k => $v) {
                        $stmt->bindValue($k, $v);
                    }
                }

                $stmt->execute();
            } catch (Exception $ex) {
                Event::dispatch(EventData::forException($ex, $sql_query, $named_parameters));

                throw new QueryException($ex->getMessage(), $ex->getCode(), $ex);
            }

            $rows_affected = $stmt->rowCount();
            Event::dispatch(EventData::forAfter(Event::AFTER_DELETE, $table_name, $named_parameters, $sql_query, $rows_affected));

            return $rows_affected;

        }
201997
public function GetCountWhere($Wheres = '') {
      if (is_array($Wheres))
         $this->SQL->Where($Wheres);
         
      $Data = $this->SQL
         ->Select('MessageID', 'count', 'Count')
         ->From('ConversationMessage')
         ->Get();
         
      if ($Data->NumRows() > 0)
         return $Data->FirstRow()->Count;
      
      return 0;
   }
1278559
function delete($table, $where, $where_params)
    {
        $sql = "DELETE FROM " . $table . $this->buildWhere($where);
        $stmt = $this->executeQuery($sql, $where_params);

        return $stmt;
    }
362075
public function delete()
    {
        // Define wheres
        $where = $this->getWhereString();

        // Define where in
        $whereIn = $this->getWhereInString();

        // Build query
        $this->query = 'DELETE FROM ' . $this->table . ' '. $where . ' ' . $whereIn;

        // Prepare statement
        $this->statement = $this->pdo->prepare($this->query);

        // Bind where values
        if (count($this->wheres)) {
            $this->bindWheres();
        }

        // Execute statement
        $result = $this->statement->execute();

        // Reset values
        $this->reset();

        // Return result
        return $result;
    }
933739
public final function Delete(Sql\Condition $where, Sql\OrderList $orderBy = null, $offset = 0, $count = 0)
    {
        $sql = $this->SqlBuilder();
        $delete = $sql->Delete($this->Table(), $where, $orderBy, $offset, $count);
        $this->Connection()->ExecuteQuery((string)$delete);
    }
690391
function delete_all($with_groups = false)
    {
        $this->cache = null;

        $now = $this->db->now();

        $this->db->query("UPDATE " . $this->db->table_name($this->db_name, true)
            . " SET `del` = 1, `changed` = $now"
            . " WHERE `user_id` = ?", $this->user_id);

        $count = $this->db->affected_rows();

        if ($with_groups) {
            $this->db->query("UPDATE " . $this->db->table_name($this->db_groups, true)
                . " SET `del` = 1, `changed` = $now"
                . " WHERE `user_id` = ?", $this->user_id);

            $count += $this->db->affected_rows();
        }

        return $count;
    }
667805
public function delete($tableName, $where = null)
    {
        list($where, $params) = $this->_buildWhere($where);
        $query = "DELETE FROM $tableName $where";
        
        $stmt = $this->prepare($query);
        $stmt->execute($params);
        return $stmt;
    }
314994
public function deleteUrlAliasesWithoutLocation(): int
    {
        $dbPlatform = $this->connection->getDatabasePlatform();

        $subquery = $this->connection->createQueryBuilder();
        $subquery
            ->select('node_id')
            ->from('ezcontentobject_tree', 't')
            ->where(
                $subquery->expr()->eq(
                    't.node_id',
                    sprintf(
                        'CAST(%s as %s)',
                        $dbPlatform->getSubstringExpression($this->table . '.action', 8),
                        $this->getIntegerType($dbPlatform)
                    )
                )
            )
        ;

        $deleteQuery = $this->connection->createQueryBuilder();
        $deleteQuery
            ->delete($this->table)
            ->where(
                $deleteQuery->expr()->eq(
                    'action_type',
                    $deleteQuery->createPositionalParameter('eznode')
                )
            )
            ->andWhere(
                sprintf('NOT EXISTS (%s)', $subquery->getSQL())
            )
        ;

        return $deleteQuery->execute();
    }
144486
public function delete(): int
    {
        $this->builder->setDeleteAction();
        $sql = $this->builder->buildSql();
        $this->builder = new QueryBuilder($this->pdo);
        return $this->execSql($sql);
    }
889601
public function GetDelete($Table, $Where, &$Data) {
      if (is_array($Data)) {
         // Grab the records.
         $Result = $this->SQL->GetWhere($Table, $Where)->ResultArray();
         
         if (empty($Result))
            return;
         
         // Put the records in the result array.
         if (isset($Data[$Table])) {
            $Data[$Table] = array_merge($Data[$Table], $Result);
         } else {
            $Data[$Table] = $Result;
         }
      }
      
      $this->SQL->Delete($Table, $Where);
   }
791592
public function deleteWhere(array $where)
    {
        $this->applyScope();

        $this->applyConditions($where);

        $deleted = $this->model->delete();

        event(new RepositoryEntityDeleted($this, $this->model->getModel()));

        $this->resetModel();

        return $deleted;
    }
910522
public function deletePDO($table, array $where = array(), $limit = 1)
    {
        $limit = (int)$limit;
        if (count($where) === 0) {
            return false;
        }
        $q = "DELETE FROM `$table` ";
        $q .= 'WHERE ';
        foreach ($where as $key => $val) {
            if (empty($val)) {
                continue;
            } else {
                $q .= "`$key`=? AND ";
            }
        }
        $q = rtrim($q, 'AND ');
        if ($limit > 0) {
            $q .= ' LIMIT ' . $limit . ' ;';
        } else {
            $q .= ' ;';
        }
        try {
            $this->_queryId = self::$_linkId->prepare($q);
            $i = 1;
            foreach ($where as $key => $val) {
                if (empty($val)) {
                    continue;
                } else {
                    $type = $this->getPDOConstantType($val);
                    $this->_queryId->bindValue($i, $val, $type);
                    ++$i;
                }
            }
            return $this->_queryId->execute();
        } catch (PDOException $e) {
            $this->_error = $e->getMessage();
            return false;
        }
    }