Deletes a migration

@param migrationName  - The name of the migration to be deleted
@param callback
765384
function(migrationName, callback) {
    var command = util.format('DELETE FROM %s where name = \'/%s\'', internals.migrationTable, migrationName);
    return this.runSql(command).nodeify(callback);
  }
1054301
function(callback) {
                if (db && !cacheDeletingInProgress) {
                    cacheDeletingInProgress = true;
                    db.threads
                        .where('owner')
                        .equals(userInfo.id)
                        .delete()
                        .then(function() {
                            console.log('threads table deleted');

                            db.contacts
                                .where('owner')
                                .equals(userInfo.id)
                                .delete()
                                .then(function() {
                                    console.log('contacts table deleted');

                                    db.messages
                                        .where('owner')
                                        .equals(userInfo.id)
                                        .delete()
                                        .then(function() {
                                            console.log('messages table deleted');

                                            db.participants
                                                .where('owner')
                                                .equals(userInfo.id)
                                                .delete()
                                                .then(function() {
                                                    console.log('participants table deleted');

                                                    db.messageGaps
                                                        .where('owner')
                                                        .equals(userInfo.id)
                                                        .delete()
                                                        .then(function() {
                                                            console.log('messageGaps table deleted');
                                                            cacheDeletingInProgress = false;
                                                            callback && callback();
                                                        });
                                                });
                                        });
                                });
                        })
                        .catch(function(error) {
                            fireEvent('error', {
                                code: error.code,
                                message: error.message,
                                error: error
                            });
                        });
                }
            }
1331941
public int delete(DatabaseConnection databaseConnection, T data, ObjectCache objectCache) throws SQLException {
		if (mappedDelete == null) {
			mappedDelete = MappedDelete.build(dao, tableInfo);
		}
		int result = mappedDelete.delete(databaseConnection, data, objectCache);
		if (dao != null && !localIsInBatchMode.get()) {
			dao.notifyChanges();
		}
		return result;
	}
352803
public function destroyField($name, $tableName, NodeTypeContract $nodeType)
    {
        $this->modelBuilder->build($tableName, $nodeType->getFields());
        $this->formBuilder->build($tableName, $nodeType->getFields());

        $migration = $this->migrationBuilder
            ->getMigrationClassPathByKey($tableName, $name);

        $this->migrateDown($migration);

        $this->migrationBuilder->destroyFieldMigrationForTable($name, $tableName);
    }
10913
public function migrate($migrationName) {
		$this->createTable();
		$this->db->dal()->into('_migrations')->insert(['name'=>$migrationName, 'migrated'=>date('Y-m-d H:i:s')]);
	}
470204
public function remove($migrationName) {
		$list = $this->getList(false);
		unset($list[$migrationName]);
		$this->writeMigrations($list);
	}
1773
protected function deleteIfNeeded($migration)
    {
        if (!$this->input->getOption('delete')) {
            return;
        }

        if ($this->migrator->deleteMigrationFile($migration)) {
            $this->message("<info>Deleted:</info> {$migration}.php");
        }
    }
793829
def delete_migration(connection, basename):
    

    # Prepare query
    sql = "DELETE FROM migrations_applied WHERE name = %s"

    # Run
    with connection.cursor() as cursor:
        cursor.execute(sql, (basename,))
        connection.commit()

    return True
1024981
protected boolean writeMigration(Migration dbMigration, String version) {
        if (migrationModel.isMigrationTableExist()) {
            scriptInfo = server.find(ScriptInfo.class, version);
            if (scriptInfo != null) {
                return false;
            }
        }
        scriptInfo = new ScriptInfo();
        scriptInfo.setRevision(version);
        try (StringWriter writer = new StringWriter()) {
            JAXBContext jaxbContext = JAXBContext.newInstance(Migration.class);
            Marshaller marshaller = jaxbContext.createMarshaller();
            marshaller.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, Boolean.TRUE);
            marshaller.marshal(dbMigration, writer);
            writer.flush();
            scriptInfo.setModelDiff(writer.toString());
        } catch (JAXBException | IOException e) {
            throw new RuntimeException(e);
        }
        return true;
    }
