From 1a49884577fb125abf325ed7362926867ec43bb1 Mon Sep 17 00:00:00 2001 From: Angel Fernando Quiroz Campos Date: Wed, 11 May 2016 15:06:09 -0500 Subject: [PATCH] Revert "Fix issue setting PRIMARY KEY to possible NULL in migration from 1.9 to 1.10 - refs CT#8200" This reverts commit 70c7ef3799973aeada684f7c016c71d9a28e1e2f. --- app/Migrations/Schema/V110/Version110.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Migrations/Schema/V110/Version110.php b/app/Migrations/Schema/V110/Version110.php index 167513d56a..10bf1574bb 100644 --- a/app/Migrations/Schema/V110/Version110.php +++ b/app/Migrations/Schema/V110/Version110.php @@ -123,8 +123,8 @@ class Version110 extends AbstractMigrationChamilo $this->addSql("ALTER TABLE track_e_online CHANGE COLUMN login_ip user_ip varchar(39) NOT NULL DEFAULT ''"); $this->addSql("ALTER TABLE track_e_login CHANGE COLUMN login_ip user_ip varchar(39) NOT NULL DEFAULT ''"); - $this->addSql("ALTER TABLE user DROP PRIMARY KEY"); $this->addSql("ALTER TABLE user MODIFY COLUMN user_id int unsigned DEFAULT NULL"); + $this->addSql("ALTER TABLE user DROP PRIMARY KEY"); $this->addSql("ALTER TABLE user ADD COLUMN id INT DEFAULT NULL"); $this->addSql("UPDATE user SET id = user_id"); $this->addSql("ALTER TABLE user MODIFY COLUMN id INT NOT NULL PRIMARY KEY AUTO_INCREMENT AFTER user_id");