From 16f8e4ee8079e767fd041a8fbff756e360cf6cf5 Mon Sep 17 00:00:00 2001 From: Antonino Natale Date: Tue, 10 Dec 2024 23:12:10 +0100 Subject: [PATCH] chore: add database_query_handle_empty_result migration --- ...0-2237-add-database-query-handle-empty-result.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 db/knex_migrations/2024-12-10-2237-add-database-query-handle-empty-result.js diff --git a/db/knex_migrations/2024-12-10-2237-add-database-query-handle-empty-result.js b/db/knex_migrations/2024-12-10-2237-add-database-query-handle-empty-result.js new file mode 100644 index 000000000..9d70fcd5d --- /dev/null +++ b/db/knex_migrations/2024-12-10-2237-add-database-query-handle-empty-result.js @@ -0,0 +1,13 @@ +exports.up = function (knex) { + return knex.schema + .alterTable("monitor", function (table) { + table.boolean("database_query_handle_empty_as_failure").notNullable().defaultTo(false); + }); +}; + +exports.down = function (knex) { + return knex.schema + .alterTable("monitor", function (table) { + table.dropColumn("database_query_handle_empty_as_failure"); + }); +};