Part-DB-server/migrations/Version20251010125849.php
2025-10-10 15:01:53 +02:00

26 lines
587 B
PHP

<?php
declare(strict_types=1);
namespace DoctrineMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
final class Version20251010125849 extends AbstractMigration
{
public function getDescription(): string
{
return 'Add unique index to parts.ipn again';
}
public function up(Schema $schema): void
{
$this->addSql('CREATE UNIQUE INDEX UNIQ_6940A7FE3D721C14 ON parts (ipn)');
}
public function down(Schema $schema): void
{
$this->addSql('DROP INDEX UNIQ_6940A7FE3D721C14 ON `parts`');
}
}