From 6745f82bf61cf1b10050084e0784fac2e2902415 Mon Sep 17 00:00:00 2001 From: Benjamin Sonntag Date: Sat, 27 Aug 2016 14:42:29 +0200 Subject: [PATCH] [fix] Fixes #38 we don't ADD to a .sql in upgrades/ we create a new one for each new release --- install/upgrades/3.0.0~1.sql | 3 --- install/upgrades/3.4.6.sql | 3 +++ 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/install/upgrades/3.0.0~1.sql b/install/upgrades/3.0.0~1.sql index f4860b5e..865f0c60 100644 --- a/install/upgrades/3.0.0~1.sql +++ b/install/upgrades/3.0.0~1.sql @@ -204,9 +204,6 @@ UPDATE domaines_type SET create_tmpdir=true, create_targetdir=true WHERE target= ALTER IGNORE TABLE domaines MODIFY domaine VARCHAR(255); ALTER IGNORE TABLE sub_domaines MODIFY domaine VARCHAR(255); --- Should lthe default_subdomains table already exists, prevent the following INSERT INTO to double the entries -ALTER TABLE `default_subdomains` ADD UNIQUE KEY `unique_row` (`sub`,`domain_type`,`domain_type_parameter`,`concerned`); - -- Defaults subdomains to create when a domain is added CREATE TABLE IF NOT EXISTS `default_subdomains` ( `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT, diff --git a/install/upgrades/3.4.6.sql b/install/upgrades/3.4.6.sql index 1db7205f..fb29b904 100644 --- a/install/upgrades/3.4.6.sql +++ b/install/upgrades/3.4.6.sql @@ -36,3 +36,6 @@ ALTER TABLE `tld` ENGINE InnoDB; ALTER TABLE `variable` ENGINE InnoDB; ALTER TABLE `vm_history` ENGINE InnoDB; +-- Should lthe default_subdomains table already exists, prevent the following INSERT INTO to double the entries +ALTER TABLE `default_subdomains` ADD UNIQUE KEY `unique_row` (`sub`,`domain_type`,`domain_type_parameter`,`concerned`); +