From a9f4fe2c9a22b9806263cf0fd9e5996727d501b1 Mon Sep 17 00:00:00 2001
From: Guilhem Moulin <guilhem@fripost.org>
Date: Sat, 7 Jun 2025 17:24:38 +0200
Subject: =?UTF-8?q?Rename=20=E2=80=9Csks=E2=80=9D=20group=20to=20=E2=80=9C?=
 =?UTF-8?q?avverk=E2=80=9D.?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

And “sks:AvverkAnm” resp. “sks:UtfordAvverk” to “sks:avverk_anmald”
resp. “sks:avverk_utford”.
---
 schema.sql | 192 ++++++++++++++++++++++++++++++-------------------------------
 1 file changed, 96 insertions(+), 96 deletions(-)

(limited to 'schema.sql')

diff --git a/schema.sql b/schema.sql
index 41226b2..492b4ab 100644
--- a/schema.sql
+++ b/schema.sql
@@ -2642,40 +2642,34 @@ ALTER SEQUENCE postgis."sametinget:flyttled_ogc_fid_seq" OWNED BY postgis."samet
 
 
 --
--- Name: sks:AvverkAnm; Type: TABLE; Schema: postgis; Owner: webmap_import
+-- Name: sks:atervatningsavtal; Type: TABLE; Schema: postgis; Owner: webmap_import
 --
 
