names as $name) { if (!$schema->hasTable($name)) { continue; } $sql = "ALTER TABLE $name ENGINE=InnoDB"; $this->addSql($sql); error_log($sql); } } /** * @param Schema $schema * @throws \Doctrine\DBAL\DBALException * @throws \Doctrine\DBAL\Schema\SchemaException */ public function down(Schema $schema) { foreach ($this->names as $name) { if (!$schema->hasTable($name)) { continue; } $this->addSql("ALTER TABLE $name ENGINE=MyISAM"); } } }