Sets query instance with delete operation and table
344555
protected function setQuery()
    {
        $this->builder = $this->connection->createQueryBuilder();
        $this->builder->select([]);
        $this->builder->from($this->connection->quoteIdentifier($this->model->table()));
    }
669255
def delete(self, table_name, constraints=None):
    
    if constraints is None:
      constraints = "1=1"
    where, params = self.sql_writer.parse_constraints(constraints)
    sql = "delete from {0} where {1};".format(table_name, where)
    self.execute(sql, params)
246402
public void deleteInstance() {
    System.out.println("\nDeleting Instance");
    // [START bigtable_delete_instance]
    try {
      adminClient.deleteInstance(instanceId);
      System.out.println("Instance deleted: " + instanceId);
    } catch (NotFoundException e) {
      System.err.println("Failed to delete non-existent instance: " + e.getMessage());
    }
    // [END bigtable_delete_instance]
  }
1304177
def delete(self, table):
        
        self._table = table
        self._limit = None
        self._query = "DELETE FROM {0}".format(self._table)

        return self
1212213
@Deprecated
  public void deleteByQuery(Query query, RequestOptions requestOptions) throws AlgoliaException {
    this.deleteByQuery(query, 100000, requestOptions);
  }
36179
public static function delete($query)
    {
        static::applySchema();

        $key = static::getPrimaryKeyOrMainField();

        if ($key && !is_array($query)) {
            $query = [$key => $query];
        }

        $whereArray = [];
        if (isset($query['where'])) {
            $whereArray[] = $query['where'];
            unset($query['where']);
        }

        $params = [];

        foreach ($query as $field => $value) {
            $token = ':'.$field;
            $whereArray[] = "`{$field}` = {$token}";
            $params[$token] = $value;
        }

        $where = $whereArray
               ? 'WHERE '.implode(' AND ', $whereArray)
               : '';

        $table = static::getTable();
        $sql = "DELETE FROM {$table} {$where}";

        static::getDatabase()->execute($sql, $params);
    }
686905
async def delete(query):
    
    assert isinstance(query, peewee.Delete),\
        ("Error, trying to run delete coroutine"
         "with wrong query class %s" % str(query))

    cursor = await _execute_query_async(query)
    rowcount = cursor.rowcount

    await cursor.release()
    return rowcount
469410
def setQuery(self, query):
        
        if not query.isNull() and hash(query) == hash(self._query):
            return
        
        self._query = query
        
        if QueryCompound.typecheck(query):
            self.uiColumnDDL.hide()
            self.uiOperatorDDL.hide()
            
            # setup the compound editor
            editor = XLineEdit(self)
            editor.setReadOnly(True)
            editor.setText(query.name() + ' %s' % nativestring(query))
            editor.setHint(nativestring(query))
            
            self.setEditor(editor)
        
        else:
            self.uiColumnDDL.show()
            self.uiOperatorDDL.show()
            
            text = query.columnName()
            self.uiColumnDDL.setCurrentSchemaPath(nativestring(text))
            
            self.uiOperatorDDL.blockSignals(True)
            plug = self.currentPlugin()
            if plug:
                op = plug.operator(query.operatorType(), query.value())
                
                index = self.uiOperatorDDL.findText(op)
                if index != -1:
                    self.uiOperatorDDL.setCurrentIndex(index)
            
            self.uiOperatorDDL.blockSignals(False)
        
        self.refreshButtons()
935398
def delete *where
    sql, *binds = SQLHelper.delete(:table => name, :where => @query_where + where, :prepared => true)
    pstmt = prepare :delete, sql
    pstmt.send @update_method, *binds
  end
801604
public function delete(string $table) : QueryBuilder
    {
        $this->_query[] = "DELETE FROM";
        $this->_query[] = "`". $this->sanitize($table) ."`";

        return $this;
    }
423978
def delete(cls, uuid):
        """"""
        to_delete = Workflow.query.get(uuid)
        db.session.delete(to_delete)
362990
def setQuery(self, query):
        
        if not self.isNull() and hash(query) == hash(self.query()):
            return
        
        # add entries
        table = self.tableType()
        
        self.setUpdatesEnabled(False)
        self.blockSignals(True)
        self.clear()
        
        if query is None or table is None:
            self.setEnabled(False)
            self.setUpdatesEnabled(True)
            self.blockSignals(False)
            return
        else:
            self.setEnabled(True)
        
        # load the queries for this item
        if QueryCompound.typecheck(query):
            queries = query.queries()
            self.setCurrentJoiner(query.operatorType())
        else:
            queries = [query]
        
        self.uiNameTXT.setText(query.name())
        
        layout = self._entryWidget.layout()
        for index, query in enumerate(queries):
            widget = self.addEntry(query)
            widget.setFirst(index == 0)
            widget.setLast(index == (len(queries) - 1))
            widget.setJoiner(self.currentJoiner())
        
        self.setUpdatesEnabled(True)
        self.blockSignals(False)
1207863
def delete(self, obj):
        """"""
        del_id = obj.get_id()
        if not del_id:
            return

        cur = self._conn().cursor()

        tabname = obj.__class__.get_table_name()
        query = 'delete from %s where id = ?' % tabname
        cur.execute(query, (del_id,))

        self._conn().commit()
        cur.close()
1170361
public function delete($table = "")
    {
        if (empty($table)) {
            $table = $this->structure->tableName; // @codeCoverageIgnore
        }

        $this->table = $table;
        $this->queryType = self::QUERY_DELETE;

        return $this;
    }
1183278
def delete_many(self, query):
        
        items = self.find(query)
        result = [
            self.table.remove(where(u'_id') == item[u'_id'])
            for item in items
        ]

        if query == {}:
            # need to reset TinyDB's index for docs order consistency
            self.table._last_id = 0

        return DeleteResult(raw_result=result)
1295951
function Delete(Table $table, Condition $condition = null, OrderList $orderList = null, $offset = 0, $count = 0)
    {
        return parent::CreateDelete($table, $condition, $orderList, $offset, $count);
    }
147607
def delete(sql_params = "", *bindvars)
      delete_sql = "DELETE FROM \"#{@schema_name}\".\"#{@table_name}\" "
      case sql_params
      when String
        delete_sql << sql_params
      when Hash
        raise ArgumentError, "Cannot specify bind variables when passing WHERE conditions as Hash" unless bindvars.empty?
        where_sqls = []
        sql_params.each do |k, v|
          where_sqls << "#{k} = :#{k}"
          bindvars << v
        end
        delete_sql << "WHERE " << where_sqls.join(" AND ") unless where_sqls.empty?
      else
        raise ArgumentError, "Only String or Hash can be provided as SQL condition argument"
      end
      @schema.execute(delete_sql, *bindvars)
    end