1181659
protected function runMigration($migration, $method)
    {
        $connection = $this->resolveConnection(
            $migration->getConnection()
        );

        $callback = function () use ($migration, $method) {
            if (method_exists($migration, $method)) {
                $migration->{$method}();
            }
        };

        $this->getSchemaGrammar($connection)->supportsSchemaTransactions()
            && $migration->withinTransaction
                    ? $connection->transaction($callback)
                    : $callback();
    }
850600
@Override
    public void deleteByColumn(String schemaName, String tableName, String columnName, Object columnValue)
    {
        if (!isOpen())
        {
            throw new PersistenceException("ThriftClient is closed.");
        }

        Connection conn = null;
        try
        {
            conn = getConnection();
            ColumnPath path = new ColumnPath(tableName);
            conn.getClient().remove(CassandraUtilities.toBytes(columnValue, columnValue.getClass()), path,
                    generator.getTimestamp(), getConsistencyLevel());

        }
        catch (InvalidRequestException e)
        {
            log.error("Error while deleting of column family {} for row key {}, Caused by: .", tableName, columnValue,
                    e);
            throw new KunderaException(e);
        }
        catch (TException e)
        {
            log.error("Error while deleting of column family {} for row key {}, Caused by: .", tableName, columnValue,
                    e);
            throw new KunderaException(e);
        }
        finally
        {
            releaseConnection(conn);
        }

    }
1109130
public function addNode($migrationName, $migrationObject)
    {
        $appName = $migrationObject->getAppLabel();
        $node = new Node($appName, $migrationName);

        // add to node store
        $this->nodes[$appName][$migrationName] = $migrationObject;

        // create family tree
        $this->nodeFamilyTree[$appName][$migrationName] = $node;
    }
876205
function(id, callback) {
    
    var self = this;
    
    if (typeof id == 'number' || id instanceof Array) {
      
      // Remove entry from database
      this.driver.deleteById({
        id: id,
        table: this.context
      }, function(err, results) {
        callback.call(self, err);
      });

    } else if (id && typeof id == 'object') {
      
      var o = id;
      
      this.driver.deleteWhere({
        condition: _.keys(o).join('=? AND ') + '=?',
        params: _.values(o),
        table: this.context
      }, function(err, results) {
        callback.call(self, err);
      });
      
    } else {
      
      callback.call(self, new Error(util.format("%s: Wrong value for `id` parameter", this.className)));
      
    }

  }
567765
function(callback) {
    var cqlString = 'SELECT * from migrations';
    return this.runSql(cqlString)
      .then(function(data) {
        var sortedData = data.rows.map(function(item) {
          item.moment_time = moment(item.ran_on).valueOf();
          return item
        });
        // Order migration records in ascending order.
        return sortedData.sort(function(x,y) {
          if (x.moment_time > y.moment_time) return -1;
          if (x.moment_time < y.moment_time) return 1;
          return 0;
        })
      })
      .nodeify(callback);
  }
1316014
public static void removeTrigger(String triggerName) throws SundialSchedulerException {

    try {
      getScheduler().unscheduleJob(triggerName);
    } catch (SchedulerException e) {
      throw new SundialSchedulerException("ERROR REMOVING TRIGGER!!!", e);
    }
  }
502893
protected function runMigration($migration, $method)
    {
        $callback = function () use ($migration, $method) {
            if (method_exists($migration, $method)) {
                $migration->{$method}();
            }
        };

        $callback();
    }
631415
public int deleteByTableName(String tableName) throws SQLException {
		DeleteBuilder<DataColumns, TableColumnKey> db = deleteBuilder();
		db.where().eq(DataColumns.COLUMN_TABLE_NAME, tableName);
		PreparedDelete<DataColumns> deleteQuery = db.prepare();
		int deleted = delete(deleteQuery);
		return deleted;
	}