From 9997516d96b2026a9913db2e8a70f8aefd95d03b Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Wed, 31 Jan 2007 13:12:16 +0000 Subject: [PATCH] Die Spalte "taxzone_id" in den Tabellen customer und vendor darf nicht NULL sein. --- sql/Pg-upgrade2/customer_vendor_taxzone_id.sql | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 sql/Pg-upgrade2/customer_vendor_taxzone_id.sql diff --git a/sql/Pg-upgrade2/customer_vendor_taxzone_id.sql b/sql/Pg-upgrade2/customer_vendor_taxzone_id.sql new file mode 100644 index 000000000..9ad3f1e61 --- /dev/null +++ b/sql/Pg-upgrade2/customer_vendor_taxzone_id.sql @@ -0,0 +1,10 @@ +-- @tag: customer_vendor_taxzone_id +-- @description: Die Spalte "taxzone_id" in den Tabellen customer und vendor darf nicht NULL sein. +-- @depends: release_2_4_1 +UPDATE customer SET taxzone_id = 0 WHERE taxzone_id ISNULL; +ALTER TABLE customer ALTER COLUMN taxzone_id SET DEFAULT 0; +ALTER TABLE customer ALTER COLUMN taxzone_id SET NOT NULL; + +UPDATE vendor SET taxzone_id = 0 WHERE taxzone_id ISNULL; +ALTER TABLE vendor ALTER COLUMN taxzone_id SET DEFAULT 0; +ALTER TABLE vendor ALTER COLUMN taxzone_id SET NOT NULL; -- 2.20.1