15 lines
656 B
SQL
15 lines
656 B
SQL
ALTER TABLE vn.deviceProductionUser DROP INDEX IF EXISTS deviceProductionUser_UN;
|
|
|
|
ALTER TABLE vn.deviceProductionUser DROP FOREIGN KEY deviceProductionUser_FK;
|
|
|
|
ALTER TABLE vn.deviceProductionUser DROP PRIMARY KEY;
|
|
|
|
ALTER TABLE vn.deviceProductionUser ADD id INT UNSIGNED AUTO_INCREMENT NOT NULL PRIMARY KEY FIRST;
|
|
|
|
ALTER TABLE vn.deviceProductionUser ADD CONSTRAINT deviceProductionUser_deviceProduction_FK FOREIGN KEY (deviceProductionFk) REFERENCES vn.deviceProduction(id);
|
|
|
|
ALTER TABLE vn.deviceProductionUser ADD CONSTRAINT deviceProductionUser_unique UNIQUE KEY (deviceProductionFk);
|
|
|
|
ALTER TABLE vn.deviceProduction ADD simSerialNumber TEXT NULL;
|
|
|