From ba38e71b29f7dd6f11eae5cbdb1b79084ab11c53 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Wed, 13 Oct 2021 16:05:49 -0400 Subject: [PATCH] Correct definition of Importance. Want less importance to have a hgiher value. Make not null. --- db/zm_create.sql.in | 2 +- db/zm_update-1.36.9.sql | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) create mode 100644 db/zm_update-1.36.9.sql diff --git a/db/zm_create.sql.in b/db/zm_create.sql.in index 6233862cc..45e04033d 100644 --- a/db/zm_create.sql.in +++ b/db/zm_create.sql.in @@ -539,7 +539,7 @@ CREATE TABLE `Monitors` ( `Longitude` DECIMAL(11,8), `RTSPServer` BOOLEAN NOT NULL DEFAULT FALSE, `RTSPStreamName` varchar(255) NOT NULL default '', - `Importance` enum('Not','Less','Normal'), + `Importance` enum('Normal','Less','Not') NOT NULL default 'Normal', PRIMARY KEY (`Id`) ) ENGINE=@ZM_MYSQL_ENGINE@; diff --git a/db/zm_update-1.36.9.sql b/db/zm_update-1.36.9.sql new file mode 100644 index 000000000..919efc87a --- /dev/null +++ b/db/zm_update-1.36.9.sql @@ -0,0 +1,2 @@ +UPDATE Monitors set Importance = 'Normal' where Importance IS NULL; +ALTER TABLE `Monitors` MODIFY `Importance` enum('Normal','Less','Not') NOT NULL default 'Normal';