salix/db/versions/.archive/10691-bronzeCamellia/00-firstScript.sql

7 lines
381 B
MySQL
Raw Normal View History

ALTER TABLE vn.invoiceInLog MODIFY COLUMN changedModel enum('InvoiceIn','InvoiceInTax','InvoiceInDueDay')
CHARACTER SET utf8mb3 COLLATE utf8mb3_unicode_ci DEFAULT 'InvoiceIn' NOT NULL;
ALTER TABLE `vn`.`invoiceInDueDay`
ADD IF NOT EXISTS editorFk INT UNSIGNED NULL,
ADD CONSTRAINT invoiceInDueDay_fk_editor FOREIGN KEY IF NOT EXISTS (editorFk) REFERENCES account.`user`(id);