/** * Drops the index specified by name from a database table. * * @param string $tableName * @param string $indexName * @return void */ public function dropIndexByName($tableName, $indexName) { $this->adapter->dropIndexByName($tableName, $indexName); }
/** * Adds the specified foreign key to a database table. * * @param TableMigrationInterface $table * @param ForeignKeyMigrationInterface $foreignKey * * @return TableMigrationInterface */ public function addForeignKey(TableMigrationInterface $table, ForeignKeyMigrationInterface $foreignKey) { $this->adapter->dropIndexByName($table, $foreignKey); return $this; }