From a523f1c1ba6c67a2a1005f70db0d57fc6482c7d5 Mon Sep 17 00:00:00 2001 From: Jeremy Benoist Date: Mon, 29 Oct 2018 14:41:40 +0100 Subject: fixup! Debug MySQL failing --- app/DoctrineMigrations/Version20181029131313.php | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'app/DoctrineMigrations') diff --git a/app/DoctrineMigrations/Version20181029131313.php b/app/DoctrineMigrations/Version20181029131313.php index 328dc80e..47b2f3f4 100644 --- a/app/DoctrineMigrations/Version20181029131313.php +++ b/app/DoctrineMigrations/Version20181029131313.php @@ -14,20 +14,16 @@ final class Version20181029131313 extends WallabagMigration { public function up(Schema $schema): void { - $this->addSql('ALTER TABLE ' . $this->getTable('craue_config_setting') . ' RENAME TO ' . $this->getTable('internal_setting') . ';'); - if ('mysql' === $this->connection->getDatabasePlatform()->getName()) { - $this->addSql('ALTER TABLE ' . $this->getTable('internal_setting') . ' CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;'); + $this->addSql('ALTER TABLE ' . $this->getTable('craue_config_setting') . ' CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;'); - $this->addSql('ALTER TABLE ' . $this->getTable('internal_setting') . ' CHANGE `name` `name` VARCHAR(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;'); - $this->addSql('ALTER TABLE ' . $this->getTable('internal_setting') . ' CHANGE `section` `section` VARCHAR(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;'); + $this->addSql('ALTER TABLE ' . $this->getTable('craue_config_setting') . ' CHANGE `name` `name` VARCHAR(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;'); + $this->addSql('ALTER TABLE ' . $this->getTable('craue_config_setting') . ' CHANGE `section` `section` VARCHAR(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;'); } } public function down(Schema $schema): void { - $this->addSql('ALTER TABLE ' . $this->getTable('internal_setting') . ' RENAME TO ' . $this->getTable('craue_config_setting') . ';'); - if ('mysql' === $this->connection->getDatabasePlatform()->getName()) { $this->addSql('ALTER TABLE ' . $this->getTable('craue_config_setting') . ' CONVERT TO CHARACTER SET utf8 COLLATE utf8_unicode_ci;'); -- cgit v1.2.3