addSql('ALTER TABLE software ADD type VARCHAR(255) NOT NULL'); $this->addSql('ALTER TABLE software_profile ADD operative_system_id INT NOT NULL'); $this->addSql('ALTER TABLE software_profile ADD CONSTRAINT FK_B70C3C9BF1E9F66E FOREIGN KEY (operative_system_id) REFERENCES operative_system (id)'); $this->addSql('CREATE INDEX IDX_B70C3C9BF1E9F66E ON software_profile (operative_system_id)'); } public function down(Schema $schema): void { // this down() migration is auto-generated, please modify it to your needs $this->addSql('ALTER TABLE software DROP type'); $this->addSql('ALTER TABLE software_profile DROP FOREIGN KEY FK_B70C3C9BF1E9F66E'); $this->addSql('DROP INDEX IDX_B70C3C9BF1E9F66E ON software_profile'); $this->addSql('ALTER TABLE software_profile DROP operative_system_id'); } }