-CREATE TABLE postgis."sks:AvverkAnm" (
+CREATE TABLE postgis."sks:atervatningsavtal" (
     ogc_fid bigint NOT NULL,
-    "OBJECTID" integer NOT NULL,
+    "Uuid" uuid NOT NULL,
     "Beteckn" character varying(12) NOT NULL,
     "ArendeAr" smallint NOT NULL,
-    "Inkomdatum" date NOT NULL,
-    "AnmaldHa" real NOT NULL,
-    "SkogsodlHa" real,
-    "NatforHa" real,
-    "ArendeStatus" character varying(254) NOT NULL,
-    "AvvSasong" character varying(254) NOT NULL,
-    "AvvHa" real,
-    "AvverkningsanmalanKlass" character varying(254) NOT NULL,
+    "AvtalatDatum" date,
+    "Url" character varying(252),
     wkb_geometry postgis.geometry(MultiPolygon,3006) NOT NULL
 );
 
 
-ALTER TABLE postgis."sks:AvverkAnm" OWNER TO webmap_import;
+ALTER TABLE postgis."sks:atervatningsavtal" OWNER TO webmap_import;
 
 --
--- Name: TABLE "sks:AvverkAnm"; Type: COMMENT; Schema: postgis; Owner: webmap_import
+-- Name: TABLE "sks:atervatningsavtal"; Type: COMMENT; Schema: postgis; Owner: webmap_import
 --
 
-COMMENT ON TABLE postgis."sks:AvverkAnm" IS 'Avverkningsanmälningar (Skogsstyrelsen)';
+COMMENT ON TABLE postgis."sks:atervatningsavtal" IS 'Återvätningsavtal';
 
 
 --
--- Name: sks:AvverkAnm_ogc_fid_seq; Type: SEQUENCE; Schema: postgis; Owner: webmap_import
+-- Name: sks:atervatningsavtal_ogc_fid_seq; Type: SEQUENCE; Schema: postgis; Owner: webmap_import
 --
 
-CREATE SEQUENCE postgis."sks:AvverkAnm_ogc_fid_seq"
+CREATE SEQUENCE postgis."sks:atervatningsavtal_ogc_fid_seq"
     START WITH 1
     INCREMENT BY 1
     NO MINVALUE
@@ -2683,51 +2677,50 @@ CREATE SEQUENCE postgis."sks:AvverkAnm_ogc_fid_seq"
     CACHE 1;
 
 
-ALTER TABLE postgis."sks:AvverkAnm_ogc_fid_seq" OWNER TO webmap_import;
+ALTER TABLE postgis."sks:atervatningsavtal_ogc_fid_seq" OWNER TO webmap_import;
 
 --
--- Name: sks:AvverkAnm_ogc_fid_seq; Type: SEQUENCE OWNED BY; Schema: postgis; Owner: webmap_import
+-- Name: sks:atervatningsavtal_ogc_fid_seq; Type: SEQUENCE OWNED BY; Schema: postgis; Owner: webmap_import
 --
 
-ALTER SEQUENCE postgis."sks:AvverkAnm_ogc_fid_seq" OWNED BY postgis."sks:AvverkAnm".ogc_fid;
+ALTER SEQUENCE postgis."sks:atervatningsavtal_ogc_fid_seq" OWNED BY postgis."sks:atervatningsavtal".ogc_fid;
 
 
 --
--- Name: sks:UtfordAvverk; Type: TABLE; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_anmald; Type: TABLE; Schema: postgis; Owner: webmap_import
 --
 
-CREATE TABLE postgis."sks:UtfordAvverk" (
+CREATE TABLE postgis."sks:avverk_anmald" (
     ogc_fid bigint NOT NULL,
     "OBJECTID" integer NOT NULL,
-    "Beteckn" character varying(12),
+    "Beteckn" character varying(12) NOT NULL,
     "ArendeAr" smallint NOT NULL,
-    "Avverktyp" character varying(254) NOT NULL,
-    "Skogstyp" character varying(254) NOT NULL,
+    "Inkomdatum" date NOT NULL,
     "AnmaldHa" real NOT NULL,
+    "SkogsodlHa" real,
     "NatforHa" real,
-    "Avvdatum" date,
-    "KallaDatum" character varying(62),
-    "Forebild" character varying(62),
-    "Efterbild" character varying(62),
-    "ArealHa" real NOT NULL,
+    "AvvSasong" character varying(254) NOT NULL,
+    "ArendeStatus" character varying(254) NOT NULL,
+    "AvvHa" real,
+    "AvverkningsanmalanKlass" character varying(254) NOT NULL,
     wkb_geometry postgis.geometry(MultiPolygon,3006) NOT NULL
 );
 
 
-ALTER TABLE postgis."sks:UtfordAvverk" OWNER TO webmap_import;
+ALTER TABLE postgis."sks:avverk_anmald" OWNER TO webmap_import;
 
 --
--- Name: TABLE "sks:UtfordAvverk"; Type: COMMENT; Schema: postgis; Owner: webmap_import
+-- Name: TABLE "sks:avverk_anmald"; Type: COMMENT; Schema: postgis; Owner: webmap_import
 --
 
-COMMENT ON TABLE postgis."sks:UtfordAvverk" IS 'Utförd avverkning (Skogsstyrelsen)';
+COMMENT ON TABLE postgis."sks:avverk_anmald" IS 'Avverkningsanmälningar (Skogsstyrelsen)';
 
 
 --
--- Name: sks:UtfordAvverk_ogc_fid_seq; Type: SEQUENCE; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_anmald_ogc_fid_seq; Type: SEQUENCE; Schema: postgis; Owner: webmap_import
 --
 
-CREATE SEQUENCE postgis."sks:UtfordAvverk_ogc_fid_seq"
+CREATE SEQUENCE postgis."sks:avverk_anmald_ogc_fid_seq"
     START WITH 1
     INCREMENT BY 1
     NO MINVALUE
@@ -2735,44 +2728,51 @@ CREATE SEQUENCE postgis."sks:UtfordAvverk_ogc_fid_seq"
     CACHE 1;
 
 
-ALTER TABLE postgis."sks:UtfordAvverk_ogc_fid_seq" OWNER TO webmap_import;
+ALTER TABLE postgis."sks:avverk_anmald_ogc_fid_seq" OWNER TO webmap_import;
 
 --
--- Name: sks:UtfordAvverk_ogc_fid_seq; Type: SEQUENCE OWNED BY; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_anmald_ogc_fid_seq; Type: SEQUENCE OWNED BY; Schema: postgis; Owner: webmap_import
 --
 
-ALTER SEQUENCE postgis."sks:UtfordAvverk_ogc_fid_seq" OWNED BY postgis."sks:UtfordAvverk".ogc_fid;
+ALTER SEQUENCE postgis."sks:avverk_anmald_ogc_fid_seq" OWNED BY postgis."sks:avverk_anmald".ogc_fid;
 
 
 --
--- Name: sks:atervatningsavtal; Type: TABLE; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_utford; Type: TABLE; Schema: postgis; Owner: webmap_import
 --
 
-CREATE TABLE postgis."sks:atervatningsavtal" (
+CREATE TABLE postgis."sks:avverk_utford" (
     ogc_fid bigint NOT NULL,
-    "Uuid" uuid NOT NULL,
-    "Beteckn" character varying(12) NOT NULL,
+    "OBJECTID" integer NOT NULL,
+    "Beteckn" character varying(12),
     "ArendeAr" smallint NOT NULL,
-    "AvtalatDatum" date,
-    "Url" character varying(252),
+    "Avverktyp" character varying(254) NOT NULL,
+    "Skogstyp" character varying(254) NOT NULL,
+    "AnmaldHa" real NOT NULL,
+    "NatforHa" real,
+    "Avvdatum" date,
+    "KallaDatum" character varying(62),
+    "Forebild" character varying(62),
+    "Efterbild" character varying(62),
+    "ArealHa" real NOT NULL,
     wkb_geometry postgis.geometry(MultiPolygon,3006) NOT NULL
 );
 
 
-ALTER TABLE postgis."sks:atervatningsavtal" OWNER TO webmap_import;
+ALTER TABLE postgis."sks:avverk_utford" OWNER TO webmap_import;
 
 --
--- Name: TABLE "sks:atervatningsavtal"; Type: COMMENT; Schema: postgis; Owner: webmap_import
+-- Name: TABLE "sks:avverk_utford"; Type: COMMENT; Schema: postgis; Owner: webmap_import
 --
 
-COMMENT ON TABLE postgis."sks:atervatningsavtal" IS 'Återvätningsavtal';
+COMMENT ON TABLE postgis."sks:avverk_utford" IS 'Utförd avverkning (Skogsstyrelsen)';
 
 
 --
--- Name: sks:atervatningsavtal_ogc_fid_seq; Type: SEQUENCE; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_utford_ogc_fid_seq; Type: SEQUENCE; Schema: postgis; Owner: webmap_import
 --
 
-CREATE SEQUENCE postgis."sks:atervatningsavtal_ogc_fid_seq"
+CREATE SEQUENCE postgis."sks:avverk_utford_ogc_fid_seq"
     START WITH 1
     INCREMENT BY 1
     NO MINVALUE
@@ -2780,13 +2780,13 @@ CREATE SEQUENCE postgis."sks:atervatningsavtal_ogc_fid_seq"
     CACHE 1;
 
 
-ALTER TABLE postgis."sks:atervatningsavtal_ogc_fid_seq" OWNER TO webmap_import;
+ALTER TABLE postgis."sks:avverk_utford_ogc_fid_seq" OWNER TO webmap_import;
 
 --
--- Name: sks:atervatningsavtal_ogc_fid_seq; Type: SEQUENCE OWNED BY; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_utford_ogc_fid_seq; Type: SEQUENCE OWNED BY; Schema: postgis; Owner: webmap_import
 --
 
-ALTER SEQUENCE postgis."sks:atervatningsavtal_ogc_fid_seq" OWNED BY postgis."sks:atervatningsavtal".ogc_fid;
+ALTER SEQUENCE postgis."sks:avverk_utford_ogc_fid_seq" OWNED BY postgis."sks:avverk_utford".ogc_fid;
 
 
 --
@@ -3798,24 +3798,24 @@ ALTER TABLE ONLY postgis."sametinget:flyttled" ALTER COLUMN ogc_fid SET DEFAULT
 
 
 --
--- Name: sks:AvverkAnm ogc_fid; Type: DEFAULT; Schema: postgis; Owner: webmap_import
+-- Name: sks:atervatningsavtal ogc_fid; Type: DEFAULT; Schema: postgis; Owner: webmap_import
 --
 
-ALTER TABLE ONLY postgis."sks:AvverkAnm" ALTER COLUMN ogc_fid SET DEFAULT nextval('postgis."sks:AvverkAnm_ogc_fid_seq"'::regclass);
+ALTER TABLE ONLY postgis."sks:atervatningsavtal" ALTER COLUMN ogc_fid SET DEFAULT nextval('postgis."sks:atervatningsavtal_ogc_fid_seq"'::regclass);
 
 
 --
--- Name: sks:UtfordAvverk ogc_fid; Type: DEFAULT; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_anmald ogc_fid; Type: DEFAULT; Schema: postgis; Owner: webmap_import
 --
 
-ALTER TABLE ONLY postgis."sks:UtfordAvverk" ALTER COLUMN ogc_fid SET DEFAULT nextval('postgis."sks:UtfordAvverk_ogc_fid_seq"'::regclass);
+ALTER TABLE ONLY postgis."sks:avverk_anmald" ALTER COLUMN ogc_fid SET DEFAULT nextval('postgis."sks:avverk_anmald_ogc_fid_seq"'::regclass);
 
 
 --
--- Name: sks:atervatningsavtal ogc_fid; Type: DEFAULT; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_utford ogc_fid; Type: DEFAULT; Schema: postgis; Owner: webmap_import
 --
 
-ALTER TABLE ONLY postgis."sks:atervatningsavtal" ALTER COLUMN ogc_fid SET DEFAULT nextval('postgis."sks:atervatningsavtal_ogc_fid_seq"'::regclass);
+ALTER TABLE ONLY postgis."sks:avverk_utford" ALTER COLUMN ogc_fid SET DEFAULT nextval('postgis."sks:avverk_utford_ogc_fid_seq"'::regclass);
 
 
 --
@@ -4758,59 +4758,59 @@ ALTER TABLE ONLY postgis."sametinget:flyttled"
 
 
 --
--- Name: sks:AvverkAnm sks:AvverkAnm_OBJECTID_key; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
+-- Name: sks:atervatningsavtal sks:atervatningsavtal_Uuid_key; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
 --
 
-ALTER TABLE ONLY postgis."sks:AvverkAnm"
-    ADD CONSTRAINT "sks:AvverkAnm_OBJECTID_key" UNIQUE ("OBJECTID");
+ALTER TABLE ONLY postgis."sks:atervatningsavtal"
+    ADD CONSTRAINT "sks:atervatningsavtal_Uuid_key" UNIQUE ("Uuid");
 
 
 --
--- Name: sks:AvverkAnm sks:AvverkAnm_pkey; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
+-- Name: sks:atervatningsavtal sks:atervatningsavtal_pkey; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
 --
 
-ALTER TABLE ONLY postgis."sks:AvverkAnm"
-    ADD CONSTRAINT "sks:AvverkAnm_pkey" PRIMARY KEY (ogc_fid);
+ALTER TABLE ONLY postgis."sks:atervatningsavtal"
+    ADD CONSTRAINT "sks:atervatningsavtal_pkey" PRIMARY KEY (ogc_fid);
 
 
 --
--- Name: sks:UtfordAvverk sks:UtfordAvverk_Beteckn_key; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_anmald sks:avverk_anmald_OBJECTID_key; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
 --
 
-ALTER TABLE ONLY postgis."sks:UtfordAvverk"
-    ADD CONSTRAINT "sks:UtfordAvverk_Beteckn_key" UNIQUE ("Beteckn");
+ALTER TABLE ONLY postgis."sks:avverk_anmald"
+    ADD CONSTRAINT "sks:avverk_anmald_OBJECTID_key" UNIQUE ("OBJECTID");
 
 
 --
--- Name: sks:UtfordAvverk sks:UtfordAvverk_OBJECTID_key; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_anmald sks:avverk_anmald_pkey; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
 --
 
-ALTER TABLE ONLY postgis."sks:UtfordAvverk"
-    ADD CONSTRAINT "sks:UtfordAvverk_OBJECTID_key" UNIQUE ("OBJECTID");
+ALTER TABLE ONLY postgis."sks:avverk_anmald"
+    ADD CONSTRAINT "sks:avverk_anmald_pkey" PRIMARY KEY (ogc_fid);
 
 
 --
--- Name: sks:UtfordAvverk sks:UtfordAvverk_pkey; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_utford sks:avverk_utford_Beteckn_key; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
 --
 
-ALTER TABLE ONLY postgis."sks:UtfordAvverk"
-    ADD CONSTRAINT "sks:UtfordAvverk_pkey" PRIMARY KEY (ogc_fid);
+ALTER TABLE ONLY postgis."sks:avverk_utford"
+    ADD CONSTRAINT "sks:avverk_utford_Beteckn_key" UNIQUE ("Beteckn");
 
 
 --
--- Name: sks:atervatningsavtal sks:atervatningsavtal_Uuid_key; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_utford sks:avverk_utford_OBJECTID_key; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
 --
 
-ALTER TABLE ONLY postgis."sks:atervatningsavtal"
-    ADD CONSTRAINT "sks:atervatningsavtal_Uuid_key" UNIQUE ("Uuid");
+ALTER TABLE ONLY postgis."sks:avverk_utford"
+    ADD CONSTRAINT "sks:avverk_utford_OBJECTID_key" UNIQUE ("OBJECTID");
 
 
 --
--- Name: sks:atervatningsavtal sks:atervatningsavtal_pkey; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_utford sks:avverk_utford_pkey; Type: CONSTRAINT; Schema: postgis; Owner: webmap_import
 --
 
-ALTER TABLE ONLY postgis."sks:atervatningsavtal"
-    ADD CONSTRAINT "sks:atervatningsavtal_pkey" PRIMARY KEY (ogc_fid);
+ALTER TABLE ONLY postgis."sks:avverk_utford"
+    ADD CONSTRAINT "sks:avverk_utford_pkey" PRIMARY KEY (ogc_fid);
 
 
 --
@@ -5370,24 +5370,24 @@ CREATE INDEX "sametinget:flyttled_wkb_geometry_geom_idx" ON postgis."sametinget:
 
 
 --
--- Name: sks:AvverkAnm_wkb_geometry_geom_idx; Type: INDEX; Schema: postgis; Owner: webmap_import
+-- Name: sks:atervatningsavtal_wkb_geometry_geom_idx; Type: INDEX; Schema: postgis; Owner: webmap_import
 --
 
-CREATE INDEX "sks:AvverkAnm_wkb_geometry_geom_idx" ON postgis."sks:AvverkAnm" USING gist (wkb_geometry);
+CREATE INDEX "sks:atervatningsavtal_wkb_geometry_geom_idx" ON postgis."sks:atervatningsavtal" USING gist (wkb_geometry);
 
 
 --
--- Name: sks:UtfordAvverk_wkb_geometry_geom_idx; Type: INDEX; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_anmald_wkb_geometry_geom_idx; Type: INDEX; Schema: postgis; Owner: webmap_import
 --
 
-CREATE INDEX "sks:UtfordAvverk_wkb_geometry_geom_idx" ON postgis."sks:UtfordAvverk" USING gist (wkb_geometry);
+CREATE INDEX "sks:avverk_anmald_wkb_geometry_geom_idx" ON postgis."sks:avverk_anmald" USING gist (wkb_geometry);
 
 
 --
--- Name: sks:atervatningsavtal_wkb_geometry_geom_idx; Type: INDEX; Schema: postgis; Owner: webmap_import
+-- Name: sks:avverk_utford_wkb_geometry_geom_idx; Type: INDEX; Schema: postgis; Owner: webmap_import
 --
 
-CREATE INDEX "sks:atervatningsavtal_wkb_geometry_geom_idx" ON postgis."sks:atervatningsavtal" USING gist (wkb_geometry);
+CREATE INDEX "sks:avverk_utford_wkb_geometry_geom_idx" ON postgis."sks:avverk_utford" USING gist (wkb_geometry);
 
 
 --
@@ -6251,45 +6251,45 @@ GRANT SELECT,USAGE ON SEQUENCE postgis."sametinget:flyttled_ogc_fid_seq" TO webm
 
 
 --
--- Name: TABLE "sks:AvverkAnm"; Type: ACL; Schema: postgis; Owner: webmap_import
+-- Name: TABLE "sks:atervatningsavtal"; Type: ACL; Schema: postgis; Owner: webmap_import
 --
 
-GRANT SELECT ON TABLE postgis."sks:AvverkAnm" TO webmap_guest;
+GRANT SELECT ON TABLE postgis."sks:atervatningsavtal" TO webmap_guest;
 
 
 --
--- Name: SEQUENCE "sks:AvverkAnm_ogc_fid_seq"; Type: ACL; Schema: postgis; Owner: webmap_import
+-- Name: SEQUENCE "sks:atervatningsavtal_ogc_fid_seq"; Type: ACL; Schema: postgis; Owner: webmap_import
 --
 
-GRANT SELECT,USAGE ON SEQUENCE postgis."sks:AvverkAnm_ogc_fid_seq" TO webmap_guest;
+GRANT SELECT,USAGE ON SEQUENCE postgis."sks:atervatningsavtal_ogc_fid_seq" TO webmap_guest;
 
 
 --
--- Name: TABLE "sks:UtfordAvverk"; Type: ACL; Schema: postgis; Owner: webmap_import
+-- Name: TABLE "sks:avverk_anmald"; Type: ACL; Schema: postgis; Owner: webmap_import
 --
 
-GRANT SELECT ON TABLE postgis."sks:UtfordAvverk" TO webmap_guest;
+GRANT SELECT ON TABLE postgis."sks:avverk_anmald" TO webmap_guest;
 
 
 --
--- Name: SEQUENCE "sks:UtfordAvverk_ogc_fid_seq"; Type: ACL; Schema: postgis; Owner: webmap_import
+-- Name: SEQUENCE "sks:avverk_anmald_ogc_fid_seq"; Type: ACL; Schema: postgis; Owner: webmap_import
 --
 
-GRANT SELECT,USAGE ON SEQUENCE postgis."sks:UtfordAvverk_ogc_fid_seq" TO webmap_guest;
+GRANT SELECT,USAGE ON SEQUENCE postgis."sks:avverk_anmald_ogc_fid_seq" TO webmap_guest;
 
 
 --
--- Name: TABLE "sks:atervatningsavtal"; Type: ACL; Schema: postgis; Owner: webmap_import
+-- Name: TABLE "sks:avverk_utford"; Type: ACL; Schema: postgis; Owner: webmap_import
 --
 
-GRANT SELECT ON TABLE postgis."sks:atervatningsavtal" TO webmap_guest;
+GRANT SELECT ON TABLE postgis."sks:avverk_utford" TO webmap_guest;
 
 
 --
--- Name: SEQUENCE "sks:atervatningsavtal_ogc_fid_seq"; Type: ACL; Schema: postgis; Owner: webmap_import
+-- Name: SEQUENCE "sks:avverk_utford_ogc_fid_seq"; Type: ACL; Schema: postgis; Owner: webmap_import
 --
 
-GRANT SELECT,USAGE ON SEQUENCE postgis."sks:atervatningsavtal_ogc_fid_seq" TO webmap_guest;
+GRANT SELECT,USAGE ON SEQUENCE postgis."sks:avverk_utford_ogc_fid_seq" TO webmap_guest;
 
 
 --
-- 
cgit v1.2.3

