Drop the current table if it exists
197153
def drop():
    
    # Ensure the connection is up
    _State.connection()
    _State.table.drop(checkfirst=True)
    _State.metadata.remove(_State.table)
    _State.table = None
    _State.new_transaction()
703121
def OnTableChanged(self, event):
        """"""

        if hasattr(event, 'table'):
            self.Select(event.table)
            self.EnsureVisible(event.table)

        event.Skip()
770294
def delete_table(self, tablename):
        
        self.tables = filter(lambda x: x.name != tablename, self.tables)
1300785
def _drop(self, tree):
        
        tablename = tree.table
        kwargs = {}
        try:
            ret = self.connection.delete_table(tablename, **kwargs)
        except DynamoDBError as e:
            if e.kwargs["Code"] == "ResourceNotFoundException" and tree.exists:
                return False
            raise
        return True
12011
public function drop($table = '')
    {
        $tableName = '';

        $tableName = ($table !== '') ?
            $table : $this->tableName;

        $this->schema = strtoupper(__FUNCTION__).' TABLE IF EXISTS
        `'.$this->database.'`.`'.$tableName.'`'.PHP_EOL;

        return $this;
    }
250824
def drop_table(self, tablename, silent=False):
        
        if not silent and not self.is_table_existed(tablename):
            raise MonSQLException('TABLE %s DOES NOT EXIST' %tablename)

        self.__cursor.execute('DROP TABLE IF EXISTS %s' %(tablename))
        self.__db.commit()
1360923
def drop_db(url):
    
    parsed_url = urlparse(url)
    db_name = parsed_url.path
    db_name = db_name.strip("/")
    db = connect("postgresql://" + parsed_url.netloc)
    # check that db exists
    q = """SELECT 1 as exists
           FROM pg_database
           WHERE datname = '{db_name}'""".format(
        db_name=db_name
    )
    if db.query(q).fetchone():
        # DROP DATABASE must be run outside of a transaction
        conn = db.engine.connect()
        conn.execute("commit")
        conn.execute("DROP DATABASE " + db_name)
        conn.close()
517851
public function dropTable($table, $ifExists = true)
    {
        $this->queryBuilder->dropTable($table, $ifExists);
        return $this;
    }
379315
static void drop(CallInfo callInfo, DB db, String tableName) {
    String sql = String.format("DROP TABLE %s", tableName);
    db.access(callInfo, () -> {
      db.logSetup(callInfo, sql);
      try (WrappedStatement ws = db.compile(sql)) {
        PreparedStatement dropStmt = ws.getStatement();
        dropStmt.execute();
      }
      return 0; 
    });
  }
1223670
def drop(self):
        
        if self._is_dropped is False:
            self.table.drop(self.engine)
        self._is_dropped = True
601383
public function dropExistingTable($table)
    {
        echo "    > drop table $table if exists ...";
        $time = microtime(true);
        $this->db->createCommand('DROP TABLE IF EXISTS `' . $table . '`')->execute();
        echo " done (time: " . sprintf('%.3f', microtime(true) - $time) . "s)\n";
    }
254973
async def delete(self):
        
        await r.table_name(self.table_name) \
            .get(self.id) \
            .delete() \
            .run(await conn.get())
843551
function removeTable(opts: Options, change: Change): Change {
    const { value } = change;
    const { startKey } = value;

    return removeTableByKey(opts, change, startKey);
}
115362
def drop(self, ex):
    ""
    # todo: factor out inheritance logic (for readability)
    if ex.name not in self:
      if ex.ifexists: return
      raise KeyError(ex.name)
    table_ = self[ex.name]
    parent = table_.parent_table
    if table_.child_tables:
      if not ex.cascade:
        raise table.IntegrityError('delete_parent_without_cascade',ex.name)
      self.cascade_delete(ex.name)
    else: del self[ex.name]
    if parent: parent.child_tables.remove(table_)
1024179
def delete(self, name):
    '''
    
    '''
    conn = self._client.connect()
    conn.execute( self._table.delete().where(self._table.c.name==name) )
331813
def drop_column(self, name):
        
        if self.db.engine.dialect.name == 'sqlite':
            raise RuntimeError("SQLite does not support dropping columns.")
        name = normalize_column_name(name)
        with self.db.lock:
            if not self.exists or not self.has_column(name):
                log.debug("Column does not exist: %s", name)
                return

            self._threading_warn()
            self.db.op.drop_column(
                self.table.name,
                name,
                self.table.schema
            )
            self._reflect_table()
15082
def drop_column(self, table, name):
        """"""
        try:
            self.execute('ALTER TABLE {0} DROP COLUMN {1}'.format(wrap(table), name))
            self._printer('\tDropped column {0} from {1}'.format(name, table))
        except ProgrammingError:
            self._printer("\tCan't DROP '{0}'; check that column/key exists in '{1}'".format(name, table))
        return name