30 lines
840 B
PHP

<?php
declare(strict_types=1);
namespace Chill\Migrations\ThirdParty;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
final class Version20230215175150 extends AbstractMigration
{
public function getDescription(): string
{
return 'Change profession to a string field and transfer values';
}
public function up(Schema $schema): void
{
$this->addSql('ALTER TABLE chill_3party.third_party ADD profession VARCHAR(255) DEFAULT \'\' NOT NULL');
// $this->addSql('ALTER TABLE chill_3party.third_party DROP profession_id');
}
public function down(Schema $schema): void
{
// $this->addSql('ALTER TABLE chill_3party.third_party ADD profession_id INT DEFAULT NULL');
$this->addSql('ALTER TABLE chill_3party.third_party DROP profession');
}
}