From 64739a3a3623cbadad8dd77526d2b94361a25df7 Mon Sep 17 00:00:00 2001 From: phborba Date: Mon, 2 Oct 2023 13:36:46 -0300 Subject: [PATCH 01/53] =?UTF-8?q?Vers=C3=A3o=204.10.1:=20corrige=20problem?= =?UTF-8?q?a=20=20de=20cria=C3=A7=C3=A3o=20de=20banco=20edgv=203.0=20e=20a?= =?UTF-8?q?diciona=20EDGV=203.0=20Pro?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 9 + .../core/DbModels/PostGIS/3_Pro/edgv3_pro.sql | 4889 +++++++++++++++++ .../DbCreatorFactory/spatialiteDbCreator.py | 2 + .../core/Factories/DbFactory/postgisDb.py | 6 +- .../SqlFactory/postgisSqlGenerator.py | 4 +- .../connectionComboBox.py | 1 + .../databaseFileLineEdit.py | 1 + .../databaseParameterWidget.ui | 5 + DsgTools/metadata.txt | 5 + README.md | 8 +- 10 files changed, 4921 insertions(+), 9 deletions(-) create mode 100644 DsgTools/core/DbModels/PostGIS/3_Pro/edgv3_pro.sql diff --git a/CHANGELOG.md b/CHANGELOG.md index ab992419f..d0c96f90d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,14 @@ # CHANGELOG +## 4.10.1 - 2023-10-02 + +Melhoria: + +- Adicionado o modelo EDGV 3.0 Pro; + +Correção de Bug: + +- Correção de erro ao criar banco EDGV 3.0; ## 4.11.16 - dev diff --git a/DsgTools/core/DbModels/PostGIS/3_Pro/edgv3_pro.sql b/DsgTools/core/DbModels/PostGIS/3_Pro/edgv3_pro.sql new file mode 100644 index 000000000..6f98cf2f8 --- /dev/null +++ b/DsgTools/core/DbModels/PostGIS/3_Pro/edgv3_pro.sql @@ -0,0 +1,4889 @@ +CREATE SCHEMA edgv# +CREATE SCHEMA dominios# + +CREATE EXTENSION postgis# +CREATE EXTENSION IF NOT EXISTS "uuid-ossp"# +SET search_path TO pg_catalog,public,edgv,dominios# + +CREATE TABLE public.db_metadata( + edgvversion varchar(50) NOT NULL DEFAULT 'EDGV 3.0 Pro', + dbimplversion varchar(50) NOT NULL DEFAULT '1.3.1', + CONSTRAINT edgvversioncheck CHECK (edgvversion = 'EDGV 3.0 Pro') +)# +INSERT INTO public.db_metadata (edgvversion, dbimplversion) VALUES ('EDGV 3.0 Pro','1.3.1')# + +CREATE TABLE dominios.exibir_lado_simbologia ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT exibir_lado_simbologia_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.exibir_lado_simbologia (code,code_name) VALUES (1,'Exibir ambos os lados (1)')# +INSERT INTO dominios.exibir_lado_simbologia (code,code_name) VALUES (2,'Exibir lado esquerdo (2)')# +INSERT INTO dominios.exibir_lado_simbologia (code,code_name) VALUES (3,'Exibir lado direito (3)')# +INSERT INTO dominios.exibir_lado_simbologia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.exibir_lado_simbologia OWNER TO postgres# + +CREATE TABLE dominios.exibir_ponta_simbologia ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT exibir_ponta_simbologia_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.exibir_ponta_simbologia (code,code_name) VALUES (1,'Exibir ambos as pontas (1)')# +INSERT INTO dominios.exibir_ponta_simbologia (code,code_name) VALUES (2,'Exibir ponta inicial (2)')# +INSERT INTO dominios.exibir_ponta_simbologia (code,code_name) VALUES (3,'Exibir ponta final (3)')# +INSERT INTO dominios.exibir_ponta_simbologia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.exibir_ponta_simbologia OWNER TO postgres# + +CREATE TABLE dominios.tipo_area_uso_especifico ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_area_uso_especifico_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (1,'Área de propriedade particular (1)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (2,'Área habitacional (2)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (3,'Área relacionada a dutos (3)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (4,'Área relacionada a edificação agropecuária ou extrativismo vegetal ou pesca (4)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (5,'Área relacionada a edificação de comércio ou serviços (5)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (6,'Área relacinada a edificação de ensino (6)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (7,'Área relacionada a edificação de saúde (7)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (8,'Área relacionada a edificação industrial (8)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (9,'Área relacionada a edificação religiosa (9)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (10,'Área relacionada a energia elétrica (10)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (11,'Área relacionada a equipamentos de desenvolvimento social (11)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (12,'Área relacionada a estação de medição de fenômenos (12)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (13,'Área relacionada ao extrativismo mineral (13)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (14,'Área relacionada a instalação de abastecimento de água (14)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (15,'Área relacionada a instalação de comunicações (15)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (16,'Área relacionada a instalação de estrutura de transporte (16)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (17,'Área relacionada a instalação de saneamento (17)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (18,'Área relacionada ao lazer (18)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (19,'Área relacionada a ruinas de valor histórico (19)')# +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_area_uso_especifico OWNER TO postgres# + +CREATE TABLE dominios.ancora_horizontal ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT ancora_horizontal_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (1,'Esquerda (1)')# +INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (2,'Centro (2)')# +INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (3,'Direita (3)')# +INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.ancora_horizontal OWNER TO postgres# + +CREATE TABLE dominios.ancora_vertical ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT ancora_vertical_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (1,'Inferior (1)')# +INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (2,'Meio (2)')# +INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (3,'Superior (3)')# +INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.ancora_vertical OWNER TO postgres# + +CREATE TABLE dominios.bitola ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT bitola_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.bitola (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (1,'Métrica (1)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (2,'Internacional (2)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (3,'Larga (3)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (4,'Mista métrica internacional (4)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (5,'Mista métrica larga (5)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (6,'Mista internacional larga (6)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.bitola OWNER TO postgres# + +CREATE TABLE dominios.tipo_produto_residuo ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_produto_residuo_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (3,'Petróleo (3)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (5,'Gás (5)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (18,'Cascalho (18)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (22,'Pedra (brita) (22)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (23,'Granito (23)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (24,'Mármore (24)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (25,'Bauxita (25)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (26,'Manganês (26)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (27,'Talco (27)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (32,'Cobre (32)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (33,'Carvão mineral (33)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (34,'Sal (34)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (35,'Ferro (35)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (37,'Ouro (37)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (38,'Diamante (38)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (39,'Prata (39)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (40,'Pedra preciosa (40)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (42,'Areia (42)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (43,'Saibro/piçarra (43)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (45,'Ágata (45)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (47,'Água marinha (47)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (48,'Água mineral (48)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (49,'Alexandrita (49)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (50,'Ametista (50)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (51,'Amianto (51)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (52,'Argila (52)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (53,'Barita (53)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (54,'Bentonita (54)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (55,'Calcário (55)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (56,'Carvão vegetal (56)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (57,'Caulim (57)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (59,'Chumbo (59)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (60,'Citrino (60)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (61,'Crisoberilo (61)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (62,'Cristal de rocha (62)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (63,'Cromo (63)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (64,'Diatomita (64)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (65,'Dolomito (65)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (67,'Esmeralda (67)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (68,'Estanho (68)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (69,'Feldspato (69)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (70,'Fosfato (70)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (71,'Gipsita (71)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (72,'Grafita (72)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (73,'Granada (73)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (74,'Lítio (74)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (78,'Magnesita (78)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (79,'Mica (79)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (80,'Nióbio (80)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (81,'Níquel (81)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (82,'Opala (82)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (83,'Rocha ornamental (83)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (84,'Sal-gema (84)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (85,'Terras raras (85)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (86,'Titânio (86)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (87,'Topázio (87)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (88,'Tório (88)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (89,'Tungstênio (89)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (90,'Turfa (90)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (91,'Turmalina (91)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (92,'Urânio (92)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (93,'Vermiculita (93)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (94,'Zinco (94)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (100,'Zircônio (100)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_produto_residuo OWNER TO postgres# + +CREATE TABLE dominios.tipo_borda_elemento_hidrografico ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_borda_elemento_hidrografico_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_borda_elemento_hidrografico (code,code_name) VALUES (1,'Rocha em água (1)')# +INSERT INTO dominios.tipo_borda_elemento_hidrografico (code,code_name) VALUES (2,'Recife (2)')# +INSERT INTO dominios.tipo_borda_elemento_hidrografico (code,code_name) VALUES (3,'Limite entre oceano e mangue (3)')# +INSERT INTO dominios.tipo_borda_elemento_hidrografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_borda_elemento_hidrografico OWNER TO postgres# + +CREATE TABLE dominios.posicao_rotulo ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT posicao_rotulo_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (1,'Na linha (1)')# +INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (2,'Acima da linha (2)')# +INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (3,'Abaixo da linha (3)')# +INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.posicao_rotulo OWNER TO postgres# + +CREATE TABLE dominios.tipo_simbolo_area ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_simbolo_area_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (1,'Subestação de energia (1)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (2,'Extração mineral (2)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (3,'Extração mineral não operacional (3)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (4,'Extração mineral - salina (4)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (5,'Plataforma (5)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (6,'Cemitério - Cristã (6)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (7,'Cemitério - Israelita (7)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (8,'Cemitério - Muçulmana (8)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (9,'Cemitério - Outros (9)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (10,'Estacionamento (10)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (11,'Edificação de ensino (11)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (12,'Edificação religiosa (12)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (13,'Edificação religiosa - mesquita (13)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (14,'Edificação religiosa - sinagoga (14)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (19,'Edificação religiosa - cristã (19)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (20,'Edificação religiosa - templo (20)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (15,'Edificação saúde (15)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (16,'Posto de combustível (16)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (17,'Representação diplomática (17)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (18,'Campo/quadra (18)')# +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_simbolo_area OWNER TO postgres# + +CREATE TABLE dominios.justificativa ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT justificativa_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.justificativa (code,code_name) VALUES (1,'Esquerda (1)')# +INSERT INTO dominios.justificativa (code,code_name) VALUES (2,'Centro (2)')# +INSERT INTO dominios.justificativa (code,code_name) VALUES (3,'Direita (3)')# +INSERT INTO dominios.justificativa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.justificativa OWNER TO postgres# + +CREATE TABLE dominios.auxiliar ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT auxiliar_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.auxiliar (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.auxiliar (code,code_name) VALUES (1,'Sim (1)')# +INSERT INTO dominios.auxiliar (code,code_name) VALUES (2,'Não (2)')# +INSERT INTO dominios.auxiliar (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.auxiliar OWNER TO postgres# + +CREATE TABLE dominios.administracao ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT administracao_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.administracao (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (1,'Federal (1)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (2,'Estadual (2)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (3,'Municipal (3)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (6,'Particular (6)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (7,'Concessionada (7)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.administracao OWNER TO postgres# + +CREATE TABLE dominios.booleano ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT booleano_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.booleano (code,code_name) VALUES (1,'Sim (1)')# +INSERT INTO dominios.booleano (code,code_name) VALUES (2,'Não (2)')# +INSERT INTO dominios.booleano (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.booleano OWNER TO postgres# + +CREATE TABLE dominios.booleano_estendido ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT booleano_estendido_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.booleano_estendido (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.booleano_estendido (code,code_name) VALUES (1,'Sim (1)')# +INSERT INTO dominios.booleano_estendido (code,code_name) VALUES (2,'Não (2)')# +INSERT INTO dominios.booleano_estendido (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.booleano_estendido OWNER TO postgres# + +CREATE TABLE dominios.tipo_sumidouro_vertedouro ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_sumidouro_vertedouro_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_sumidouro_vertedouro (code,code_name) VALUES (4,'Sumidouro (4)')# +INSERT INTO dominios.tipo_sumidouro_vertedouro (code,code_name) VALUES (5,'Vertedouro (5)')# +INSERT INTO dominios.tipo_sumidouro_vertedouro (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_sumidouro_vertedouro OWNER TO postgres# + +CREATE TABLE dominios.finalidade ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT finalidade_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.finalidade (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.finalidade (code,code_name) VALUES (2,'Tratamento (2)')# +INSERT INTO dominios.finalidade (code,code_name) VALUES (3,'Recalque (3)')# +INSERT INTO dominios.finalidade (code,code_name) VALUES (4,'Distribuição (4)')# +INSERT INTO dominios.finalidade (code,code_name) VALUES (8,'Armazenamento (8)')# +INSERT INTO dominios.finalidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.finalidade OWNER TO postgres# + +CREATE TABLE dominios.situacao_em_poligono ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT situacao_em_poligono_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (1,'Fora de polígono (1)')# +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (2,'Dentro de polígono - Trecho principal (2)')# +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (3,'Dentro de polígono - Trecho secundário (3)')# +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (4,'Dentro de polígono - Trecho compartilhado (4)')# +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.situacao_em_poligono OWNER TO postgres# + +CREATE TABLE dominios.forma_extracao ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT forma_extracao_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.forma_extracao (code,code_name) VALUES (5,'A céu aberto (5)')# +INSERT INTO dominios.forma_extracao (code,code_name) VALUES (6,'Subterrânea (6)')# +INSERT INTO dominios.forma_extracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.forma_extracao OWNER TO postgres# + +CREATE TABLE dominios.indice ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT indice_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.indice (code,code_name) VALUES (1,'Mestra (1)')# +INSERT INTO dominios.indice (code,code_name) VALUES (2,'Normal (2)')# +INSERT INTO dominios.indice (code,code_name) VALUES (3,'Auxiliar (3)')# +INSERT INTO dominios.indice (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.indice OWNER TO postgres# + +CREATE TABLE dominios.jurisdicao ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT jurisdicao_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (1,'Federal (1)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (2,'Estadual (2)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (3,'Municipal (3)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (6,'Particular (6)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.jurisdicao OWNER TO postgres# + +CREATE TABLE dominios.tipo_barragem ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_barragem_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_barragem (code,code_name) VALUES (1,'Barragem (1)')# +INSERT INTO dominios.tipo_barragem (code,code_name) VALUES (2,'Dique (2)')# +INSERT INTO dominios.tipo_barragem (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_barragem OWNER TO postgres# + +CREATE TABLE dominios.material_construcao ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT material_construcao_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.material_construcao (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (1,'Alvenaria (1)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (2,'Concreto (2)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (3,'Metal (3)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (4,'Rocha (4)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (5,'Madeira (5)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (9,'Fibra (9)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (23,'Terra (23)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (98,'Outros (98)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.material_construcao OWNER TO postgres# + +CREATE TABLE dominios.modal_uso ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT modal_uso_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.modal_uso (code,code_name) VALUES (4,'Rodoviário (4)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (5,'Ferroviário (5)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (6,'Metroviário (6)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (7,'Dutos (7)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (9,'Aeroportuário (9)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (10,'Hidroviário (10)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (14,'Portuário (14)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.modal_uso OWNER TO postgres# + +CREATE TABLE dominios.nr_linhas ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT nr_linhas_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (1,'Simples (1)')# +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (2,'Dupla (2)')# +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (3,'Múltipla (3)')# +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.nr_linhas OWNER TO postgres# + +CREATE TABLE dominios.posicao_pista ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT posicao_pista_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.posicao_pista (code,code_name) VALUES (12,'Adjacentes (12)')# +INSERT INTO dominios.posicao_pista (code,code_name) VALUES (13,'Superpostas (13)')# +INSERT INTO dominios.posicao_pista (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.posicao_pista (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.posicao_pista OWNER TO postgres# + +CREATE TABLE dominios.posicao_relativa ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT posicao_relativa_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (2,'Superfície (2)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (3,'Elevado (3)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (4,'Emerso (4)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (5,'Submerso (5)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (6,'Subterrâneo (6)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.posicao_relativa OWNER TO postgres# + +CREATE TABLE dominios.referencial_altim ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT referencial_altim_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (1,'Torres (1)')# +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (2,'Imbituba (2)')# +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (3,'Santana (3)')# +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (4,'Local (4)')# +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.referencial_altim OWNER TO postgres# + +CREATE TABLE dominios.referencial_grav ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT referencial_grav_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (1,'Postdam 1930 (1)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (2,'IGSN71 (2)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (3,'Absoluto (3)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (4,'Local (4)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (5,'RGFB (5)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.referencial_grav OWNER TO postgres# + +CREATE TABLE dominios.regime ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT regime_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.regime (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.regime (code,code_name) VALUES (1,'Permanente (1)')# +INSERT INTO dominios.regime (code,code_name) VALUES (3,'Temporário (3)')# +INSERT INTO dominios.regime (code,code_name) VALUES (5,'Seco (5)')# +INSERT INTO dominios.regime (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.regime OWNER TO postgres# + +CREATE TABLE dominios.revestimento ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT revestimento_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.revestimento (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (1,'Leito natural (1)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (2,'Revestimento primário (solto) (2)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (3,'Pavimentado (3)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (4,'Calçado (4)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.revestimento OWNER TO postgres# + +CREATE TABLE dominios.sistema_geodesico ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT sistema_geodesico_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (1,'SAD 69 (1)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (2,'SIRGAS 2000 (2)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (3,'WGS-84 (3)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (4,'Córrego Alegre (4)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (5,'Astro Chuá (5)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (6,'SAD-69 (96) (6)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (98,'Outra referência (98)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.sistema_geodesico OWNER TO postgres# + +CREATE TABLE dominios.situacao_fisica ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT situacao_fisica_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (1,'Abandonada (1)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (2,'Destruída (2)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (3,'Construída (3)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (4,'Em construção (4)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.situacao_fisica OWNER TO postgres# + +CREATE TABLE dominios.situacao_marco ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT situacao_marco_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (1,'Bom (1)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (2,'Destruído (2)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (3,'Destruído sem chapa (3)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (4,'Destruído com chapa danificada (4)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (5,'Não encontrado (5)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (6,'Não visitado (6)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.situacao_marco OWNER TO postgres# + +CREATE TABLE dominios.tipo_massa_dagua ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_massa_dagua_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (1,'Rio (com fluxo) (1)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (2,'Canal (com fluxo) (2)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (3,'Oceano (sem fluxo) (3)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (4,'Baía (sem fluxo) (4)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (5,'Enseada (sem fluxo) (5)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (6,'Meando Abandonado (sem fluxo) (6)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (7,'Lago ou Lagoa (sem fluxo) (7)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (9,'Laguna (com fluxo) (9)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (10,'Represa/açude com fluxo (10)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (11,'Represa/açude sem fluxo (11)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (12,'Canal não operacional (sem fluxo) (12)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_massa_dagua OWNER TO postgres# + +CREATE TABLE dominios.tipo_delimitacao_fisica ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_delimitacao_fisica_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_delimitacao_fisica (code,code_name) VALUES (1,'Cerca (1)')# +INSERT INTO dominios.tipo_delimitacao_fisica (code,code_name) VALUES (2,'Muro (2)')# +INSERT INTO dominios.tipo_delimitacao_fisica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_delimitacao_fisica OWNER TO postgres# + +CREATE TABLE dominios.tipo_deposito ( + code smallint NOT NULL, + code_name text NOT NULL, + filter text NOT NULL, + CONSTRAINT tipo_deposito_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (101,'Geral - Cisterna (101)','Depósito geral')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (108,'Geral - Galpão (108)','Depósito geral')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (109,'Geral - Silo (109)','Depósito geral')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (110,'Geral - Composteira (110)','Depósito geral')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (111,'Geral - Depósito frigorífico (111)','Depósito geral')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (112,'Geral - Barracão industrial (112)','Depósito geral')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (113,'Geral - Reservatório (113)','Depósito geral')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (132,'Geral - Armazém (132)','Depósito geral')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (198,'Geral - Outros (198)','Depósito geral')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (201,'Abast água - Tanque de água (201)','Depósito de abastecimento de água')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (202,'Abast água - Caixa de água (202)','Depósito de abastecimento de água')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (203,'Abast água - Cisterna (203)','Depósito de abastecimento de água')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (204,'Abast água - Reservatório (204)','Depósito de abastecimento de água')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (298,'Abast água - Outros (298)','Depósito de abastecimento de água')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (301,'San - Tanque de saneamento (301)','Depósito de saneamento')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (304,'San - Depósito de lixo (304)','Depósito de saneamento')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (305,'San - Aterro sanitário (305)','Depósito de saneamento')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (306,'San - Aterro controlado (306)','Depósito de saneamento')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (398,'San - Outros (398)','Depósito de saneamento')# +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_deposito OWNER TO postgres# + +CREATE TABLE dominios.tipo_edificacao ( + code smallint NOT NULL, + code_name text NOT NULL, + filter text NOT NULL, + CONSTRAINT tipo_edificacao_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (0,'Edificação genérica (0)','Edificação genérica')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3,'Edif. Flutuante / Palafita (3)','Edificação genérica')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (101,'Com - Centro de operações de comunicação (101)','Edificação de comunicação')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (102,'Com - Central de comutação e transmissão (102)','Edificação de comunicação')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (103,'Com - Estação rádio-base (103)','Edificação de comunicação')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (104,'Com - Estação repetidora (104)','Edificação de comunicação')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (105,'Com - Administrativo (105)','Edificação de comunicação')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (201,'Edificação de energia (201)','Edificação de energia')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (301,'Abast - Edificação de captação de água (301)','Edificação de abastecimento de água')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (302,'Abast - Edificação de tratamento de água (302)','Edificação de abastecimento de água')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (303,'Abast - Edificação de recalque de água (303)','Edificação de abastecimento de água')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (304,'Abast - Administrativa (304)','Edificação de abastecimento de água')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (395,'Abast - Mista (395)','Edificação de abastecimento de água')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (398,'Abast - Outros (398)','Edificação de abastecimento de água')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (403,'Saneam - Edificação de recalque de resíduos (403)','Edificação de saneamento')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (405,'Saneam - Edificação de tratamento de esgoto (405)','Edificação de saneamento')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (406,'Saneam - Usina de reciclagem (406)','Edificação de saneamento')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (407,'Saneam - Incinerador de resíduos (407)','Edificação de saneamento')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (408,'Saneam - Administração (408)','Edificação de saneamento')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (498,'Saneam - Outros (498)','Edificação de saneamento')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (516,'Ens - Edificação de educação infantil – creche (516)','Edificação de ensino')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (517,'Ens - Edificação de educação infantil - pré-escola (517)','Edificação de ensino')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (518,'Ens - Edificação de ensino fundamental (518)','Edificação de ensino')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (519,'Ens - Edificação de ensino médio (519)','Edificação de ensino')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (520,'Ens - Edificação de educação superior – Graduação (520)','Edificação de ensino')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (521,'Ens - Edificação de educação superior – graduação e pós-graduação (521)','Edificação de ensino')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (522,'Ens - Edificação de educação superior – pós-graduação e extensão (522)','Edificação de ensino')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (523,'Ens - Edificação de educação professional de nível técnico (523)','Edificação de ensino')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (524,'Ens - Edificação de educação profissional de nível tecnológico (524)','Edificação de ensino')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (525,'Ens - Outras atividades de ensino (525)','Edificação de ensino')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (601,'Rel - Igreja cristã (601)','Edificação religiosa')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (602,'Rel - Templo (602)','Edificação religiosa')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (603,'Rel - Centro religioso (603)','Edificação religiosa')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (604,'Rel - Mosteiro (604)','Edificação religiosa')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (605,'Rel - Convento (605)','Edificação religiosa')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (606,'Rel - Mesquita (606)','Edificação religiosa')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (607,'Rel - Sinagoga (607)','Edificação religiosa')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (608,'Rel - Capela Mortuária (608)','Edificação religiosa')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (609,'Rel - Terreiro (609)','Edificação religiosa')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (610,'Rel - Administração (610)','Edificação religiosa')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (611,'Rel - Igreja não cristã (611)','Edificação religiosa')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (698,'Rel - Outros (698)','Edificação religiosa')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (709,'Tur - Cruzeiro (709)','Edificação ou construção turística')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (710,'Tur - Estátua (710)','Edificação ou construção turística')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (711,'Tur - Mirante (711)','Edificação ou construção turística')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (712,'Tur - Monumento (712)','Edificação ou construção turística')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (713,'Tur - Panteão (713)','Edificação ou construção turística')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (798,'Tur - Outros (798)','Edificação ou construção turística')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (801,'Laz - Estádio (801)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (802,'Laz - Ginásio (802)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (803,'Laz - Museu (803)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (804,'Laz - Teatro (804)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (805,'Laz - Anfiteatro (805)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (806,'Laz - Espaço de exibição de filmes (806)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (807,'Laz - Centro cultural (807)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (808,'Laz - Plataforma de pesca (808)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (809,'Laz - Arquivo (809)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (810,'Laz - Biblioteca (810)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (811,'Laz - Centro de documentação (811)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (812,'Laz - Circo (812)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (813,'Laz - Concha acústica (813)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (814,'Laz - Conservatório (814)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (815,'Laz - Coreto ou tribuna (815)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (817,'Laz - Equipamentos culturais diversos (817)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (818,'Laz - Espaço de eventos e/ou cultural (818)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (819,'Laz - Galeria (819)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (898,'Laz - Outros (898)','Edificação de lazer')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (903,'Comerc - Centro comercial (903)','Edificação de comércio e serviço')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (904,'Comerc - Mercado (904)','Edificação de comércio e serviço')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (905,'Comerc - Centro de convenções (905)','Edificação de comércio e serviço')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (907,'Comerc - Hotel / motel / pousada (907)','Edificação de comércio e serviço')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (908,'Comerc - Banco (908)','Edificação de comércio e serviço')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (909,'Comerc - Centro de exposições (909)','Edificação de comércio e serviço')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (910,'Comerc - Mercado público (910)','Edificação de comércio e serviço')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (998,'Comerc - Outros (998)','Edificação de comércio e serviço')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1015,'Ind - Fabricação alimentícia e bebidas (1015)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1016,'Ind - Fabricação de produtos do fumo (1016)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1017,'Ind - Fabricação de produtos têxteis (1017)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1018,'Ind - Confecção de artigos de vestuário e acessórios (1018)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1019,'Ind - Preparação de couros, artefatos de couro, artigos de viagem e calçados (1019)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1020,'Ind - Fabricação de produtos de madeira e celulose (1020)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1021,'Ind - Fabricação de celulose, papel e produtos de papel (1021)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1022,'Ind - Industria de edição, impressão e reprodução de gravações (1022)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1023,'Ind - Fabricação de coque, refino de petróleo, elaboração de combustíveis nucleares e produção de álcool (1023)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1024,'Ind - Fabricação de produtos químicos (1024)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1025,'Ind - Fabricação de artigos de borracha e material plástico (1025)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1026,'Ind - Fabricação de produtos de minerais não-metálicos (1026)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1027,'Ind - Indústria de metalurgia básica (1027)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1028,'Ind - Fabricação de produtos de metal (1028)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1029,'Ind - Fabricação de máquinas e equipamentos (1029)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1030,'Ind - Fabriação de máquinas de escritório e equipamentos de informática (1030)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1031,'Ind - Fabricação de máquinas, aparelhos e materiais elétricos (1031)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1032,'Ind - Fabricação de material eletrônico, de aparelhos e equipamentos de comunicações (1032)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1033,'Ind - Fabricação de equipamentos de instrumentação médico-hospitalares, instrumentos de precisão e ópticos, automação industrial, cronômetros e relógios (1033)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1034,'Ind - Fabricação e montagem de veículos automotores, reboques e carrocerias (1034)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1035,'Ind - Fabricação de outros equipamentos de transporte (1035)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1036,'Ind - Fabricação de móveis e indústrias diversas (1036)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1037,'Ind - Indústria reciclagem (1037)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1045,'Ind - Indústria de construção (1045)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1046,'Ind - Chaminé (1046)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1098,'Ind - Outros (1098)','Edificação industrial')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1110,'Ext Min - Extração de carvão mineral (1110)','Edificação de extração mineral')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1111,'Ext Min - Extração de petróleo e serviços relacionados (1111)','Edificação de extração mineral')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1113,'Ext Min - Extração de minerais metálicos (1113)','Edificação de extração mineral')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1114,'Ext Min - Extração de minerais não-metálicos (1114)','Edificação de extração mineral')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1198,'Ext Min - Outros (1198)','Edificação de extração mineral')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1212,'Agro - Sede operacional de fazenda (1212)','Edificação agropecuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1213,'Agro - Aviário (1213)','Edificação agropecuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1214,'Agro - Apiário (1214)','Edificação agropecuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1215,'Agro - Viveiro de plantas (1215)','Edificação agropecuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1216,'Agro - Viveiro para aquicultura (1216)','Edificação agropecuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1217,'Agro - Pocilga (1217)','Edificação agropecuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1218,'Agro - Curral (1218)','Edificação agropecuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1298,'Agro - Outros (1298)','Edificação agropecuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1303,'Pub Civ - Cartorial (1303)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1304,'Pub Civ - Gestão pública (1304)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1305,'Pub Civ - Eleitoral (1305)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1306,'Pub Civ - Produção ou pequisa pública (1306)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1307,'Pub Civ - Seguridade social (1307)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1308,'Pub Civ - Câmara municipal (1308)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1309,'Pub Civ - Assembléia legislativa (1309)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1310,'Pub Civ - Autarquia (1310)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1313,'Pub Civ - Fórum (1313)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1314,'Pub Civ - Fundação (1314)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1315,'Pub Civ - Procuradoria (1315)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1316,'Pub Civ - Secretaria (1316)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1322,'Pub Civ - Prefeitura (1322)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1398,'Pub Civ - Outros (1398)','Edificação pública civil')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1401,'Habitacão indigena isolada (1401)','Habitacão indigena')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1402,'Habitacão indigena coletiva (1402)','Habitacão indigena')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1501,'Edificação de medição de fenômenos (1501)','Medição de fenômenos')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1712,'Pub Mil - Aquartelamento (1712)','Edificação militar')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1717,'Pub Mil - Hotel de trânsito (1717)','Edificação militar')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1718,'Pub Mil - Delegacia de serviço militar (1718)','Edificação militar')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1724,'Pub Mil - Capitania dos portos (1724)','Edificação militar')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1798,'Pub Mil - Outros (1798)','Edificação militar')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1910,'Posto Fisc - Tributação (1910)','Posto fiscal')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1912,'Posto Fisc - Fiscalização sanitária (1912)','Posto fiscal')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1913,'Posto Fisc - Posto de pesagem (1913)','Posto fiscal')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1995,'Posto Fisc - Misto (1995)','Posto fiscal')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1998,'Posto Fisc - Outros (1998)','Posto fiscal')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2025,'Sau - Atendimento hospitalar (2025)','Edificação de saúde')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2026,'Sau - Atendimento hospitalar especializado (2026)','Edificação de saúde')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2027,'Sau - Atendimento a urgência e emergências (pronto socorro) (2027)','Edificação de saúde')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2028,'Sau - Atenção ambulatorial (posto e centro de saúde) (2028)','Edificação de saúde')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2029,'Sau - Serviços de complementação diagnóstica ou terapêutica (2029)','Edificação de saúde')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2030,'Sau - Outras atividades relacionadas com a atenção à saúde (instituto de pesquisa) (2030)','Edificação de saúde')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2031,'Sau - Serviços veterinários (2031)','Edificação de saúde')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2101,'Ssoc – Serviço Social (2101)','Edificação de desenvolvimento social')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2208,'Rod - Terminal interestadual (2208)','Edificação rodoviária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2209,'Rod - Terminal urbano (2209)','Edificação rodoviária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2210,'Rod - Parada interestadual (2210)','Edificação rodoviária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2213,'Rod - Posto de pedágio (2213)','Edificação rodoviária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2298,'Rod - Outros (2298)','Edificação rodoviária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2316,'Ferrov - Estação ferroviária de passageiros (2316)','Edificação ferroviária ou metroviária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2317,'Ferrov - Estação metroviária (2317)','Edificação ferroviária ou metroviária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2318,'Ferrov - Terminal ferroviário de cargas (2318)','Edificação ferroviária ou metroviária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2319,'Ferrov - Terminal ferroviário de passageiros e cargas (2319)','Edificação ferroviária ou metroviária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2320,'Ferrov - Oficina de manutenção (2320)','Edificação ferroviária ou metroviária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2321,'Ferrov - Administração (2321)','Edificação ferroviária ou metroviária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2398,'Ferrov - Outros (2398)','Edificação ferroviária ou metroviária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2426,'Aero - Terminal de passageiros (2426)','Edificação aeroportuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2427,'Aero - Terminal de cargas (2427)','Edificação aeroportuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2428,'Aero - Torre de controle (2428)','Edificação aeroportuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2429,'Aero - Hangar (2429)','Edificação aeroportuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2430,'Aero - Serviço de Combate à incendios (SCI) (2430)','Edificação aeroportuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2431,'Aero - Administração (2431)','Edificação aeroportuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2498,'Aero - Outros (2498)','Edificação aeroportuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2501,'Port - Edificação portuária (2501)','Edificação portuária')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2601,'Posto de combustivel (2601)','Posto de combustivel')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2901,'Dip – Consulado (2901)','Representação diplomática')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2902,'Dip – Embaixada (2902)','Representação diplomática')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3001,'Seg – Delegacia de polícia civil (3001)','Edificação de segurança pública')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3002,'Seg – Posto policia militar (3002)','Edificação de segurança pública')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3003,'Seg – Posto guarda municipal (3003)','Edificação de segurança pública')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3004,'Seg – Posto de polícia rodoviária federal (3004)','Edificação de segurança pública')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3005,'Seg – Polícia militar (3005)','Edificação de segurança pública')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3006,'Seg - Prisional (3006)','Edificação de segurança pública')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3007,'Seg - Bombeiros Militar (3007)','Edificação de segurança pública')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3008,'Seg - Bombeiros Civil (3008)','Edificação de segurança pública')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3098,'Seg – Outras polícias (3098)','Edificação de segurança pública')# +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_edificacao OWNER TO postgres# + +CREATE TABLE dominios.tipo_alteracao_fisiografica ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_alteracao_fisiografica_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_alteracao_fisiografica (code,code_name) VALUES (26,'Corte (26)')# +INSERT INTO dominios.tipo_alteracao_fisiografica (code,code_name) VALUES (27,'Aterro (27)')# +INSERT INTO dominios.tipo_alteracao_fisiografica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_alteracao_fisiografica OWNER TO postgres# + +CREATE TABLE dominios.tipo_elemento_fisiografico ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_elemento_fisiografico_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (8,'Escarpa (8)')# +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (13,'Falésia (13)')# +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (14,'Talude (14)')# +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (15,'Dolina (15)')# +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (16,'Duna (16)')# +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (19,'Gruta (19)')# +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (20,'Caverna (20)')# +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (21,'Rocha - Matacão/pedra (21)')# +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (22,'Rocha - Penedo isolado (22)')# +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (23,'Rocha - Area rochosa/lajedo (23)')# +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_elemento_fisiografico OWNER TO postgres# + +CREATE TABLE dominios.tipo_toponimo_fisiografico ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_toponimo_fisiografico_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (1,'Serra (1)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (2,'Morro (2)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (3,'Montanha (3)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (4,'Chapada (4)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (5,'Maciço (5)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (6,'Planalto (6)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (7,'Planície (7)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (9,'Península (9)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (10,'Ponta (10)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (11,'Cabo (11)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (12,'Praia (12)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (17,'Pico (17)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_toponimo_fisiografico OWNER TO postgres# + +CREATE TABLE dominios.tipo_ilha ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_ilha_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (1,'Fluvial (1)')# +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (2,'Marítima (2)')# +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (3,'Lacustre (3)')# +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_ilha OWNER TO postgres# + +CREATE TABLE dominios.tipo_elemento_hidrografico ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_elemento_hidrografico_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (1,'Poço dágua (1)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (2,'Poço artesiano (2)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (3,'Olho dágua (3)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (6,'Foz marítima (6)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (8,'Rocha em água (8)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (9,'Cachoeira (9)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (10,'Salto (10)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (11,'Catarata (11)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (12,'Corredeira (12)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (14,'Banco de areia fluvial (14)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (15,'Banco de areia marítimo (15)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (16,'Banco de areia lacustre (16)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (17,'Banco de areia cordão arenoso (17)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (18,'Recife contiguo (18)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (19,'Recife afastado (19)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_elemento_hidrografico OWNER TO postgres# + +CREATE TABLE dominios.tipo_elemento_energia ( + code smallint NOT NULL, + code_name text NOT NULL, + filter text NOT NULL, + CONSTRAINT tipo_elemento_energia_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (302,'Linha de distribuição de energia (302)','Linha de energia')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (303,'Linha de transmissão de energia (303)','Linha de energia')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (405,'Estação geradora – Eólica (405)','Estação geradora de energia')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (408,'Estação geradora – Hidrelétrica (408)','Estação geradora de energia')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (407,'Estação geradora – Maré-motriz (407)','Estação geradora de energia')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (498,'Estação geradora – Outras (498)','Estação geradora de energia')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (406,'Estação geradora – Solar (406)','Estação geradora de energia')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (409,'Estação geradora – Termelétrica (409)','Estação geradora de energia')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (1401,'Torre de energia (1401)','Torre de energia')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (1701,'Aerogerador (1701)','Aerogerador')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (1801,'Subestação de transmissão de energia elétrica (1801)','Subestação de energia')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (1802,'Subestação de distribuição de energia elétrica (1802)','Subestação de energia')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_elemento_energia OWNER TO postgres# + +CREATE TABLE dominios.tipo_elemento_infraestrutura ( + code smallint NOT NULL, + code_name text NOT NULL, + filter text NOT NULL, + CONSTRAINT tipo_elemento_infraestrutura_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (701,'Quebramar (701)','Quebramar')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (801,'Molhe (801)','Molhe')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (901,'Comporta (901)','Comporta')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1001,'Eclusa (1001)','Eclusa')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1201,'Torre de comunicação (1201)','Torre de comunicação')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1301,'Antena de comunicação (1301)','Antena de comunicação')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1400,'Plataforma- Desconhecido (1400)','Plataforma')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1401,'Plataforma- Petróleo (1401)','Plataforma')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1402,'Plataforma- Gás (1402)','Plataforma')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1495,'Plataforma- Mista (1495)','Plataforma')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1501,'Funicular (1501)','Funicular')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1601,'Cremalheira (1601)','Cremalheira')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1701,'Girador Ferroviário (1701)','Girador Ferroviário')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1801,'Fundeadouro (1801)','Fundeadouro')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1938,'Atrac - Cais (1938)','Atracadouro Terminal')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1939,'Atrac - Cais flutuante (1939)','Atracadouro Terminal')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1940,'Atrac - Trapiche (1940)','Atracadouro Terminal')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1941,'Atrac - Molhe de atracação (1941)','Atracadouro Terminal')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1942,'Atrac - Pier (1942)','Atracadouro Terminal')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1943,'Atrac - Dolfim (1943)','Atracadouro Terminal')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1944,'Atrac - Desembarcadouro (1944)','Atracadouro Terminal')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (2001,'Caminho Aéreo – Teleférico (2001)','Caminho Aéreo')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (2098,'Caminho Aéreo – Outros (2098)','Caminho Aéreo')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_elemento_infraestrutura OWNER TO postgres# + +CREATE TABLE dominios.tipo_mobilidade_urbana ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_mobilidade_urbana_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_mobilidade_urbana (code,code_name) VALUES (1,'Calçadão / Rua pedestre (1)')# +INSERT INTO dominios.tipo_mobilidade_urbana (code,code_name) VALUES (2,'Ciclovia (2)')# +INSERT INTO dominios.tipo_mobilidade_urbana (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_mobilidade_urbana OWNER TO postgres# + +CREATE TABLE dominios.tipo_trecho_duto ( + code smallint NOT NULL, + code_name text NOT NULL, + filter text NOT NULL, + CONSTRAINT tipo_trecho_duto_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (101,'Calha - Água pluvial (101)','Calha')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (201,'Correia transp - Minério (201)','Correia transportadora')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (202,'Correia transp - Grãos (202)','Correia transportadora')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (298,'Correia transp - Outros (298)','Correia transportadora')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (300,'Duto – Desconhecido (300)','Duto')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (301,'Duto – Água (301)','Duto')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (302,'Duto – Óleo (302)','Duto')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (303,'Duto – Gasolina (303)','Duto')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (304,'Duto – Álcool (304)','Duto')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (305,'Duto – Querosene (305)','Duto')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (306,'Duto – Petróleo (306)','Duto')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (307,'Duto – Nafta (307)','Duto')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (308,'Duto – Gás (308)','Duto')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (309,'Duto – Efluentes (309)','Duto')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (310,'Duto – Esgoto (310)','Duto')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (398,'Duto – Outros (398)','Duto')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_trecho_duto OWNER TO postgres# + +CREATE TABLE dominios.tipo_travessia ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_travessia_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (1,'Balsa (1)')# +INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (2,'Bote transportador (2)')# +INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_travessia OWNER TO postgres# + +CREATE TABLE dominios.tipo_elemento_viario ( + code smallint NOT NULL, + code_name text NOT NULL, + filter text NOT NULL, + CONSTRAINT tipo_elemento_viario_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (101,'Túnel (101)','Túnel')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (102,'Túnel - Passagem subterrânea sob via (102)','Túnel')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (201,'Ponte móvel (201)','Ponte')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (202,'Ponte pênsil (202)','Ponte')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (203,'Ponte fixa (203)','Ponte')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (204,'Ponte estaiada (204)','Ponte')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (301,'Passagem elevada (301)','Passagem elevada / Viaduto')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (302,'Viaduto (302)','Passagem elevada / Viaduto')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (401,'Travessia - Vau natural (401)','Travessia')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (402,'Travessia - Vau construído (402)','Travessia')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (501,'Galeria/Bueiro (501)','Galeria/Bueiro')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (607,'Pedestre - Passagem subterrânea (607)','Travessia pedestre')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (608,'Pedestre - Passarela (608)','Travessia pedestre')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (609,'Pedestre - Pinguela (609)','Travessia pedestre')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (701,'Ferrov - Passagem em nível (701)','Cruzamento ferroviário')# +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_elemento_viario OWNER TO postgres# + +CREATE TABLE dominios.tipo_exposicao ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_exposicao_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (3,'Fechado (3)')# +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (4,'Coberto (4)')# +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (5,'Céu aberto (5)')# +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_exposicao OWNER TO postgres# + +CREATE TABLE dominios.tipo_extracao_mineral ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_extracao_mineral_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (1,'Poço - água subterrânea (1)')# +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (4,'Mina / Pedreira (4)')# +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (5,'Garimpo (5)')# +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (6,'Salina (6)')# +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (8,'Poço - petróleo (8)')# +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_extracao_mineral OWNER TO postgres# + +CREATE TABLE dominios.tipo_ferrovia ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_ferrovia_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (5,'Bonde (5)')# +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (6,'Aeromóvel (6)')# +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (7,'Trem (7)')# +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (8,'Metrô (8)')# +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_ferrovia OWNER TO postgres# + +CREATE TABLE dominios.tipo_limite_especial ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_limite_especial_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (2,'Terra indígena (2)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (5,'Unidade de Conservação (5)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (24,'Área de Proteção Ambiental – APA (24)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (25,'Área de Relevante Interesse Ecológico – ARIE (25)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (26,'Floresta – FLO (26)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (27,'Reserva de Desenvolvimento Sustentável – RDS (27)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (28,'Reserva Extrativista – RESEX (28)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (29,'Reserva de Fauna – REFAU (29)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (30,'Reserva Particular do Patrimônio Natural – RPPN (30)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (31,'Estação Ecológica – ESEC (31)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (32,'Parque – PAR (32)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (33,'Monumento Natural – MONA (33)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (34,'Reserva Biológica – REBIO (34)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (35,'Refúgio de Vida Silvestre – RVS (35)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (36,'Área militar (36)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_limite_especial OWNER TO postgres# + +CREATE TABLE dominios.tipo_limite_legal ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_limite_legal_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_limite_legal (code,code_name) VALUES (1,'Limite Internacional (1)')# +INSERT INTO dominios.tipo_limite_legal (code,code_name) VALUES (2,'Limite Estadual (2)')# +INSERT INTO dominios.tipo_limite_legal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_limite_legal OWNER TO postgres# + +CREATE TABLE dominios.tipo_localidade ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_localidade_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (1,'Cidade (1)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (2,'Capital estadual (2)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (3,'Capital federal (3)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (4,'Vila (4)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (5,'Aglomerado rural isolado – Núcleo (5)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (6,'Aglomerado rural isolado – Povoado (6)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (7,'Outros aglomerados rurais – Lugarejo (7)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (8,'Nome local (8)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_localidade OWNER TO postgres# + +CREATE TABLE dominios.tipo_ocupacao_solo ( + code smallint NOT NULL, + code_name text NOT NULL, + filter text NOT NULL, + CONSTRAINT tipo_ocupacao_solo_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (101,'Cemitério - Crematório (101)','Cemitério')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (102,'Cemitério Parque (102)','Cemitério')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (103,'Cemitério Vertical (103)','Cemitério')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (104,'Cemitério Comum - Cristã (104)','Cemitério')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (105,'Cemitério - Túmulo isolado (105)','Cemitério')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (106,'Cemitério Comum - Muçulmana (106)','Cemitério')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (107,'Cemitério Comum - Israelita (107)','Cemitério')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (108,'Cemitério Comum - Outras religiões (108)','Cemitério')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (201,'Campo/Quadra de futebol (201)','Campo ou quadra')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (202,'Campo/Quadra de basquete (202)','Campo ou quadra')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (203,'Campo/Quadra de vôlei (203)','Campo ou quadra')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (204,'Campo/Quadra de pólo (204)','Campo ou quadra')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (205,'Campo/Quadra de hipismo (205)','Campo ou quadra')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (206,'Campo/Quadra poliesportiva (206)','Campo ou quadra')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (207,'Campo/Quadra de tênis (207)','Campo ou quadra')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (298,'Campo/Quadra - Outras quadras esportivas (298)','Campo ou quadra')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (301,'Pista de atletismo (301)','Pista competição')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (302,'Pista de ciclismo (302)','Pista competição')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (303,'Pista de motociclismo (303)','Pista competição')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (304,'Pista de automobilismo (304)','Pista competição')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (305,'Pista de corrida de cavalos (305)','Pista competição')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (306,'Pista de bicicross (306)','Pista competição')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (307,'Pista de motocross (307)','Pista competição')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (398,'Pista - Outras pistas de competição (398)','Pista competição')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (404,'Pátio rodoviário (404)','Pátio')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (405,'Pátio ferroviário (405)','Pátio')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (406,'Pátio metroviário (406)','Pátio')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (409,'Pátio aeroportuário (409)','Pátio')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (414,'Pátio portuário (414)','Pátio')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (415,'Pátio hidroviário (415)','Pátio')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (416,'Pátio de dutos (416)','Pátio')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (501,'Piscina (501)','Piscina')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (601,'Sítio Arqueológico (601)','Sítio Arqueológico')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (701,'Ruína (701)','Ruína')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (801,'Moega (801)','Equipamento agropecuário')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (802,'Moinho (802)','Equipamento agropecuário')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (803,'Secador (803)','Equipamento agropecuário')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (804,'Tombador (804)','Equipamento agropecuário')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (805,'Elevador de grãos (805)','Equipamento agropecuário')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (806,'Pivô central (806)','Equipamento agropecuário')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (901,'Estacionamento (901)','Estacionamento')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1001,'Arquibancada (1001)','Arquibancada')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1101,'Farol ou farolete (1101)','Farol')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1601,'Estação climatológica principal (1601)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1602,'Estação climatológica auxiliar (1602)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1603,'Estação agroclimatológica (1603)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1604,'Estação pluviométrica (1604)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1605,'Estação eólica (1605)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1606,'Estação evaporimétrica (1606)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1607,'Estação solarimétrica (1607)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1608,'Estação de radar meteorológico (1608)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1609,'Estação de rádiosonda (1609)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1610,'Estação fluviométrica (1610)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1611,'Estação maregráfica (1611)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1612,'Estação mares terrestres - crosta (1612)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1613,'Estação Metero-maregráfica (1613)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1614,'Estação Hidrológica (1614)','Ponto de estacão de medição de fenômenos')# +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_ocupacao_solo OWNER TO postgres# + +CREATE TABLE dominios.tipo_pista_pouso ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_pista_pouso_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (9,'Pista de pouso (9)')# +INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (10,'Pista de táxi (10)')# +INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (11,'Heliponto (11)')# +INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_pista_pouso OWNER TO postgres# + +CREATE TABLE dominios.tipo_pto ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_pto_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (1,'Vértice de Triangulação – VT (1)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (2,'Referëncia de Nível – RN (2)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (3,'Estação Gravimétrica – EG (3)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (4,'Estação de Poligonal – EP (4)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (5,'Ponto Astronômico – PA (5)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (6,'Ponto Barométrico – B (6)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (7,'Ponto Trigonométrico – RV (7)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (8,'Ponto de Satélite – SAT (8)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (9,'Ponto de controle (9)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (12,'Centro perspectivo (12)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (13,'Ponto fotogramétrico (13)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (14,'Marco internacional (14)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (15,'Marco estadual (15)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (16,'Marco municipal (16)')# +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_pto OWNER TO postgres# + +CREATE TABLE dominios.tipo_ref ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_ref_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (1,'Altimétrico (1)')# +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (2,'Planimétrico (2)')# +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (3,'Planialtimétrico (3)')# +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (4,'Gravimétrico (4)')# +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_ref OWNER TO postgres# + +CREATE TABLE dominios.tipo_trecho_drenagem ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_trecho_drenagem_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (1,'Rio (1)')# +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (2,'Canal (2)')# +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (3,'Trecho pluvial (3)')# +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (4,'Canal encoberto (4)')# +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (5,'Canal não operacional (5)')# +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_trecho_drenagem OWNER TO postgres# + +CREATE TABLE dominios.tipo_hid ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_hid_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (1,'Rio (1)')# +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (2,'Canal (2)')# +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (3,'Oceano (3)')# +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (4,'Baía (4)')# +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (5,'Enseada (5)')# +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (6,'Meando Abandonado (6)')# +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (7,'Lago ou Lagoa (7)')# +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (9,'Laguna (9)')# +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (10,'Represa (10)')# +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (11,'Açude (11)')# +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_hid OWNER TO postgres# + +CREATE TABLE dominios.tipo_veg ( + code smallint NOT NULL, + code_name text NOT NULL, + filter text NOT NULL, + CONSTRAINT tipo_veg_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (150,'Cult - Arroz de inundação (150)','Vegetação Cultivada')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (194,'Cult - Perene (194)','Vegetação Cultivada')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (196,'Cult - Anual irrigado (196)','Vegetação Cultivada')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (197,'Cult - Anual não irrigado (197)','Vegetação Cultivada')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (201,'Mangue (201)','Mangue')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (301,'Brejo/pântano (301)','Brejo ou pântano')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (401,'Restinga (401)','Restinga')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (501,'Campinarana (501)','Campinarana')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (601,'Floresta densa (601)','Floresta')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (602,'Floresta esparsa (602)','Floresta')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (701,'Cerrado/Cerradão (701)','Cerrado/Cerradão')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (801,'Caatinga (801)','Caatinga')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (901,'Campo (901)','Campo')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1000,'Terreno exposto - desconhecido (1000)','Terreno Exposto')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1001,'Terreno exposto - cascalho (1001)','Terreno Exposto')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1002,'Terreno exposto - areia (1002)','Terreno Exposto')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1003,'Terreno exposto - pedregoso (1003)','Terreno Exposto')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1296,'Reflorestamento (1296)','Reflorestamento')# +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_veg OWNER TO postgres# + +CREATE TABLE dominios.tipo_via_deslocamento ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_via_deslocamento_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (2,'Estrada/Rodovia (2)')# +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (3,'Caminho carroçável (3)')# +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (4,'Auto-estrada (4)')# +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (5,'Arruamento (5)')# +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (6,'Trilha ou Picada (6)')# +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_via_deslocamento OWNER TO postgres# + +CREATE TABLE dominios.trafego ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT trafego_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.trafego (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.trafego (code,code_name) VALUES (1,'Permanente (1)')# +INSERT INTO dominios.trafego (code,code_name) VALUES (2,'Periódico (2)')# +INSERT INTO dominios.trafego (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.trafego OWNER TO postgres# + +CREATE TABLE dominios.uso_pista ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT uso_pista_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.uso_pista (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (6,'Particular (6)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (11,'Público (11)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (12,'Militar (12)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (13,'Público/Militar (13)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.uso_pista OWNER TO postgres# + +CREATE TABLE edgv.cobter_area_construida_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + densamente_edificada smallint NOT NULL, + assentamento_precario smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT cobter_area_construida_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX cobter_area_construida_a_geom ON edgv.cobter_area_construida_a USING gist (geom)# + +ALTER TABLE edgv.cobter_area_construida_a OWNER TO postgres# + +ALTER TABLE edgv.cobter_area_construida_a + ADD CONSTRAINT cobter_area_construida_a_densamente_edificada_fk FOREIGN KEY (densamente_edificada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.cobter_area_construida_a ALTER COLUMN densamente_edificada SET DEFAULT 9999# + +ALTER TABLE edgv.cobter_area_construida_a + ADD CONSTRAINT cobter_area_construida_a_assentamento_precario_fk FOREIGN KEY (assentamento_precario) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.cobter_area_construida_a ALTER COLUMN assentamento_precario SET DEFAULT 9999# + +CREATE TABLE edgv.cobter_massa_dagua_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + regime smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT cobter_massa_dagua_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX cobter_massa_dagua_a_geom ON edgv.cobter_massa_dagua_a USING gist (geom)# + +ALTER TABLE edgv.cobter_massa_dagua_a OWNER TO postgres# + +ALTER TABLE edgv.cobter_massa_dagua_a + ADD CONSTRAINT cobter_massa_dagua_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_massa_dagua (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.cobter_massa_dagua_a + ADD CONSTRAINT cobter_massa_dagua_a_regime_fk FOREIGN KEY (regime) + REFERENCES dominios.regime (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN regime SET DEFAULT 9999# + +ALTER TABLE edgv.cobter_massa_dagua_a + ADD CONSTRAINT cobter_massa_dagua_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.cobter_vegetacao_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + tipo smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT cobter_vegetacao_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX cobter_vegetacao_a_geom ON edgv.cobter_vegetacao_a USING gist (geom)# + +ALTER TABLE edgv.cobter_vegetacao_a OWNER TO postgres# + +ALTER TABLE edgv.cobter_vegetacao_a + ADD CONSTRAINT cobter_vegetacao_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_veg (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.cobter_vegetacao_a ALTER COLUMN tipo SET DEFAULT 9999# + +CREATE TABLE edgv.constr_area_uso_especifico_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT constr_area_uso_especifico_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX constr_area_uso_especifico_a_geom ON edgv.constr_area_uso_especifico_a USING gist (geom)# + +ALTER TABLE edgv.constr_area_uso_especifico_a OWNER TO postgres# + +ALTER TABLE edgv.constr_area_uso_especifico_a + ADD CONSTRAINT constr_area_uso_especifico_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_area_uso_especifico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_area_uso_especifico_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.constr_area_uso_especifico_a + ADD CONSTRAINT constr_area_uso_especifico_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_area_uso_especifico_a ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.constr_area_uso_especifico_a + ADD CONSTRAINT constr_area_uso_especifico_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_area_uso_especifico_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.constr_deposito_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + tipo_exposicao smallint NOT NULL, + situacao_fisica smallint NOT NULL, + material_construcao smallint NOT NULL, + finalidade smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + exibir_linha_rotulo smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT constr_deposito_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX constr_deposito_a_geom ON edgv.constr_deposito_a USING gist (geom)# + +ALTER TABLE edgv.constr_deposito_a OWNER TO postgres# + +ALTER TABLE edgv.constr_deposito_a + ADD CONSTRAINT constr_deposito_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_deposito (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_a + ADD CONSTRAINT constr_deposito_a_tipo_exposicao_fk FOREIGN KEY (tipo_exposicao) + REFERENCES dominios.tipo_exposicao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN tipo_exposicao SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_a + ADD CONSTRAINT constr_deposito_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_a + ADD CONSTRAINT constr_deposito_a_material_construcao_fk FOREIGN KEY (material_construcao) + REFERENCES dominios.material_construcao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_a + ADD CONSTRAINT constr_deposito_a_material_construcao_check + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN material_construcao SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_a + ADD CONSTRAINT constr_deposito_a_finalidade_fk FOREIGN KEY (finalidade) + REFERENCES dominios.finalidade (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN finalidade SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_a + ADD CONSTRAINT constr_deposito_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_a + ADD CONSTRAINT constr_deposito_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_a + ADD CONSTRAINT constr_deposito_a_exibir_linha_rotulo_fk FOREIGN KEY (exibir_linha_rotulo) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN exibir_linha_rotulo SET DEFAULT 9999# + +CREATE TABLE edgv.constr_deposito_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + tipo_exposicao smallint NOT NULL, + situacao_fisica smallint NOT NULL, + material_construcao smallint NOT NULL, + finalidade smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + simb_rot real, + exibir_linha_rotulo smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT constr_deposito_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX constr_deposito_p_geom ON edgv.constr_deposito_p USING gist (geom)# + +ALTER TABLE edgv.constr_deposito_p OWNER TO postgres# + +ALTER TABLE edgv.constr_deposito_p + ADD CONSTRAINT constr_deposito_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_deposito (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_p + ADD CONSTRAINT constr_deposito_p_tipo_exposicao_fk FOREIGN KEY (tipo_exposicao) + REFERENCES dominios.tipo_exposicao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN tipo_exposicao SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_p + ADD CONSTRAINT constr_deposito_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_p + ADD CONSTRAINT constr_deposito_p_material_construcao_fk FOREIGN KEY (material_construcao) + REFERENCES dominios.material_construcao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_p + ADD CONSTRAINT constr_deposito_p_material_construcao_check + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN material_construcao SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_p + ADD CONSTRAINT constr_deposito_p_finalidade_fk FOREIGN KEY (finalidade) + REFERENCES dominios.finalidade (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN finalidade SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_p + ADD CONSTRAINT constr_deposito_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_p + ADD CONSTRAINT constr_deposito_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.constr_deposito_p + ADD CONSTRAINT constr_deposito_p_exibir_linha_rotulo_fk FOREIGN KEY (exibir_linha_rotulo) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN exibir_linha_rotulo SET DEFAULT 9999# + +CREATE TABLE edgv.constr_edificacao_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + material_construcao smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + exibir_linha_rotulo smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT constr_edificacao_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX constr_edificacao_a_geom ON edgv.constr_edificacao_a USING gist (geom)# + +ALTER TABLE edgv.constr_edificacao_a OWNER TO postgres# + +ALTER TABLE edgv.constr_edificacao_a + ADD CONSTRAINT constr_edificacao_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_edificacao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.constr_edificacao_a + ADD CONSTRAINT constr_edificacao_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.constr_edificacao_a + ADD CONSTRAINT constr_edificacao_a_material_construcao_fk FOREIGN KEY (material_construcao) + REFERENCES dominios.material_construcao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_edificacao_a + ADD CONSTRAINT constr_edificacao_a_material_construcao_check + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN material_construcao SET DEFAULT 9999# + +ALTER TABLE edgv.constr_edificacao_a + ADD CONSTRAINT constr_edificacao_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.constr_edificacao_a + ADD CONSTRAINT constr_edificacao_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.constr_edificacao_a + ADD CONSTRAINT constr_edificacao_a_exibir_linha_rotulo_fk FOREIGN KEY (exibir_linha_rotulo) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN exibir_linha_rotulo SET DEFAULT 9999# + +CREATE TABLE edgv.constr_edificacao_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + material_construcao smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + simb_rot real, + exibir_linha_rotulo smallint NOT NULL, + suprimir_bandeira smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT constr_edificacao_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX constr_edificacao_p_geom ON edgv.constr_edificacao_p USING gist (geom)# + +ALTER TABLE edgv.constr_edificacao_p OWNER TO postgres# + +ALTER TABLE edgv.constr_edificacao_p + ADD CONSTRAINT constr_edificacao_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_edificacao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.constr_edificacao_p + ADD CONSTRAINT constr_edificacao_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.constr_edificacao_p + ADD CONSTRAINT constr_edificacao_p_material_construcao_fk FOREIGN KEY (material_construcao) + REFERENCES dominios.material_construcao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_edificacao_p + ADD CONSTRAINT constr_edificacao_p_material_construcao_check + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN material_construcao SET DEFAULT 9999# + +ALTER TABLE edgv.constr_edificacao_p + ADD CONSTRAINT constr_edificacao_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.constr_edificacao_p + ADD CONSTRAINT constr_edificacao_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.constr_edificacao_p + ADD CONSTRAINT constr_edificacao_p_exibir_linha_rotulo_fk FOREIGN KEY (exibir_linha_rotulo) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN exibir_linha_rotulo SET DEFAULT 9999# + +ALTER TABLE edgv.constr_edificacao_p + ADD CONSTRAINT constr_edificacao_p_suprimir_bandeira_fk FOREIGN KEY (suprimir_bandeira) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN suprimir_bandeira SET DEFAULT 9999# + +CREATE TABLE edgv.constr_extracao_mineral_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + tipo_produto smallint NOT NULL, + forma_extracao smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT constr_extracao_mineral_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX constr_extracao_mineral_a_geom ON edgv.constr_extracao_mineral_a USING gist (geom)# + +ALTER TABLE edgv.constr_extracao_mineral_a OWNER TO postgres# + +ALTER TABLE edgv.constr_extracao_mineral_a + ADD CONSTRAINT constr_extracao_mineral_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_extracao_mineral (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_a + ADD CONSTRAINT constr_extracao_mineral_a_tipo_produto_fk FOREIGN KEY (tipo_produto) + REFERENCES dominios.tipo_produto_residuo (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN tipo_produto SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_a + ADD CONSTRAINT constr_extracao_mineral_a_forma_extracao_fk FOREIGN KEY (forma_extracao) + REFERENCES dominios.forma_extracao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN forma_extracao SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_a + ADD CONSTRAINT constr_extracao_mineral_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_a + ADD CONSTRAINT constr_extracao_mineral_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_a + ADD CONSTRAINT constr_extracao_mineral_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.constr_extracao_mineral_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + tipo_produto smallint NOT NULL, + forma_extracao smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT constr_extracao_mineral_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX constr_extracao_mineral_p_geom ON edgv.constr_extracao_mineral_p USING gist (geom)# + +ALTER TABLE edgv.constr_extracao_mineral_p OWNER TO postgres# + +ALTER TABLE edgv.constr_extracao_mineral_p + ADD CONSTRAINT constr_extracao_mineral_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_extracao_mineral (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_p + ADD CONSTRAINT constr_extracao_mineral_p_tipo_produto_fk FOREIGN KEY (tipo_produto) + REFERENCES dominios.tipo_produto_residuo (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN tipo_produto SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_p + ADD CONSTRAINT constr_extracao_mineral_p_forma_extracao_fk FOREIGN KEY (forma_extracao) + REFERENCES dominios.forma_extracao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN forma_extracao SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_p + ADD CONSTRAINT constr_extracao_mineral_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_p + ADD CONSTRAINT constr_extracao_mineral_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_p + ADD CONSTRAINT constr_extracao_mineral_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.constr_ocupacao_solo_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT constr_ocupacao_solo_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX constr_ocupacao_solo_a_geom ON edgv.constr_ocupacao_solo_a USING gist (geom)# + +ALTER TABLE edgv.constr_ocupacao_solo_a OWNER TO postgres# + +ALTER TABLE edgv.constr_ocupacao_solo_a + ADD CONSTRAINT constr_ocupacao_solo_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_ocupacao_solo (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_ocupacao_solo_a + ADD CONSTRAINT constr_ocupacao_solo_a_tipo_check + CHECK (tipo = ANY(ARRAY[101 :: SMALLINT, 102 :: SMALLINT, 103 :: SMALLINT, 104 :: SMALLINT, 105 :: SMALLINT, 106 :: SMALLINT, 107 :: SMALLINT, 108 :: SMALLINT, 201 :: SMALLINT, 202 :: SMALLINT, 203 :: SMALLINT, 204 :: SMALLINT, 205 :: SMALLINT, 206 :: SMALLINT, 207 :: SMALLINT, 298 :: SMALLINT, 301 :: SMALLINT, 302 :: SMALLINT, 303 :: SMALLINT, 304 :: SMALLINT, 305 :: SMALLINT, 306 :: SMALLINT, 307 :: SMALLINT, 398 :: SMALLINT, 404 :: SMALLINT, 405 :: SMALLINT, 406 :: SMALLINT, 409 :: SMALLINT, 414 :: SMALLINT, 415 :: SMALLINT, 416 :: SMALLINT, 501 :: SMALLINT, 601 :: SMALLINT, 701 :: SMALLINT, 801 :: SMALLINT, 802 :: SMALLINT, 804 :: SMALLINT, 803 :: SMALLINT, 805 :: SMALLINT, 806 :: SMALLINT, 901 :: SMALLINT, 1001 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.constr_ocupacao_solo_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.constr_ocupacao_solo_a + ADD CONSTRAINT constr_ocupacao_solo_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_ocupacao_solo_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.constr_ocupacao_solo_a + ADD CONSTRAINT constr_ocupacao_solo_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_ocupacao_solo_a ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.constr_ocupacao_solo_a + ADD CONSTRAINT constr_ocupacao_solo_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_ocupacao_solo_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.constr_ocupacao_solo_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT constr_ocupacao_solo_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX constr_ocupacao_solo_l_geom ON edgv.constr_ocupacao_solo_l USING gist (geom)# + +ALTER TABLE edgv.constr_ocupacao_solo_l OWNER TO postgres# + +ALTER TABLE edgv.constr_ocupacao_solo_l + ADD CONSTRAINT constr_ocupacao_solo_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_ocupacao_solo (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_ocupacao_solo_l + ADD CONSTRAINT constr_ocupacao_solo_l_tipo_check + CHECK (tipo = ANY(ARRAY[301 :: SMALLINT, 302 :: SMALLINT, 303 :: SMALLINT, 304 :: SMALLINT, 305 :: SMALLINT, 306 :: SMALLINT, 307 :: SMALLINT, 398 :: SMALLINT, 1001 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.constr_ocupacao_solo_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.constr_ocupacao_solo_l + ADD CONSTRAINT constr_ocupacao_solo_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_ocupacao_solo_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.constr_ocupacao_solo_l + ADD CONSTRAINT constr_ocupacao_solo_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_ocupacao_solo_l ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.constr_ocupacao_solo_l + ADD CONSTRAINT constr_ocupacao_solo_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_ocupacao_solo_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.constr_ocupacao_solo_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT constr_ocupacao_solo_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX constr_ocupacao_solo_p_geom ON edgv.constr_ocupacao_solo_p USING gist (geom)# + +ALTER TABLE edgv.constr_ocupacao_solo_p OWNER TO postgres# + +ALTER TABLE edgv.constr_ocupacao_solo_p + ADD CONSTRAINT constr_ocupacao_solo_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_ocupacao_solo (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_ocupacao_solo_p + ADD CONSTRAINT constr_ocupacao_solo_p_tipo_check + CHECK (tipo = ANY(ARRAY[101 :: SMALLINT, 102 :: SMALLINT, 103 :: SMALLINT, 104 :: SMALLINT, 105 :: SMALLINT, 106 :: SMALLINT, 107 :: SMALLINT, 108 :: SMALLINT, 201 :: SMALLINT, 202 :: SMALLINT, 203 :: SMALLINT, 204 :: SMALLINT, 205 :: SMALLINT, 206 :: SMALLINT, 207 :: SMALLINT, 298 :: SMALLINT, 301 :: SMALLINT, 302 :: SMALLINT, 303 :: SMALLINT, 304 :: SMALLINT, 305 :: SMALLINT, 306 :: SMALLINT, 307 :: SMALLINT, 398 :: SMALLINT, 701 :: SMALLINT, 801 :: SMALLINT, 802 :: SMALLINT, 804 :: SMALLINT, 803 :: SMALLINT, 805 :: SMALLINT, 806 :: SMALLINT, 1101 :: SMALLINT, 1601 :: SMALLINT, 1602 :: SMALLINT, 1603 :: SMALLINT, 1604 :: SMALLINT, 1605 :: SMALLINT, 1606 :: SMALLINT, 1607 :: SMALLINT, 1608 :: SMALLINT, 1609 :: SMALLINT, 1610 :: SMALLINT, 1611 :: SMALLINT, 1612 :: SMALLINT, 1613 :: SMALLINT, 1614 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.constr_ocupacao_solo_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.constr_ocupacao_solo_p + ADD CONSTRAINT constr_ocupacao_solo_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_ocupacao_solo_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.constr_ocupacao_solo_p + ADD CONSTRAINT constr_ocupacao_solo_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_ocupacao_solo_p ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.constr_ocupacao_solo_p + ADD CONSTRAINT constr_ocupacao_solo_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_ocupacao_solo_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_curva_nivel_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + cota integer NOT NULL, + indice smallint NOT NULL, + depressao smallint NOT NULL, + dentro_de_massa_dagua smallint NOT NULL, + texto_edicao varchar(255), + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT elemnat_curva_nivel_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_curva_nivel_l_geom ON edgv.elemnat_curva_nivel_l USING gist (geom)# + +ALTER TABLE edgv.elemnat_curva_nivel_l OWNER TO postgres# + +ALTER TABLE edgv.elemnat_curva_nivel_l + ADD CONSTRAINT elemnat_curva_nivel_l_indice_fk FOREIGN KEY (indice) + REFERENCES dominios.indice (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN indice SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_curva_nivel_l + ADD CONSTRAINT elemnat_curva_nivel_l_depressao_fk FOREIGN KEY (depressao) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN depressao SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_curva_nivel_l + ADD CONSTRAINT elemnat_curva_nivel_l_dentro_de_massa_dagua_fk FOREIGN KEY (dentro_de_massa_dagua) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN dentro_de_massa_dagua SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_curva_nivel_l + ADD CONSTRAINT elemnat_curva_nivel_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_elemento_fisiografico_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT elemnat_elemento_fisiografico_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_elemento_fisiografico_a_geom ON edgv.elemnat_elemento_fisiografico_a USING gist (geom)# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_a OWNER TO postgres# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_a + ADD CONSTRAINT elemnat_elemento_fisiografico_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_fisiografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_a + ADD CONSTRAINT elemnat_elemento_fisiografico_a_tipo_check + CHECK (tipo = ANY(ARRAY[15 :: SMALLINT, 16 :: SMALLINT, 21 :: SMALLINT, 22 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_a + ADD CONSTRAINT elemnat_elemento_fisiografico_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_a + ADD CONSTRAINT elemnat_elemento_fisiografico_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_a ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_elemento_fisiografico_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT elemnat_elemento_fisiografico_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_elemento_fisiografico_l_geom ON edgv.elemnat_elemento_fisiografico_l USING gist (geom)# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_l OWNER TO postgres# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_l + ADD CONSTRAINT elemnat_elemento_fisiografico_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_fisiografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_l + ADD CONSTRAINT elemnat_elemento_fisiografico_l_tipo_check + CHECK (tipo = ANY(ARRAY[8 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_l + ADD CONSTRAINT elemnat_elemento_fisiografico_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_l + ADD CONSTRAINT elemnat_elemento_fisiografico_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_elemento_fisiografico_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + simb_rot real, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT elemnat_elemento_fisiografico_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_elemento_fisiografico_p_geom ON edgv.elemnat_elemento_fisiografico_p USING gist (geom)# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_p OWNER TO postgres# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_p + ADD CONSTRAINT elemnat_elemento_fisiografico_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_fisiografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_p + ADD CONSTRAINT elemnat_elemento_fisiografico_p_tipo_check + CHECK (tipo = ANY(ARRAY[19 :: SMALLINT, 20 :: SMALLINT, 21 :: SMALLINT, 22 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_p + ADD CONSTRAINT elemnat_elemento_fisiografico_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_p + ADD CONSTRAINT elemnat_elemento_fisiografico_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_fisiografico_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_elemento_hidrografico_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT elemnat_elemento_hidrografico_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_elemento_hidrografico_a_geom ON edgv.elemnat_elemento_hidrografico_a USING gist (geom)# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a OWNER TO postgres# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a + ADD CONSTRAINT elemnat_elemento_hidrografico_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_hidrografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a + ADD CONSTRAINT elemnat_elemento_hidrografico_a_tipo_check + CHECK (tipo = ANY(ARRAY[6 :: SMALLINT, 8 :: SMALLINT, 12 :: SMALLINT, 14 :: SMALLINT, 15 :: SMALLINT, 16 :: SMALLINT, 17 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a + ADD CONSTRAINT elemnat_elemento_hidrografico_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a + ADD CONSTRAINT elemnat_elemento_hidrografico_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_elemento_hidrografico_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT elemnat_elemento_hidrografico_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_elemento_hidrografico_l_geom ON edgv.elemnat_elemento_hidrografico_l USING gist (geom)# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l OWNER TO postgres# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l + ADD CONSTRAINT elemnat_elemento_hidrografico_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_hidrografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l + ADD CONSTRAINT elemnat_elemento_hidrografico_l_tipo_check + CHECK (tipo = ANY(ARRAY[6 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l + ADD CONSTRAINT elemnat_elemento_hidrografico_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l + ADD CONSTRAINT elemnat_elemento_hidrografico_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_elemento_hidrografico_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + simb_rot real, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT elemnat_elemento_hidrografico_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_elemento_hidrografico_p_geom ON edgv.elemnat_elemento_hidrografico_p USING gist (geom)# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p OWNER TO postgres# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p + ADD CONSTRAINT elemnat_elemento_hidrografico_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_hidrografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p + ADD CONSTRAINT elemnat_elemento_hidrografico_p_tipo_check + CHECK (tipo = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 6 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p + ADD CONSTRAINT elemnat_elemento_hidrografico_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p + ADD CONSTRAINT elemnat_elemento_hidrografico_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_ilha_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT elemnat_ilha_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_ilha_p_geom ON edgv.elemnat_ilha_p USING gist (geom)# + +ALTER TABLE edgv.elemnat_ilha_p OWNER TO postgres# + +ALTER TABLE edgv.elemnat_ilha_p + ADD CONSTRAINT elemnat_ilha_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_ilha (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ilha_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ilha_p + ADD CONSTRAINT elemnat_ilha_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ilha_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ilha_p + ADD CONSTRAINT elemnat_ilha_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ilha_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_ilha_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT elemnat_ilha_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_ilha_a_geom ON edgv.elemnat_ilha_a USING gist (geom)# + +ALTER TABLE edgv.elemnat_ilha_a OWNER TO postgres# + +ALTER TABLE edgv.elemnat_ilha_a + ADD CONSTRAINT elemnat_ilha_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_ilha (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ilha_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ilha_a + ADD CONSTRAINT elemnat_ilha_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ilha_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ilha_a + ADD CONSTRAINT elemnat_ilha_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ilha_a ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_ponto_cotado_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + cota real NOT NULL, + cota_comprovada smallint NOT NULL, + cota_mais_alta smallint NOT NULL, + label_x real, + label_y real, + visivel smallint NOT NULL, + ancora_horizontal smallint NOT NULL, + ancora_vertical smallint NOT NULL, + suprimir_simbologia smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT elemnat_ponto_cotado_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_ponto_cotado_p_geom ON edgv.elemnat_ponto_cotado_p USING gist (geom)# + +ALTER TABLE edgv.elemnat_ponto_cotado_p OWNER TO postgres# + +ALTER TABLE edgv.elemnat_ponto_cotado_p + ADD CONSTRAINT elemnat_ponto_cotado_p_cota_comprovada_fk FOREIGN KEY (cota_comprovada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN cota_comprovada SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ponto_cotado_p + ADD CONSTRAINT elemnat_ponto_cotado_p_cota_mais_alta_fk FOREIGN KEY (cota_mais_alta) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN cota_mais_alta SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ponto_cotado_p + ADD CONSTRAINT elemnat_ponto_cotado_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ponto_cotado_p + ADD CONSTRAINT elemnat_ponto_cotado_p_ancora_horizontal_fk FOREIGN KEY (ancora_horizontal) + REFERENCES dominios.ancora_horizontal (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN ancora_horizontal SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ponto_cotado_p + ADD CONSTRAINT elemnat_ponto_cotado_p_ancora_vertical_fk FOREIGN KEY (ancora_vertical) + REFERENCES dominios.ancora_vertical (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN ancora_vertical SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ponto_cotado_p + ADD CONSTRAINT elemnat_ponto_cotado_p_suprimir_simbologia_fk FOREIGN KEY (suprimir_simbologia) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN suprimir_simbologia SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_terreno_sujeito_inundacao_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT elemnat_terreno_sujeito_inundacao_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_terreno_sujeito_inundacao_a_geom ON edgv.elemnat_terreno_sujeito_inundacao_a USING gist (geom)# + +ALTER TABLE edgv.elemnat_terreno_sujeito_inundacao_a OWNER TO postgres# + +CREATE TABLE edgv.elemnat_toponimo_fisiografico_natural_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + espacamento real, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT elemnat_toponimo_fisiografico_natural_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_toponimo_fisiografico_natural_p_geom ON edgv.elemnat_toponimo_fisiografico_natural_p USING gist (geom)# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p OWNER TO postgres# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p + ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_toponimo_fisiografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p + ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_p_tipo_check + CHECK (tipo = ANY(ARRAY[2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 17 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p + ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_toponimo_fisiografico_natural_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + espacamento real, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT elemnat_toponimo_fisiografico_natural_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_toponimo_fisiografico_natural_l_geom ON edgv.elemnat_toponimo_fisiografico_natural_l USING gist (geom)# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l OWNER TO postgres# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l + ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_toponimo_fisiografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l + ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_l_tipo_check + CHECK (tipo = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 12 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l ALTER COLUMN tipo SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_trecho_drenagem_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_em_poligono smallint NOT NULL, + regime smallint NOT NULL, + texto_edicao varchar(255), + tamanho_txt real, + visivel smallint NOT NULL, + posicao_rotulo smallint NOT NULL, + direcao_fixada smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT elemnat_trecho_drenagem_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_trecho_drenagem_l_geom ON edgv.elemnat_trecho_drenagem_l USING gist (geom)# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l OWNER TO postgres# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l + ADD CONSTRAINT elemnat_trecho_drenagem_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_trecho_drenagem (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l + ADD CONSTRAINT elemnat_trecho_drenagem_l_situacao_em_poligono_fk FOREIGN KEY (situacao_em_poligono) + REFERENCES dominios.situacao_em_poligono (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN situacao_em_poligono SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l + ADD CONSTRAINT elemnat_trecho_drenagem_l_regime_fk FOREIGN KEY (regime) + REFERENCES dominios.regime (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN regime SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l + ADD CONSTRAINT elemnat_trecho_drenagem_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l + ADD CONSTRAINT elemnat_trecho_drenagem_l_posicao_rotulo_fk FOREIGN KEY (posicao_rotulo) + REFERENCES dominios.posicao_rotulo (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN posicao_rotulo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l + ADD CONSTRAINT elemnat_trecho_drenagem_l_direcao_fixada_fk FOREIGN KEY (direcao_fixada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN direcao_fixada SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_sumidouro_vertedouro_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + tipo smallint NOT NULL, + visivel smallint NOT NULL, + simb_rot real, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT elemnat_sumidouro_vertedouro_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_sumidouro_vertedouro_p_geom ON edgv.elemnat_sumidouro_vertedouro_p USING gist (geom)# + +ALTER TABLE edgv.elemnat_sumidouro_vertedouro_p OWNER TO postgres# + +ALTER TABLE edgv.elemnat_sumidouro_vertedouro_p + ADD CONSTRAINT elemnat_sumidouro_vertedouro_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_sumidouro_vertedouro (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_sumidouro_vertedouro_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_sumidouro_vertedouro_p + ADD CONSTRAINT elemnat_sumidouro_vertedouro_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_sumidouro_vertedouro_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_alteracao_fisiografica_antropica_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + sobreposto_transportes smallint NOT NULL, + visivel smallint NOT NULL, + exibir_lado_simbologia smallint NOT NULL, + largura_simbologia real, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_alteracao_fisiografica_antropica_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_alteracao_fisiografica_antropica_l_geom ON edgv.infra_alteracao_fisiografica_antropica_l USING gist (geom)# + +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l OWNER TO postgres# + +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l + ADD CONSTRAINT infra_alteracao_fisiografica_antropica_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_alteracao_fisiografica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l + ADD CONSTRAINT infra_alteracao_fisiografica_antropica_l_sobreposto_transportes_fk FOREIGN KEY (sobreposto_transportes) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ALTER COLUMN sobreposto_transportes SET DEFAULT 9999# + +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l + ADD CONSTRAINT infra_alteracao_fisiografica_antropica_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l + ADD CONSTRAINT infra_alteracao_fisiografica_antropica_l_exibir_lado_simbologia_fk FOREIGN KEY (exibir_lado_simbologia) + REFERENCES dominios.exibir_lado_simbologia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ALTER COLUMN exibir_lado_simbologia SET DEFAULT 9999# + +CREATE TABLE edgv.infra_barragem_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + material_construcao smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + sobreposto_transportes smallint NOT NULL, + largura_simbologia real, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_barragem_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_barragem_l_geom ON edgv.infra_barragem_l USING gist (geom)# + +ALTER TABLE edgv.infra_barragem_l OWNER TO postgres# + +ALTER TABLE edgv.infra_barragem_l + ADD CONSTRAINT infra_barragem_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_barragem (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_barragem_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_barragem_l + ADD CONSTRAINT infra_barragem_l_material_construcao_fk FOREIGN KEY (material_construcao) + REFERENCES dominios.material_construcao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_barragem_l + ADD CONSTRAINT infra_barragem_l_material_construcao_check + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_barragem_l ALTER COLUMN material_construcao SET DEFAULT 9999# + +ALTER TABLE edgv.infra_barragem_l + ADD CONSTRAINT infra_barragem_l_sobreposto_transportes_fk FOREIGN KEY (sobreposto_transportes) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_barragem_l ALTER COLUMN sobreposto_transportes SET DEFAULT 9999# + +ALTER TABLE edgv.infra_barragem_l + ADD CONSTRAINT infra_barragem_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_barragem_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_barragem_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + material_construcao smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + sobreposto_transportes smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT infra_barragem_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_barragem_a_geom ON edgv.infra_barragem_a USING gist (geom)# + +ALTER TABLE edgv.infra_barragem_a OWNER TO postgres# + +ALTER TABLE edgv.infra_barragem_a + ADD CONSTRAINT infra_barragem_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_barragem (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_barragem_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_barragem_a + ADD CONSTRAINT infra_barragem_a_material_construcao_fk FOREIGN KEY (material_construcao) + REFERENCES dominios.material_construcao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_barragem_a + ADD CONSTRAINT infra_barragem_a_material_construcao_check + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_barragem_a ALTER COLUMN material_construcao SET DEFAULT 9999# + +ALTER TABLE edgv.infra_barragem_a + ADD CONSTRAINT infra_barragem_a_sobreposto_transportes_fk FOREIGN KEY (sobreposto_transportes) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_barragem_a ALTER COLUMN sobreposto_transportes SET DEFAULT 9999# + +ALTER TABLE edgv.infra_barragem_a + ADD CONSTRAINT infra_barragem_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_barragem_a ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_energia_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + simb_rot real, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT infra_elemento_energia_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_energia_p_geom ON edgv.infra_elemento_energia_p USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_energia_p OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_energia_p + ADD CONSTRAINT infra_elemento_energia_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_energia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_p + ADD CONSTRAINT infra_elemento_energia_p_tipo_check + CHECK (tipo = ANY(ARRAY[1401 :: SMALLINT, 1701 :: SMALLINT, 405 :: SMALLINT, 406 :: SMALLINT, 407 :: SMALLINT, 408 :: SMALLINT, 409 :: SMALLINT, 498 :: SMALLINT, 1801 :: SMALLINT, 1802 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_p + ADD CONSTRAINT infra_elemento_energia_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_p + ADD CONSTRAINT infra_elemento_energia_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_p + ADD CONSTRAINT infra_elemento_energia_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_energia_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_elemento_energia_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_energia_l_geom ON edgv.infra_elemento_energia_l USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_energia_l OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_energia_l + ADD CONSTRAINT infra_elemento_energia_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_energia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_l + ADD CONSTRAINT infra_elemento_energia_l_tipo_check + CHECK (tipo = ANY(ARRAY[302 :: SMALLINT, 303 :: SMALLINT, 405 :: SMALLINT, 406 :: SMALLINT, 407 :: SMALLINT, 408 :: SMALLINT, 409 :: SMALLINT, 498 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_elemento_energia_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_l + ADD CONSTRAINT infra_elemento_energia_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_l + ADD CONSTRAINT infra_elemento_energia_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_energia_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT infra_elemento_energia_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_energia_a_geom ON edgv.infra_elemento_energia_a USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_energia_a OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_energia_a + ADD CONSTRAINT infra_elemento_energia_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_energia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_a + ADD CONSTRAINT infra_elemento_energia_a_tipo_check + CHECK (tipo = ANY(ARRAY[405 :: SMALLINT, 406 :: SMALLINT, 407 :: SMALLINT, 408 :: SMALLINT, 409 :: SMALLINT, 498 :: SMALLINT, 1801 :: SMALLINT, 1802 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_a + ADD CONSTRAINT infra_elemento_energia_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_a + ADD CONSTRAINT infra_elemento_energia_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_a + ADD CONSTRAINT infra_elemento_energia_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_infraestrutura_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT infra_elemento_infraestrutura_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_infraestrutura_a_geom ON edgv.infra_elemento_infraestrutura_a USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a + ADD CONSTRAINT infra_elemento_infraestrutura_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_infraestrutura (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a + ADD CONSTRAINT infra_elemento_infraestrutura_a_tipo_check + CHECK (tipo = ANY(ARRAY[701 :: SMALLINT, 801 :: SMALLINT, 1001 :: SMALLINT, 1400 :: SMALLINT, 1401 :: SMALLINT, 1402 :: SMALLINT, 1495 :: SMALLINT, 1801 :: SMALLINT, 1938 :: SMALLINT, 1939 :: SMALLINT, 1940 :: SMALLINT, 1941 :: SMALLINT, 1942 :: SMALLINT, 1943 :: SMALLINT, 1944 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a + ADD CONSTRAINT infra_elemento_infraestrutura_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a + ADD CONSTRAINT infra_elemento_infraestrutura_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a + ADD CONSTRAINT infra_elemento_infraestrutura_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_infraestrutura_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_elemento_infraestrutura_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_infraestrutura_l_geom ON edgv.infra_elemento_infraestrutura_l USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l + ADD CONSTRAINT infra_elemento_infraestrutura_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_infraestrutura (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l + ADD CONSTRAINT infra_elemento_infraestrutura_l_tipo_check + CHECK (tipo = ANY(ARRAY[701 :: SMALLINT, 801 :: SMALLINT, 901 :: SMALLINT, 1001 :: SMALLINT, 1501 :: SMALLINT, 1601 :: SMALLINT, 1938 :: SMALLINT, 1939 :: SMALLINT, 1940 :: SMALLINT, 1941 :: SMALLINT, 1942 :: SMALLINT, 1943 :: SMALLINT, 1944 :: SMALLINT, 2001 :: SMALLINT, 2098 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l + ADD CONSTRAINT infra_elemento_infraestrutura_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l + ADD CONSTRAINT infra_elemento_infraestrutura_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l + ADD CONSTRAINT infra_elemento_infraestrutura_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_infraestrutura_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT infra_elemento_infraestrutura_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_infraestrutura_p_geom ON edgv.infra_elemento_infraestrutura_p USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p + ADD CONSTRAINT infra_elemento_infraestrutura_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_infraestrutura (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p + ADD CONSTRAINT infra_elemento_infraestrutura_p_tipo_check + CHECK (tipo = ANY(ARRAY[901 :: SMALLINT, 1001 :: SMALLINT, 1201 :: SMALLINT, 1301 :: SMALLINT, 1400 :: SMALLINT, 1401 :: SMALLINT, 1402 :: SMALLINT, 1495 :: SMALLINT, 1601 :: SMALLINT, 1701 :: SMALLINT, 1801 :: SMALLINT, 1938 :: SMALLINT, 1939 :: SMALLINT, 1940 :: SMALLINT, 1941 :: SMALLINT, 1942 :: SMALLINT, 1943 :: SMALLINT, 1944 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p + ADD CONSTRAINT infra_elemento_infraestrutura_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p + ADD CONSTRAINT infra_elemento_infraestrutura_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p + ADD CONSTRAINT infra_elemento_infraestrutura_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_viario_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + material_construcao smallint NOT NULL, + modal_uso smallint NOT NULL, + nr_faixas varchar(255), + nr_pistas varchar(255), + posicao_pista smallint NOT NULL, + situacao_fisica smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + largura_simbologia real, + visivel smallint NOT NULL, + justificativa_txt smallint NOT NULL, + exibir_lado_simbologia smallint NOT NULL, + exibir_ponta_simbologia smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_elemento_viario_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_viario_l_geom ON edgv.infra_elemento_viario_l USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_viario_l OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_viario_l + ADD CONSTRAINT infra_elemento_viario_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_viario (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_l + ADD CONSTRAINT infra_elemento_viario_l_material_construcao_fk FOREIGN KEY (material_construcao) + REFERENCES dominios.material_construcao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_l + ADD CONSTRAINT infra_elemento_viario_l_material_construcao_check + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN material_construcao SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_l + ADD CONSTRAINT infra_elemento_viario_l_modal_uso_fk FOREIGN KEY (modal_uso) + REFERENCES dominios.modal_uso (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN modal_uso SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_l + ADD CONSTRAINT infra_elemento_viario_l_posicao_pista_fk FOREIGN KEY (posicao_pista) + REFERENCES dominios.posicao_pista (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN posicao_pista SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_l + ADD CONSTRAINT infra_elemento_viario_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_l + ADD CONSTRAINT infra_elemento_viario_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_l + ADD CONSTRAINT infra_elemento_viario_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_l + ADD CONSTRAINT infra_elemento_viario_l_exibir_lado_simbologia_fk FOREIGN KEY (exibir_lado_simbologia) + REFERENCES dominios.exibir_lado_simbologia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN exibir_lado_simbologia SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_l + ADD CONSTRAINT infra_elemento_viario_l_exibir_ponta_simbologia_fk FOREIGN KEY (exibir_ponta_simbologia) + REFERENCES dominios.exibir_ponta_simbologia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN exibir_ponta_simbologia SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_viario_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + material_construcao smallint NOT NULL, + modal_uso smallint NOT NULL, + nr_faixas varchar(255), + nr_pistas varchar(255), + posicao_pista smallint NOT NULL, + situacao_fisica smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + largura_simbologia real, + simb_rot real, + visivel smallint NOT NULL, + justificativa_txt smallint NOT NULL, + exibir_lado_simbologia smallint NOT NULL, + exibir_ponta_simbologia smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT infra_elemento_viario_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_viario_p_geom ON edgv.infra_elemento_viario_p USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_viario_p OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_viario_p + ADD CONSTRAINT infra_elemento_viario_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_viario (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_p + ADD CONSTRAINT infra_elemento_viario_p_material_construcao_fk FOREIGN KEY (material_construcao) + REFERENCES dominios.material_construcao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_p + ADD CONSTRAINT infra_elemento_viario_p_material_construcao_check + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN material_construcao SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_p + ADD CONSTRAINT infra_elemento_viario_p_modal_uso_fk FOREIGN KEY (modal_uso) + REFERENCES dominios.modal_uso (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN modal_uso SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_p + ADD CONSTRAINT infra_elemento_viario_p_posicao_pista_fk FOREIGN KEY (posicao_pista) + REFERENCES dominios.posicao_pista (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN posicao_pista SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_p + ADD CONSTRAINT infra_elemento_viario_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_p + ADD CONSTRAINT infra_elemento_viario_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_p + ADD CONSTRAINT infra_elemento_viario_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_p + ADD CONSTRAINT infra_elemento_viario_p_exibir_lado_simbologia_fk FOREIGN KEY (exibir_lado_simbologia) + REFERENCES dominios.exibir_lado_simbologia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN exibir_lado_simbologia SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_viario_p + ADD CONSTRAINT infra_elemento_viario_p_exibir_ponta_simbologia_fk FOREIGN KEY (exibir_ponta_simbologia) + REFERENCES dominios.exibir_ponta_simbologia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN exibir_ponta_simbologia SET DEFAULT 9999# + +CREATE TABLE edgv.infra_ferrovia_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + posicao_relativa smallint NOT NULL, + nr_linhas smallint NOT NULL, + eletrificada smallint NOT NULL, + bitola smallint NOT NULL, + em_arruamento smallint NOT NULL, + jurisdicao smallint NOT NULL, + administracao smallint NOT NULL, + concessionaria varchar(255), + texto_edicao varchar(255), + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_ferrovia_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_ferrovia_l_geom ON edgv.infra_ferrovia_l USING gist (geom)# + +ALTER TABLE edgv.infra_ferrovia_l OWNER TO postgres# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_ferrovia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_posicao_relativa_fk FOREIGN KEY (posicao_relativa) + REFERENCES dominios.posicao_relativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_posicao_relativa_check + CHECK (posicao_relativa = ANY(ARRAY[2 :: SMALLINT, 3 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN posicao_relativa SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_nr_linhas_fk FOREIGN KEY (nr_linhas) + REFERENCES dominios.nr_linhas (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN nr_linhas SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_eletrificada_fk FOREIGN KEY (eletrificada) + REFERENCES dominios.auxiliar (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN eletrificada SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_bitola_fk FOREIGN KEY (bitola) + REFERENCES dominios.bitola (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN bitola SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_em_arruamento_fk FOREIGN KEY (em_arruamento) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN em_arruamento SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_jurisdicao_fk FOREIGN KEY (jurisdicao) + REFERENCES dominios.jurisdicao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN jurisdicao SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_administracao_fk FOREIGN KEY (administracao) + REFERENCES dominios.administracao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN administracao SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_mobilidade_urbana_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_mobilidade_urbana_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_mobilidade_urbana_l_geom ON edgv.infra_mobilidade_urbana_l USING gist (geom)# + +ALTER TABLE edgv.infra_mobilidade_urbana_l OWNER TO postgres# + +ALTER TABLE edgv.infra_mobilidade_urbana_l + ADD CONSTRAINT infra_mobilidade_urbana_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_mobilidade_urbana (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_mobilidade_urbana_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_mobilidade_urbana_l + ADD CONSTRAINT infra_mobilidade_urbana_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_mobilidade_urbana_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_mobilidade_urbana_l + ADD CONSTRAINT infra_mobilidade_urbana_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_mobilidade_urbana_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_pista_pouso_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + revestimento smallint NOT NULL, + uso_pista smallint NOT NULL, + situacao_fisica smallint NOT NULL, + altitude real, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT infra_pista_pouso_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_pista_pouso_a_geom ON edgv.infra_pista_pouso_a USING gist (geom)# + +ALTER TABLE edgv.infra_pista_pouso_a OWNER TO postgres# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_pista_pouso (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_tipo_check + CHECK (tipo = ANY(ARRAY[9 :: SMALLINT, 10 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_revestimento_fk FOREIGN KEY (revestimento) + REFERENCES dominios.revestimento (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_revestimento_check + CHECK (revestimento = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN revestimento SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_uso_pista_fk FOREIGN KEY (uso_pista) + REFERENCES dominios.uso_pista (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN uso_pista SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.infra_pista_pouso_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + revestimento smallint NOT NULL, + uso_pista smallint NOT NULL, + situacao_fisica smallint NOT NULL, + altitude real, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_pista_pouso_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_pista_pouso_l_geom ON edgv.infra_pista_pouso_l USING gist (geom)# + +ALTER TABLE edgv.infra_pista_pouso_l OWNER TO postgres# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_pista_pouso (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_tipo_check + CHECK (tipo = ANY(ARRAY[9 :: SMALLINT, 10 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_revestimento_fk FOREIGN KEY (revestimento) + REFERENCES dominios.revestimento (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_revestimento_check + CHECK (revestimento = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN revestimento SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_uso_pista_fk FOREIGN KEY (uso_pista) + REFERENCES dominios.uso_pista (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN uso_pista SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.infra_pista_pouso_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + revestimento smallint NOT NULL, + uso_pista smallint NOT NULL, + situacao_fisica smallint NOT NULL, + altitude real, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + simb_rot real, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT infra_pista_pouso_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_pista_pouso_p_geom ON edgv.infra_pista_pouso_p USING gist (geom)# + +ALTER TABLE edgv.infra_pista_pouso_p OWNER TO postgres# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_pista_pouso (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_tipo_check + CHECK (tipo = ANY(ARRAY[9 :: SMALLINT, 11 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_revestimento_fk FOREIGN KEY (revestimento) + REFERENCES dominios.revestimento (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_revestimento_check + CHECK (revestimento = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN revestimento SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_uso_pista_fk FOREIGN KEY (uso_pista) + REFERENCES dominios.uso_pista (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN uso_pista SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.infra_travessia_hidroviaria_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_travessia_hidroviaria_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_travessia_hidroviaria_l_geom ON edgv.infra_travessia_hidroviaria_l USING gist (geom)# + +ALTER TABLE edgv.infra_travessia_hidroviaria_l OWNER TO postgres# + +ALTER TABLE edgv.infra_travessia_hidroviaria_l + ADD CONSTRAINT infra_travessia_hidroviaria_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_travessia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_travessia_hidroviaria_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_travessia_hidroviaria_l + ADD CONSTRAINT infra_travessia_hidroviaria_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_travessia_hidroviaria_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.infra_travessia_hidroviaria_l + ADD CONSTRAINT infra_travessia_hidroviaria_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_travessia_hidroviaria_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_trecho_duto_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + posicao_relativa smallint NOT NULL, + texto_edicao varchar(255), + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_trecho_duto_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_trecho_duto_l_geom ON edgv.infra_trecho_duto_l USING gist (geom)# + +ALTER TABLE edgv.infra_trecho_duto_l OWNER TO postgres# + +ALTER TABLE edgv.infra_trecho_duto_l + ADD CONSTRAINT infra_trecho_duto_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_trecho_duto (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_trecho_duto_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_trecho_duto_l + ADD CONSTRAINT infra_trecho_duto_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_trecho_duto_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_trecho_duto_l + ADD CONSTRAINT infra_trecho_duto_l_posicao_relativa_fk FOREIGN KEY (posicao_relativa) + REFERENCES dominios.posicao_relativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_trecho_duto_l ALTER COLUMN posicao_relativa SET DEFAULT 9999# + +ALTER TABLE edgv.infra_trecho_duto_l + ADD CONSTRAINT infra_trecho_duto_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_trecho_duto_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_vala_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + texto_edicao varchar(255), + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_vala_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_vala_l_geom ON edgv.infra_vala_l USING gist (geom)# + +ALTER TABLE edgv.infra_vala_l OWNER TO postgres# + +ALTER TABLE edgv.infra_vala_l + ADD CONSTRAINT infra_vala_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_vala_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_via_deslocamento_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + revestimento smallint NOT NULL, + trafego smallint NOT NULL, + nr_faixas varchar(255), + nr_pistas varchar(255), + canteiro_divisorio smallint NOT NULL, + situacao_fisica smallint NOT NULL, + jurisdicao smallint NOT NULL, + sigla varchar(255), + administracao smallint NOT NULL, + concessionaria varchar(255), + texto_edicao varchar(255), + visivel smallint NOT NULL, + ordem_simbologia integer, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_via_deslocamento_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_via_deslocamento_l_geom ON edgv.infra_via_deslocamento_l USING gist (geom)# + +ALTER TABLE edgv.infra_via_deslocamento_l OWNER TO postgres# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_via_deslocamento (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_revestimento_fk FOREIGN KEY (revestimento) + REFERENCES dominios.revestimento (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_revestimento_check + CHECK (revestimento = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN revestimento SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_trafego_fk FOREIGN KEY (trafego) + REFERENCES dominios.trafego (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN trafego SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_canteiro_divisorio_fk FOREIGN KEY (canteiro_divisorio) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN canteiro_divisorio SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_jurisdicao_fk FOREIGN KEY (jurisdicao) + REFERENCES dominios.jurisdicao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN jurisdicao SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_administracao_fk FOREIGN KEY (administracao) + REFERENCES dominios.administracao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_administracao_check + CHECK (administracao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 7 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN administracao SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.llp_delimitacao_fisica_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + tipo smallint NOT NULL, + material_construcao smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT llp_delimitacao_fisica_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX llp_delimitacao_fisica_l_geom ON edgv.llp_delimitacao_fisica_l USING gist (geom)# + +ALTER TABLE edgv.llp_delimitacao_fisica_l OWNER TO postgres# + +ALTER TABLE edgv.llp_delimitacao_fisica_l + ADD CONSTRAINT llp_delimitacao_fisica_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_delimitacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_delimitacao_fisica_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.llp_delimitacao_fisica_l + ADD CONSTRAINT llp_delimitacao_fisica_l_material_construcao_fk FOREIGN KEY (material_construcao) + REFERENCES dominios.material_construcao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_delimitacao_fisica_l + ADD CONSTRAINT llp_delimitacao_fisica_l_material_construcao_check + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 9 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.llp_delimitacao_fisica_l ALTER COLUMN material_construcao SET DEFAULT 9999# + +ALTER TABLE edgv.llp_delimitacao_fisica_l + ADD CONSTRAINT llp_delimitacao_fisica_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_delimitacao_fisica_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.llp_limite_especial_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + geometria_aproximada smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT llp_limite_especial_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX llp_limite_especial_a_geom ON edgv.llp_limite_especial_a USING gist (geom)# + +ALTER TABLE edgv.llp_limite_especial_a OWNER TO postgres# + +ALTER TABLE edgv.llp_limite_especial_a + ADD CONSTRAINT llp_limite_especial_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_limite_especial (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_limite_especial_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.llp_limite_especial_a + ADD CONSTRAINT llp_limite_especial_a_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_limite_especial_a ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +ALTER TABLE edgv.llp_limite_especial_a + ADD CONSTRAINT llp_limite_especial_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_limite_especial_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.llp_unidade_federacao_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + sigla varchar(255), + geometria_aproximada smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT llp_unidade_federacao_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX llp_unidade_federacao_a_geom ON edgv.llp_unidade_federacao_a USING gist (geom)# + +ALTER TABLE edgv.llp_unidade_federacao_a OWNER TO postgres# + +ALTER TABLE edgv.llp_unidade_federacao_a + ADD CONSTRAINT llp_unidade_federacao_a_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_unidade_federacao_a ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +CREATE TABLE edgv.llp_localidade_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + populacao integer, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT llp_localidade_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX llp_localidade_p_geom ON edgv.llp_localidade_p USING gist (geom)# + +ALTER TABLE edgv.llp_localidade_p OWNER TO postgres# + +ALTER TABLE edgv.llp_localidade_p + ADD CONSTRAINT llp_localidade_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_localidade (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_localidade_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.llp_localidade_p + ADD CONSTRAINT llp_localidade_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_localidade_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.llp_localidade_p + ADD CONSTRAINT llp_localidade_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_localidade_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.llp_ponto_controle_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + cod_ponto varchar(255), + tipo smallint NOT NULL, + tipo_ref smallint NOT NULL, + altitude_ortometrica varchar(255) NOT NULL, + altitude_geometrica varchar(255) NOT NULL, + sistema_geodesico smallint NOT NULL, + referencial_altim smallint NOT NULL, + referencial_grav smallint NOT NULL, + situacao_marco smallint NOT NULL, + orgao_responsavel varchar(255) NOT NULL, + latitude varchar(255) NOT NULL, + longitude varchar(255) NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT llp_ponto_controle_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX llp_ponto_controle_p_geom ON edgv.llp_ponto_controle_p USING gist (geom)# + +ALTER TABLE edgv.llp_ponto_controle_p OWNER TO postgres# + +ALTER TABLE edgv.llp_ponto_controle_p + ADD CONSTRAINT llp_ponto_controle_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_pto (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.llp_ponto_controle_p + ADD CONSTRAINT llp_ponto_controle_p_tipo_ref_fk FOREIGN KEY (tipo_ref) + REFERENCES dominios.tipo_ref (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN tipo_ref SET DEFAULT 9999# + +ALTER TABLE edgv.llp_ponto_controle_p + ADD CONSTRAINT llp_ponto_controle_p_sistema_geodesico_fk FOREIGN KEY (sistema_geodesico) + REFERENCES dominios.sistema_geodesico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN sistema_geodesico SET DEFAULT 9999# + +ALTER TABLE edgv.llp_ponto_controle_p + ADD CONSTRAINT llp_ponto_controle_p_referencial_altim_fk FOREIGN KEY (referencial_altim) + REFERENCES dominios.referencial_altim (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN referencial_altim SET DEFAULT 9999# + +ALTER TABLE edgv.llp_ponto_controle_p + ADD CONSTRAINT llp_ponto_controle_p_referencial_grav_fk FOREIGN KEY (referencial_grav) + REFERENCES dominios.referencial_grav (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN referencial_grav SET DEFAULT 9999# + +ALTER TABLE edgv.llp_ponto_controle_p + ADD CONSTRAINT llp_ponto_controle_p_situacao_marco_fk FOREIGN KEY (situacao_marco) + REFERENCES dominios.situacao_marco (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN situacao_marco SET DEFAULT 9999# + +ALTER TABLE edgv.llp_ponto_controle_p + ADD CONSTRAINT llp_ponto_controle_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.llp_pais_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + sigla varchar(3), + geometria_aproximada smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT llp_pais_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX llp_pais_a_geom ON edgv.llp_pais_a USING gist (geom)# + +ALTER TABLE edgv.llp_pais_a OWNER TO postgres# + +ALTER TABLE edgv.llp_pais_a + ADD CONSTRAINT llp_pais_a_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_pais_a ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_limite_especial_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + geometria_aproximada smallint NOT NULL, + sobreposto smallint NOT NULL, + exibir_rotulo_aproximado smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT edicao_limite_especial_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_limite_especial_l_geom ON edgv.edicao_limite_especial_l USING gist (geom)# + +ALTER TABLE edgv.edicao_limite_especial_l OWNER TO postgres# + +ALTER TABLE edgv.edicao_limite_especial_l + ADD CONSTRAINT edicao_limite_especial_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_limite_especial (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_limite_especial_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_limite_especial_l + ADD CONSTRAINT edicao_limite_especial_l_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_limite_especial_l ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_limite_especial_l + ADD CONSTRAINT edicao_limite_especial_l_sobreposto_fk FOREIGN KEY (sobreposto) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_limite_especial_l ALTER COLUMN sobreposto SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_limite_especial_l + ADD CONSTRAINT edicao_limite_especial_l_exibir_rotulo_aproximado_fk FOREIGN KEY (exibir_rotulo_aproximado) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_limite_especial_l ALTER COLUMN exibir_rotulo_aproximado SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_limite_legal_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + geometria_aproximada smallint NOT NULL, + texto_edicao varchar(255), + sobreposto smallint NOT NULL, + exibir_rotulo_aproximado smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT edicao_limite_legal_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_limite_legal_l_geom ON edgv.edicao_limite_legal_l USING gist (geom)# + +ALTER TABLE edgv.edicao_limite_legal_l OWNER TO postgres# + +ALTER TABLE edgv.edicao_limite_legal_l + ADD CONSTRAINT edicao_limite_legal_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_limite_legal (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_limite_legal_l + ADD CONSTRAINT edicao_limite_legal_l_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_limite_legal_l + ADD CONSTRAINT edicao_limite_legal_l_sobreposto_fk FOREIGN KEY (sobreposto) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN sobreposto SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_limite_legal_l + ADD CONSTRAINT edicao_limite_legal_l_exibir_rotulo_aproximado_fk FOREIGN KEY (exibir_rotulo_aproximado) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN exibir_rotulo_aproximado SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_area_sem_dados_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT edicao_area_sem_dados_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_area_sem_dados_a_geom ON edgv.edicao_area_sem_dados_a USING gist (geom)# + +ALTER TABLE edgv.edicao_area_sem_dados_a OWNER TO postgres# + +ALTER TABLE edgv.edicao_area_sem_dados_a + ADD CONSTRAINT edicao_area_sem_dados_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_area_sem_dados_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.centroide_area_sem_dados_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT centroide_area_sem_dados_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX centroide_area_sem_dados_p_geom ON edgv.centroide_area_sem_dados_p USING gist (geom)# + +ALTER TABLE edgv.centroide_area_sem_dados_p OWNER TO postgres# + +CREATE TABLE edgv.delimitador_area_sem_dados_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT delimitador_area_sem_dados_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX delimitador_area_sem_dados_l_geom ON edgv.delimitador_area_sem_dados_l USING gist (geom)# + +ALTER TABLE edgv.delimitador_area_sem_dados_l OWNER TO postgres# + +CREATE TABLE edgv.aux_validacao_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + subfase_id integer, + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT aux_validacao_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_validacao_a_geom ON edgv.aux_validacao_a USING gist (geom)# + +ALTER TABLE edgv.aux_validacao_a OWNER TO postgres# + +CREATE TABLE edgv.aux_validacao_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + subfase_id integer, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT aux_validacao_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_validacao_l_geom ON edgv.aux_validacao_l USING gist (geom)# + +ALTER TABLE edgv.aux_validacao_l OWNER TO postgres# + +CREATE TABLE edgv.aux_validacao_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + subfase_id integer, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT aux_validacao_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_validacao_p_geom ON edgv.aux_validacao_p USING gist (geom)# + +ALTER TABLE edgv.aux_validacao_p OWNER TO postgres# + +CREATE TABLE edgv.aux_revisao_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + subfase_id integer, + corrigido smallint NOT NULL, + justificativa varchar(255), + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT aux_revisao_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_revisao_a_geom ON edgv.aux_revisao_a USING gist (geom)# + +ALTER TABLE edgv.aux_revisao_a OWNER TO postgres# + +ALTER TABLE edgv.aux_revisao_a + ADD CONSTRAINT aux_revisao_a_corrigido_fk FOREIGN KEY (corrigido) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.aux_revisao_a ALTER COLUMN corrigido SET DEFAULT 9999# + +CREATE TABLE edgv.aux_revisao_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + subfase_id integer, + corrigido smallint NOT NULL, + justificativa varchar(255), + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT aux_revisao_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_revisao_l_geom ON edgv.aux_revisao_l USING gist (geom)# + +ALTER TABLE edgv.aux_revisao_l OWNER TO postgres# + +ALTER TABLE edgv.aux_revisao_l + ADD CONSTRAINT aux_revisao_l_corrigido_fk FOREIGN KEY (corrigido) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.aux_revisao_l ALTER COLUMN corrigido SET DEFAULT 9999# + +CREATE TABLE edgv.aux_revisao_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + subfase_id integer, + corrigido smallint NOT NULL, + justificativa varchar(255), + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT aux_revisao_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_revisao_p_geom ON edgv.aux_revisao_p USING gist (geom)# + +ALTER TABLE edgv.aux_revisao_p OWNER TO postgres# + +ALTER TABLE edgv.aux_revisao_p + ADD CONSTRAINT aux_revisao_p_corrigido_fk FOREIGN KEY (corrigido) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.aux_revisao_p ALTER COLUMN corrigido SET DEFAULT 9999# + +CREATE TABLE edgv.aux_reambulacao_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT aux_reambulacao_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_reambulacao_a_geom ON edgv.aux_reambulacao_a USING gist (geom)# + +ALTER TABLE edgv.aux_reambulacao_a OWNER TO postgres# + +CREATE TABLE edgv.aux_reambulacao_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT aux_reambulacao_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_reambulacao_l_geom ON edgv.aux_reambulacao_l USING gist (geom)# + +ALTER TABLE edgv.aux_reambulacao_l OWNER TO postgres# + +CREATE TABLE edgv.aux_reambulacao_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT aux_reambulacao_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_reambulacao_p_geom ON edgv.aux_reambulacao_p USING gist (geom)# + +ALTER TABLE edgv.aux_reambulacao_p OWNER TO postgres# + +CREATE TABLE edgv.aux_insumo_externo_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + fonte varchar(255), + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT aux_insumo_externo_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_insumo_externo_a_geom ON edgv.aux_insumo_externo_a USING gist (geom)# + +ALTER TABLE edgv.aux_insumo_externo_a OWNER TO postgres# + +CREATE TABLE edgv.aux_insumo_externo_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + fonte varchar(255), + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT aux_insumo_externo_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_insumo_externo_l_geom ON edgv.aux_insumo_externo_l USING gist (geom)# + +ALTER TABLE edgv.aux_insumo_externo_l OWNER TO postgres# + +CREATE TABLE edgv.aux_insumo_externo_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + fonte varchar(255), + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT aux_insumo_externo_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_insumo_externo_p_geom ON edgv.aux_insumo_externo_p USING gist (geom)# + +ALTER TABLE edgv.aux_insumo_externo_p OWNER TO postgres# + +CREATE TABLE edgv.aux_moldura_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + mi varchar(255), + inom varchar(255), + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT aux_moldura_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_moldura_a_geom ON edgv.aux_moldura_a USING gist (geom)# + +ALTER TABLE edgv.aux_moldura_a OWNER TO postgres# + +CREATE TABLE edgv.aux_moldura_area_continua_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + observacao varchar(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT aux_moldura_area_continua_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_moldura_area_continua_a_geom ON edgv.aux_moldura_area_continua_a USING gist (geom)# + +ALTER TABLE edgv.aux_moldura_area_continua_a OWNER TO postgres# + +CREATE TABLE edgv.edicao_grid_edicao_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT edicao_grid_edicao_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_grid_edicao_l_geom ON edgv.edicao_grid_edicao_l USING gist (geom)# + +ALTER TABLE edgv.edicao_grid_edicao_l OWNER TO postgres# + +CREATE TABLE edgv.delimitador_vegetacao_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT delimitador_vegetacao_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX delimitador_vegetacao_l_geom ON edgv.delimitador_vegetacao_l USING gist (geom)# + +ALTER TABLE edgv.delimitador_vegetacao_l OWNER TO postgres# + +CREATE TABLE edgv.delimitador_massa_dagua_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT delimitador_massa_dagua_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX delimitador_massa_dagua_l_geom ON edgv.delimitador_massa_dagua_l USING gist (geom)# + +ALTER TABLE edgv.delimitador_massa_dagua_l OWNER TO postgres# + +CREATE TABLE edgv.delimitador_area_construida_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT delimitador_area_construida_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX delimitador_area_construida_l_geom ON edgv.delimitador_area_construida_l USING gist (geom)# + +ALTER TABLE edgv.delimitador_area_construida_l OWNER TO postgres# + +CREATE TABLE edgv.delimitador_elemento_hidrografico_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT delimitador_elemento_hidrografico_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX delimitador_elemento_hidrografico_l_geom ON edgv.delimitador_elemento_hidrografico_l USING gist (geom)# + +ALTER TABLE edgv.delimitador_elemento_hidrografico_l OWNER TO postgres# + +CREATE TABLE edgv.delimitador_limite_especial_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT delimitador_limite_especial_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX delimitador_limite_especial_l_geom ON edgv.delimitador_limite_especial_l USING gist (geom)# + +ALTER TABLE edgv.delimitador_limite_especial_l OWNER TO postgres# + +CREATE TABLE edgv.centroide_vegetacao_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + tipo smallint NOT NULL, + sujeito_inundacao smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT centroide_vegetacao_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX centroide_vegetacao_p_geom ON edgv.centroide_vegetacao_p USING gist (geom)# + +ALTER TABLE edgv.centroide_vegetacao_p OWNER TO postgres# + +ALTER TABLE edgv.centroide_vegetacao_p + ADD CONSTRAINT centroide_vegetacao_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_veg (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_vegetacao_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.centroide_vegetacao_p + ADD CONSTRAINT centroide_vegetacao_p_sujeito_inundacao_fk FOREIGN KEY (sujeito_inundacao) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_vegetacao_p ALTER COLUMN sujeito_inundacao SET DEFAULT 9999# + +CREATE TABLE edgv.centroide_massa_dagua_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + regime smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT centroide_massa_dagua_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX centroide_massa_dagua_p_geom ON edgv.centroide_massa_dagua_p USING gist (geom)# + +ALTER TABLE edgv.centroide_massa_dagua_p OWNER TO postgres# + +ALTER TABLE edgv.centroide_massa_dagua_p + ADD CONSTRAINT centroide_massa_dagua_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_massa_dagua (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_massa_dagua_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.centroide_massa_dagua_p + ADD CONSTRAINT centroide_massa_dagua_p_regime_fk FOREIGN KEY (regime) + REFERENCES dominios.regime (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_massa_dagua_p ALTER COLUMN regime SET DEFAULT 9999# + +CREATE TABLE edgv.centroide_area_construida_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + densamente_edificada smallint NOT NULL, + assentamento_precario smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT centroide_area_construida_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX centroide_area_construida_p_geom ON edgv.centroide_area_construida_p USING gist (geom)# + +ALTER TABLE edgv.centroide_area_construida_p OWNER TO postgres# + +ALTER TABLE edgv.centroide_area_construida_p + ADD CONSTRAINT centroide_area_construida_p_densamente_edificada_fk FOREIGN KEY (densamente_edificada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_area_construida_p ALTER COLUMN densamente_edificada SET DEFAULT 9999# + +ALTER TABLE edgv.centroide_area_construida_p + ADD CONSTRAINT centroide_area_construida_p_assentamento_precario_fk FOREIGN KEY (assentamento_precario) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_area_construida_p ALTER COLUMN assentamento_precario SET DEFAULT 9999# + +CREATE TABLE edgv.centroide_ilha_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT centroide_ilha_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX centroide_ilha_p_geom ON edgv.centroide_ilha_p USING gist (geom)# + +ALTER TABLE edgv.centroide_ilha_p OWNER TO postgres# + +ALTER TABLE edgv.centroide_ilha_p + ADD CONSTRAINT centroide_ilha_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_ilha (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_ilha_p ALTER COLUMN tipo SET DEFAULT 9999# + +CREATE TABLE edgv.centroide_elemento_hidrografico_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT centroide_elemento_hidrografico_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX centroide_elemento_hidrografico_p_geom ON edgv.centroide_elemento_hidrografico_p USING gist (geom)# + +ALTER TABLE edgv.centroide_elemento_hidrografico_p OWNER TO postgres# + +ALTER TABLE edgv.centroide_elemento_hidrografico_p + ADD CONSTRAINT centroide_elemento_hidrografico_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_hidrografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_elemento_hidrografico_p + ADD CONSTRAINT centroide_elemento_hidrografico_p_tipo_check + CHECK (tipo = ANY(ARRAY[6 :: SMALLINT, 8 :: SMALLINT, 12 :: SMALLINT, 14 :: SMALLINT, 15 :: SMALLINT, 16 :: SMALLINT, 17 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.centroide_elemento_hidrografico_p ALTER COLUMN tipo SET DEFAULT 9999# + +CREATE TABLE edgv.centroide_limite_especial_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + geometria_aproximada smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT centroide_limite_especial_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX centroide_limite_especial_p_geom ON edgv.centroide_limite_especial_p USING gist (geom)# + +ALTER TABLE edgv.centroide_limite_especial_p OWNER TO postgres# + +ALTER TABLE edgv.centroide_limite_especial_p + ADD CONSTRAINT centroide_limite_especial_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_limite_especial (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_limite_especial_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.centroide_limite_especial_p + ADD CONSTRAINT centroide_limite_especial_p_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_limite_especial_p ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_texto_generico_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + texto_edicao varchar(255), + label_x real, + label_y real, + estilo_fonte varchar(255), + tamanho_txt real, + justificativa_txt smallint NOT NULL, + espacamento real, + cor varchar(255), + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT edicao_texto_generico_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_texto_generico_p_geom ON edgv.edicao_texto_generico_p USING gist (geom)# + +ALTER TABLE edgv.edicao_texto_generico_p OWNER TO postgres# + +ALTER TABLE edgv.edicao_texto_generico_p + ADD CONSTRAINT edicao_texto_generico_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_texto_generico_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_texto_generico_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + texto_edicao varchar(255), + estilo_fonte varchar(255), + tamanho_txt real, + espacamento real, + cor varchar(255), + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT edicao_texto_generico_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_texto_generico_l_geom ON edgv.edicao_texto_generico_l USING gist (geom)# + +ALTER TABLE edgv.edicao_texto_generico_l OWNER TO postgres# + +CREATE TABLE edgv.edicao_simb_cota_mestra_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + texto_edicao varchar(255), + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT edicao_simb_cota_mestra_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_simb_cota_mestra_l_geom ON edgv.edicao_simb_cota_mestra_l USING gist (geom)# + +ALTER TABLE edgv.edicao_simb_cota_mestra_l OWNER TO postgres# + +CREATE TABLE edgv.edicao_simb_torre_energia_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + simb_rot real, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT edicao_simb_torre_energia_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_simb_torre_energia_p_geom ON edgv.edicao_simb_torre_energia_p USING gist (geom)# + +ALTER TABLE edgv.edicao_simb_torre_energia_p OWNER TO postgres# + +CREATE TABLE edgv.edicao_identificador_trecho_rod_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + sigla varchar(255), + tipo smallint NOT NULL, + jurisdicao smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT edicao_identificador_trecho_rod_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_identificador_trecho_rod_p_geom ON edgv.edicao_identificador_trecho_rod_p USING gist (geom)# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p OWNER TO postgres# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p + ADD CONSTRAINT edicao_identificador_trecho_rod_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_via_deslocamento (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p + ADD CONSTRAINT edicao_identificador_trecho_rod_p_jurisdicao_fk FOREIGN KEY (jurisdicao) + REFERENCES dominios.jurisdicao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p + ADD CONSTRAINT edicao_identificador_trecho_rod_p_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p ALTER COLUMN jurisdicao SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_simb_vegetacao_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + texto_edicao varchar(255), + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT edicao_simb_vegetacao_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_simb_vegetacao_p_geom ON edgv.edicao_simb_vegetacao_p USING gist (geom)# + +ALTER TABLE edgv.edicao_simb_vegetacao_p OWNER TO postgres# + +CREATE TABLE edgv.edicao_simb_direcao_corrente_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + simb_rot real, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT edicao_simb_direcao_corrente_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_simb_direcao_corrente_p_geom ON edgv.edicao_simb_direcao_corrente_p USING gist (geom)# + +ALTER TABLE edgv.edicao_simb_direcao_corrente_p OWNER TO postgres# + +CREATE TABLE edgv.edicao_simb_area_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + tipo smallint NOT NULL, + simb_rot real, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT edicao_simb_area_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_simb_area_p_geom ON edgv.edicao_simb_area_p USING gist (geom)# + +ALTER TABLE edgv.edicao_simb_area_p OWNER TO postgres# + +ALTER TABLE edgv.edicao_simb_area_p + ADD CONSTRAINT edicao_simb_area_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_simbolo_area (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_simb_area_p ALTER COLUMN tipo SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_borda_elemento_hidrografico_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + tipo smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT edicao_borda_elemento_hidrografico_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_borda_elemento_hidrografico_l_geom ON edgv.edicao_borda_elemento_hidrografico_l USING gist (geom)# + +ALTER TABLE edgv.edicao_borda_elemento_hidrografico_l OWNER TO postgres# + +ALTER TABLE edgv.edicao_borda_elemento_hidrografico_l + ADD CONSTRAINT edicao_borda_elemento_hidrografico_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_borda_elemento_hidrografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_borda_elemento_hidrografico_l ALTER COLUMN tipo SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_ponto_mudanca_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + simb_rot real, + desloc real, + visivel smallint NOT NULL, + observacao varchar(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT edicao_ponto_mudanca_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_ponto_mudanca_p_geom ON edgv.edicao_ponto_mudanca_p USING gist (geom)# + +ALTER TABLE edgv.edicao_ponto_mudanca_p OWNER TO postgres# + +ALTER TABLE edgv.edicao_ponto_mudanca_p + ADD CONSTRAINT edicao_ponto_mudanca_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_ponto_mudanca_p ALTER COLUMN visivel SET DEFAULT 9999# \ No newline at end of file diff --git a/DsgTools/core/Factories/DbCreatorFactory/spatialiteDbCreator.py b/DsgTools/core/Factories/DbCreatorFactory/spatialiteDbCreator.py index 7100309be..838a5f02b 100644 --- a/DsgTools/core/Factories/DbCreatorFactory/spatialiteDbCreator.py +++ b/DsgTools/core/Factories/DbCreatorFactory/spatialiteDbCreator.py @@ -66,6 +66,8 @@ def getTemplateLocation(self, version): "3", "seed_edgv3.sqlite", ) + else: + raise Exception(self.tr("Unsuported model version fro sqlite creation")) return edgvPath def createDb(self, dbName, srid, paramDict=dict(), parentWidget=None): diff --git a/DsgTools/core/Factories/DbFactory/postgisDb.py b/DsgTools/core/Factories/DbFactory/postgisDb.py index e4e916828..56508a481 100644 --- a/DsgTools/core/Factories/DbFactory/postgisDb.py +++ b/DsgTools/core/Factories/DbFactory/postgisDb.py @@ -3503,7 +3503,7 @@ def getTemplateName(self, version): return "template_edgv_213_pro" elif version == "FTer_2a_Ed": return "template_edgv_fter_2a_ed" - elif version == "3.0": + elif version in ("3.0", "EDGV 3.0"): return "template_edgv_3" elif version in ("EDGV 3.0 Pro", "3.0 Pro"): return "template_edgv_3_pro" @@ -3578,7 +3578,7 @@ def getCreationSqlPath(self, version): "FTer_2a_Ed", "edgvFter_2a_Ed.sql", ) - elif version == "3.0": + elif version in ("3.0", "EDGV 3.0"): edgvPath = os.path.join( currentPath, "..", @@ -3590,7 +3590,7 @@ def getCreationSqlPath(self, version): "3", "edgv3.sql", ) - elif version == "3.0 Pro": + elif version in ("3.0 Pro", "EDGV 3.0 Pro"): edgvPath = os.path.join( currentPath, "..", diff --git a/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py b/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py index 7e95968b7..b368fdc08 100644 --- a/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py +++ b/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py @@ -1543,8 +1543,8 @@ def alterSearchPath(self, dbName, version): sql = "ALTER DATABASE \"{0}\" SET search_path = \"$user\", public, topology,'edgv','dominios';".format( dbName ) - elif version == "3.0": - sql = "ALTER DATABASE \"{0}\" SET search_path = \"$user\", public, topology,'edgv','complexos','dominios';".format( + elif version in ("3.0", "3.0 Pro"): + sql = "ALTER DATABASE \"{0}\" SET search_path = \"$user\", public, topology, pg_catalog, 'edgv' ,'dominios';".format( dbName ) elif version == "FTer_2a_Ed": diff --git a/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/connectionComboBox.py b/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/connectionComboBox.py index 2c21f5f18..133e7b6d8 100644 --- a/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/connectionComboBox.py +++ b/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/connectionComboBox.py @@ -67,6 +67,7 @@ def __init__(self, parent=None, isStatic=False): "FTer_2a_Ed": "EDGV FTer 2a Ed", "Non_EDGV": self.tr("Other database model"), "3.0": "EDGV 3.0", + "3.0 Pro": "EDGV 3.0 Pro", } self.instantiateAbstractDb = False self.isStatic = isStatic diff --git a/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/databaseFileLineEdit.py b/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/databaseFileLineEdit.py index dfd00186b..89f00ccb7 100644 --- a/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/databaseFileLineEdit.py +++ b/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/databaseFileLineEdit.py @@ -63,6 +63,7 @@ def __init__(self, parent=None): "FTer_2a_Ed": "EDGV FTer 2a Ed", "Non_EDGV": self.tr("Other database model"), "3.0": "EDGV 3.0", + "3.0 Pro": "EDGV 3.0 Pro", } self.instantiateAbstractDb = False self.connectionSelectorLineEdit.lineEdit.setText(self.tr("Select datasource")) diff --git a/DsgTools/gui/CustomWidgets/DatabasePropertiesWidgets/BasicPropertyWidgets/databaseParameterWidget.ui b/DsgTools/gui/CustomWidgets/DatabasePropertiesWidgets/BasicPropertyWidgets/databaseParameterWidget.ui index 6459815f8..66fc4f77c 100644 --- a/DsgTools/gui/CustomWidgets/DatabasePropertiesWidgets/BasicPropertyWidgets/databaseParameterWidget.ui +++ b/DsgTools/gui/CustomWidgets/DatabasePropertiesWidgets/BasicPropertyWidgets/databaseParameterWidget.ui @@ -70,6 +70,11 @@ 3.0 + + + 3.0 Pro + + diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 0720b41c5..257f34f4b 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -44,6 +44,11 @@ about= # Uncomment the following line and add your changelog: changelog= + 4.10.1: + Melhoria: + - Adicionado o modelo EDGV 3.0 Pro; + Correção de Bug: + - Correção de erro ao criar banco EDGV 3.0; 4.10.0: Novas Funcionalidades: - Novo processo de identificar erros de construção em linhas que devem se sobrepor (exemplo, barragem e rodovia); diff --git a/README.md b/README.md index 663c7878e..411ae5fcc 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ ------------------------------------ # Complemento DSGTools -O DSGTools é um complemento para o QGIS (http://qgis.org/pt_BR/site/) que permite aos usuários a criação e utilização de produtos cartográficos de acordo com as especificações da ET-EDGV 2.1.3 e da ET-EDGV Defesa F Ter 2ª Edição. O DSGTools visa atender não apenas o Exército Brasileiro, mas também produtores e usuários de geoinformação da sociedade. +O DSGTools é um complemento para o QGIS (http://qgis.org/pt_BR/site/) que permite aos usuários a criação e utilização de produtos cartográficos de acordo com as especificações da ET-EDGV 2.1.3 e da ET-EDGV 3.0. O DSGTools visa atender não apenas o Exército Brasileiro, mas também produtores e usuários de geoinformação da sociedade. Este projeto visa cumprir a missão estabelecida no Plano Estratégico do Exército 2016-2019 (PEEx 2016-2019), relativo ao seguinte Objetivo Estratégico do Exército (OEE): * OEE 7 - Aprimorar a Governança de Tecnologia da Informação; * Estratégia 7.2 - Reorganização do Sistema de Informação do Exército (SINFOEx); @@ -26,9 +26,9 @@ O plugin foi todo desenvolvido em python e está disponível para download pelo Estão disponíveis as seguintes funcionalidades no plugin em sua versão 3.1 (changelog completo disponível em https://github.com/dsgoficial/DsgTools/wiki ): - Criação, armazenamento e remoção de configuração de servidores PostGIS; -- Criação de banco de dados em Spatialite e em PostGIS de acordo a ET-EDGV 2.1.3, ET-EDGV 3.0 e ET-EDGV Defesa F Ter 2ª Edição; -- Criação de banco de dados em Spatialite e em PostGIS de acordo com ET-EDGV 2.1.3, ET-EDGV 3.0 e ET-EDGV Defesa F Ter 2ª Edição; -- Carregamento de camadas por classe e por categoria conforme definido na ET-EDGV 2.1.3, ET-EDGV 3.0 e ET-EDGV Defesa F Ter 2ª Edição; +- Criação de banco de dados em Spatialite e em PostGIS de acordo a ET-EDGV 2.1.3 e ET-EDGV 3.0; +- Criação de banco de dados em Spatialite e em PostGIS de acordo com ET-EDGV 2.1.3, ET-EDGV 3.0; +- Carregamento de camadas por classe e por categoria conforme definido na ET-EDGV 2.1.3, ET-EDGV 3.0; - Manipulação de feições complexas (criação, edição, remoção, zoom, associação e desassociação); - Acesso a alguns serviços WM(T)S do BDGEx e; - Acesso ao mapa índice de produtos vetoriais e matriciais do BDGEx. From f2ee3bc6def075181260affa12c24851c3a6b745 Mon Sep 17 00:00:00 2001 From: phborba Date: Mon, 2 Oct 2023 14:15:52 -0300 Subject: [PATCH 02/53] corrige changelog --- CHANGELOG.md | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d0c96f90d..f053d853b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,19 +1,7 @@ # CHANGELOG -## 4.10.1 - 2023-10-02 - -Melhoria: - -- Adicionado o modelo EDGV 3.0 Pro; - -Correção de Bug: - -- Correção de erro ao criar banco EDGV 3.0; - ## 4.11.16 - dev - - Novas Funcionalidades: - Novo processo de corrigir erros de segmentação em linhas (barragem versus rodovias); @@ -41,6 +29,15 @@ Correção de bug: - Corrige bug na geração de moldura relativo a camada (Generate Systematic Grid Related to Layer) quando se usa memory layer (o memory layer não atualiza seu extent automaticamente, logo foi necessário colocar um layer.updateExtents() no código antes de calcular o extent); - Corrige bug no processo de calcular azimute (estava sendo calculado com +90 graus); +## 4.10.1 - 2023-10-02 + +Melhoria: + +- Adicionado o modelo EDGV 3.0 Pro; + +Correção de Bug: + +- Correção de erro ao criar banco EDGV 3.0; ## 4.10.0 - 2023-09-08 From 380b984a9215f1248ff4209b448623eb2a876928 Mon Sep 17 00:00:00 2001 From: phborba Date: Mon, 2 Oct 2023 14:46:00 -0300 Subject: [PATCH 03/53] =?UTF-8?q?Vers=C3=A3o=204.11.17:=20melhoria=20no=20?= =?UTF-8?q?detecta=20nula?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 +- .../detectNullGeometriesAlgorithm.py | 36 +++++++++++++++++-- DsgTools/metadata.txt | 2 +- 3 files changed, 36 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f053d853b..c06aef59b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.16 - dev +## 4.11.17 - dev Novas Funcionalidades: @@ -16,6 +16,7 @@ Melhorias: - O seletor genérico agora ignora camadas somente leitura; - Melhoria de desempenho no processo Unir Linhas com Mesmo Conjunto de Atributos (Merge Lines With Same Attribute Set): Código refatorado para usar busca utilizando grafo. Além disso, o processo pega casos que não eram unidos anteriormente (linhas com mesmo conjunto de atributos e encadeadas); - Melhoria de desempenho no processo Identify Unmerged Lines With Same Attribute Set: Código refatorado para usar busca utilizando grafo; +- O detecta nula agora indica quais camadas tem que ser verificadas; Correção de bug: diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectNullGeometriesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectNullGeometriesAlgorithm.py index 74406244e..bd25347c7 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectNullGeometriesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectNullGeometriesAlgorithm.py @@ -20,21 +20,26 @@ * * ***************************************************************************/ """ +import concurrent.futures +import os from PyQt5.QtCore import QCoreApplication from PyQt5.QtGui import QColor from qgis.PyQt.Qt import QVariant from qgis.core import ( QgsProcessingAlgorithm, QgsProcessingParameterMultipleLayers, + QgsProcessingParameterBoolean, QgsField, QgsVectorLayer, QgsConditionalStyle, QgsExpression, + QgsProcessingMultiStepFeedback, ) class DetectNullGeometriesAlgorithm(QgsProcessingAlgorithm): INPUT_LAYERS = "INPUT_LAYERS" + RUN_CHECK_ON_INPUT = "RUN_CHECK_ON_INPUT" def initAlgorithm(self, config=None): self.addParameter( @@ -42,25 +47,50 @@ def initAlgorithm(self, config=None): self.INPUT_LAYERS, self.tr("Input layers") ) ) + self.addParameter( + QgsProcessingParameterBoolean( + self.RUN_CHECK_ON_INPUT, + self.tr("Run check in input layers"), + defaultValue=True, + ) + ) def processAlgorithm(self, parameters, context, feedback): """ Here is where the processing itself takes place. """ inputLyrList = self.parameterAsLayerList(parameters, self.INPUT_LAYERS, context) + runCheckOnInput = self.parameterAsBool(parameters, self.RUN_CHECK_ON_INPUT, context) if not inputLyrList: return {} - + multiStepFeedback = QgsProcessingMultiStepFeedback(2, feedback) if runCheckOnInput else feedback listSize = len(inputLyrList) stepSize = 100 / listSize if listSize else 0 - + def compute(lyr): + return lyr.name(), any(feat.geometry().isNull() or feat.geometry().isEmpty() for feat in lyr.getFeatures()) + if runCheckOnInput: + pool = concurrent.futures.ThreadPoolExecutor(os.cpu_count()) + futures = set() + multiStepFeedback.setCurrentStep(0) for current, lyr in enumerate(inputLyrList): if feedback.isCanceled(): break self.addRuleToLayer(lyr, feedback=feedback) self.createRuleVirtualField(lyr) - feedback.setProgress(current * stepSize) + if runCheckOnInput: + futures.add(pool.submit(compute, lyr)) + multiStepFeedback.setProgress(current * stepSize) + if not runCheckOnInput: + return {} + multiStepFeedback.setCurrentStep(1) + for current, future in enumerate(concurrent.futures.as_completed(futures)): + if feedback.isCanceled(): + break + lyrName, hasNullOrEmpty = future.result() + if hasNullOrEmpty: + multiStepFeedback.pushInfo(self.tr(f"Check layer {lyrName} for empty or null values.")) + multiStepFeedback.setProgress(current * stepSize) return {} def addRuleToLayer(self, lyr: QgsVectorLayer, feedback=None): diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 257f34f4b..e84cbfbcd 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.16 +version=4.11.17 author=Brazilian Army Geographic Service email=suporte.dsgtools@dsg.eb.mil.br about= From 21cd94964918ce33ac21047f2d68864510ae3b10 Mon Sep 17 00:00:00 2001 From: phborba Date: Mon, 2 Oct 2023 18:21:18 -0300 Subject: [PATCH 04/53] =?UTF-8?q?reorganiza=C3=A7=C3=A3o=20dos=20processin?= =?UTF-8?q?gs?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../appendFeaturesToLayerAlgorithm.py | 2 +- ...ndCopyFeaturesBetweenDatabasesAlgorithm.py | 2 +- .../EditingAlgs/createEditingGridAlgorithm.py | 4 +- ...genericSelectionToolParametersAlgorithm.py | 2 +- .../rightAngleToolParametersAlgorithm.py | 2 +- .../setFreeHandToolParametersAlgorithm.py | 2 +- .../donutHoleExtractorAlgorithm.py | 2 +- .../Algs/GeometricAlgs/extractByDE9IM.py | 2 +- .../GeometricAlgs/extractElevationPoints.py | 8 +- .../Algs/GeometricAlgs/line2Multiline.py | 2 +- .../reclassifyAdjecentPolygonsAlgorithm.py | 4 +- .../Algs/GeometricAlgs/selectByDE9IM.py | 2 +- .../smallHoleRemoverAlgorithm.py | 4 +- .../GeometricAlgs/splitPolygonsAlgorithm.py | 4 +- .../Algs/GeometricAlgs/splitPolygonsByGrid.py | 4 +- ...pplyStylesFromDatabaseToLayersAlgorithm.py | 2 +- .../assignActionsToLayersAlgorithm.py | 2 +- .../assignAliasesToLayersAlgorithm.py | 2 +- ...ssignBoundingBoxFilterToLayersAlgorithm.py | 2 +- ...assignConditionalStyleToLayersAlgorithm.py | 2 +- ...stomFormAndFormatRulesToLayersAlgorithm.py | 2 +- ...ssignDefaultFieldValueToLayersAlgorithm.py | 2 +- .../assignExpressionFieldToLayersAlgorithm.py | 2 +- .../assignFilterToLayersAlgorithm.py | 2 +- .../assignFormatRulesToLayersAlgorithm.py | 2 +- .../assignMeasureColumnToLayersAlgorithm.py | 2 +- .../assignValueMapToLayersAlgorithm.py | 2 +- .../buildJoinsOnLayersAlgorithm.py | 2 +- .../groupLayersAlgorithm.py | 2 +- .../loadLayersFromPostgisAlgorithm.py | 2 +- ...NonSpatialLayersFromPostgreSQLAlgorithm.py | 2 +- .../loadRasterLayerFromServerAlgorithm.py | 2 +- .../loadShapefileAlgorithm.py | 2 +- .../loadThemesAlgorithm.py | 2 +- .../lockAttributeEditingAlgorithm.py | 2 +- ...matchAndApplyQmlStylesToLayersAlgorithm.py | 2 +- .../LayerManagementAlgs/removeEmptyLayers.py | 2 +- .../sapLoadLayersAlgorithm.py | 2 +- .../setRemoveDuplicateNodePropertyOnLayers.py | 2 +- .../OtherAlgs/azimuthCalculationAlgorithm.py | 4 +- .../Algs/OtherAlgs/batchRunAlgorithm.py | 4 +- .../OtherAlgs/convertLayer2LayerAlgorithm.py | 4 +- .../Algs/OtherAlgs/createFrameAlgorithm.py | 74 +------------------ .../createFramesWithConstraintAlgorithm.py | 25 +------ .../OtherAlgs/createReviewGridAlgorithm.py | 4 +- .../Algs/OtherAlgs/exportToMemoryLayer.py | 4 +- .../Algs/OtherAlgs/fileInventoryAlgorithm.py | 4 +- .../filterLayerListByGeometryType.py | 4 +- ...fferencesBetweenDatabaseModelsAlgorithm.py | 6 +- .../Algs/OtherAlgs/loadTrackerAlgorithm.py | 4 +- .../multipleOutputUnitTestAlgorithm.py | 4 +- .../Algs/OtherAlgs/pecCalculatorAlgorithm.py | 4 +- .../Algs/OtherAlgs/raiseFlagsAlgorithm.py | 4 +- .../Algs/OtherAlgs/ruleStatisticsAlgorithm.py | 4 +- .../Algs/OtherAlgs/runFMESAPAlgorithm.py | 4 +- .../Algs/OtherAlgs/runRemoteFMEAlgorithm.py | 4 +- .../selectFeaturesOnCurrentCanvas.py | 4 +- .../singleOutputUnitTestAlgorithm.py | 4 +- ...ingCsvToFirstLayerWithElementsAlgorithm.py | 4 +- .../stringCsvToLayerListAlgorithm.py | 4 +- .../updateRunwayAltitudeAlgorithm.py | 4 +- .../OtherAlgs/validateTrackerAlgorithm.py | 4 +- ...dUnsharedVertexOnIntersectionsAlgorithm.py | 13 +--- ...addUnsharedVertexOnSharedEdgesAlgorithm.py | 4 +- .../adjustNetworkConnectivityAlgorithm.py | 4 +- ...sFromCenterPointsAndBoundariesAlgorithm.py | 14 +--- .../cleanGeometriesAlgorithm.py | 17 +---- .../deaggregateGeometriesAlgorithm.py | 4 +- .../detectChangesGroupAlgorithm.py | 16 ++-- .../detectNullGeometriesAlgorithm.py | 4 +- ...olvePolygonsWithSameAttributesAlgorithm.py | 6 +- .../enforceAttributeRulesAlgorithm.py | 4 +- .../enforceSpatialRulesAlgorithm.py | 5 +- .../extendLinesToGeographicBoundsAlgorithm.py | 5 +- .../fixDrainageFlowAlgorithm.py | 4 +- .../ValidationAlgs/fixNetworkAlgorithm.py | 4 +- .../fixSegmentErrorsBetweenLinesAlgorithm.py | 4 +- ...hicalSnapLayerOnLayerAndUpdateAlgorithm.py | 4 +- ...dentifyAndFixInvalidGeometriesAlgorithm.py | 4 +- .../identifyAnglesInInvalidRangeAlgorithm.py | 10 +-- .../identifyCloseFeaturesAlgorithm.py | 4 +- ...tifyCountourStreamIntersectionAlgorithm.py | 6 +- .../identifyCrossingLinesAlgorithm.py | 4 +- .../identifyDanglesAlgorithm.py | 4 +- ...entifyDrainageAndContourInconsistencies.py | 4 +- .../identifyDrainageAngleIssues.py | 18 +---- .../identifyDrainageFlowIssues.py | 18 +---- ...esWithOtherHydrographicClassesAlgorithm.py | 4 +- .../ValidationAlgs/identifyDrainageLoops.py | 4 +- .../identifyDuplicatedFeaturesAlgorithm.py | 12 +-- .../identifyDuplicatedGeometriesAlgorithm.py | 11 +-- ...fyDuplicatedLinesBetweenLayersAlgorithm.py | 11 +-- ...yDuplicatedPointsBetweenLayersAlgorithm.py | 11 +-- ...uplicatedPolygonsBetweenLayersAlgorithm.py | 11 +-- .../identifyDuplicatedVertexesAlgorithm.py | 4 +- .../ValidationAlgs/identifyGapsAlgorithm.py | 4 +- ...ntifyGapsAndOverlapsInCoverageAlgorithm.py | 4 +- ...ometriesWithLargeVertexDensityAlgorithm.py | 4 +- .../identifyIntertwinedLinesAlgorithm.py | 4 +- ...fyInvalidAttributeCombinationsAlgorithm.py | 25 +------ ...tifyInvalidSpatialRelationshipAlgorithm.py | 4 +- .../identifyInvalidUUIDsAlgorithm.py | 6 +- .../identifyMultiPartGeometriesAlgorithm.py | 4 +- ...ntifyNetworkConstructionIssuesAlgorithm.py | 4 +- .../identifyOutOfBoundsAnglesAlgorithm.py | 10 +-- ...ifyOutOfBoundsAnglesInCoverageAlgorithm.py | 10 +-- .../identifyOverlapsAlgorithm.py | 4 +- .../identifyPolygonSliverAlgorithm.py | 6 +- .../identifyPolygonUndershoots.py | 4 +- ...ntifySegmentErrorsBetweenLinesAlgorithm.py | 4 +- .../identifySmallFirstOrderDangle.py | 4 +- .../identifySmallHolesAlgorithm.py | 4 +- .../identifySmallLinesAlgorithm.py | 4 +- .../identifySmallObjectsOnLayersAlgorithm.py | 4 +- .../identifySmallPolygonsAlgorithm.py | 4 +- .../identifyTerrainModelErrorsAlgorithm.py | 18 ++--- ...ergedLinesWithSameAttributeSetAlgorithm.py | 7 +- ...yUnsharedVertexOnIntersectionsAlgorithm.py | 4 +- ...ifyUnsharedVertexOnSharedEdgesAlgorithm.py | 4 +- .../identifyVertexNearEdgesAlgorithm.py | 12 +-- .../identifyWrongBuildingAnglesAlgorithm.py | 4 +- ...identifyZAnglesBetweenFeaturesAlgorithm.py | 4 +- .../lineOnLineOverlayerAlgorithm.py | 19 +---- .../ValidationAlgs/mergeLinesAlgorithm.py | 4 +- .../overlayElementsWithAreasAlgorithm.py | 19 +---- .../removeDuplicatedFeaturesAlgorithm.py | 11 +-- .../removeDuplicatedGeometriesAlgorithm.py | 10 +-- .../removeEmptyAndUpdateAlgorithm.py | 20 +---- .../removeSmallLinesAlgorithm.py | 11 +-- .../removeSmallPolygonsAlgorithm.py | 11 +-- .../snapLayerOnLayerAndUpdateAlgorithm.py | 19 +---- .../snapToGridAndUpdateAlgorithm.py | 19 +---- .../spatialRulesCheckerAlgorithm.py | 30 +------- .../ValidationAlgs/spellCheckerAlgorithm.py | 6 +- .../Algs/ValidationAlgs/streamOrder.py | 4 +- .../topologicalCleanAlgorithm.py | 4 +- .../topologicalCleanLinesAlgorithm.py | 4 +- ...gicalDouglasAreaSimplificationAlgorithm.py | 4 +- ...gicalDouglasLineSimplificationAlgorithm.py | 4 +- ...icalLineConnectivityAdjustmentAlgorithm.py | 4 +- .../unbuildPolygonsAlgorithm.py | 12 +-- .../ValidationAlgs/unicodeFilterAlgorithm.py | 6 +- ...AdjacentGeographicBoundaryDataAlgorithm.py | 4 +- .../dsgtoolsProcessingAlgorithmProvider.py | 4 +- DsgTools/i18n/DsgTools_pt.ts | 26 +++---- 145 files changed, 293 insertions(+), 663 deletions(-) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/appendFeaturesToLayerAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/appendFeaturesToLayerAlgorithm.py index 45948e1ab..713ab73e0 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/appendFeaturesToLayerAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/appendFeaturesToLayerAlgorithm.py @@ -154,7 +154,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Data Management Algorithms" + return "DSGTools - Data Management Algorithms" def tr(self, string): return QCoreApplication.translate("AppendFeaturesToLayerAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/clipAndCopyFeaturesBetweenDatabasesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/clipAndCopyFeaturesBetweenDatabasesAlgorithm.py index a0b6361f2..83d935920 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/clipAndCopyFeaturesBetweenDatabasesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/clipAndCopyFeaturesBetweenDatabasesAlgorithm.py @@ -340,7 +340,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Data Management Algorithms" + return "DSGTools - Data Management Algorithms" def tr(self, string): return QCoreApplication.translate("AppendFeaturesToLayerAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/EditingAlgs/createEditingGridAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/EditingAlgs/createEditingGridAlgorithm.py index 04eb51241..64230f791 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/EditingAlgs/createEditingGridAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/EditingAlgs/createEditingGridAlgorithm.py @@ -273,7 +273,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Editing Algorithms") + return self.tr("Cartographic Finishing Algorithms") def groupId(self): """ @@ -283,7 +283,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Editing Algorithms" + return "DSGTools - Cartographic Finishing Algorithms" def tr(self, string): return QCoreApplication.translate("CreateEditingGridAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/EnvironmentSetterAlgs/genericSelectionToolParametersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/EnvironmentSetterAlgs/genericSelectionToolParametersAlgorithm.py index 4015f0a68..59c41f59f 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/EnvironmentSetterAlgs/genericSelectionToolParametersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/EnvironmentSetterAlgs/genericSelectionToolParametersAlgorithm.py @@ -79,7 +79,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Environment Setters" + return "DSGTools - Environment Setters" def tr(self, string): return QCoreApplication.translate("GenericSelectionToolParametersAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/EnvironmentSetterAlgs/rightAngleToolParametersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/EnvironmentSetterAlgs/rightAngleToolParametersAlgorithm.py index acaaf33ff..009a05dcd 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/EnvironmentSetterAlgs/rightAngleToolParametersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/EnvironmentSetterAlgs/rightAngleToolParametersAlgorithm.py @@ -91,7 +91,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Environment Setters" + return "DSGTools - Environment Setters" def tr(self, string): return QCoreApplication.translate("RightAngleToolParametersAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/EnvironmentSetterAlgs/setFreeHandToolParametersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/EnvironmentSetterAlgs/setFreeHandToolParametersAlgorithm.py index 97f995755..060ca08ed 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/EnvironmentSetterAlgs/setFreeHandToolParametersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/EnvironmentSetterAlgs/setFreeHandToolParametersAlgorithm.py @@ -139,7 +139,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Environment Setters" + return "DSGTools - Environment Setters" def tr(self, string): return QCoreApplication.translate("SetFreeHandToolParametersAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/donutHoleExtractorAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/donutHoleExtractorAlgorithm.py index 2ce6f967c..fe0de53f8 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/donutHoleExtractorAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/donutHoleExtractorAlgorithm.py @@ -175,7 +175,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Geometric Algorithms" + return "DSGTools - Geometric Algorithms" def tr(self, string): return QCoreApplication.translate("DonutHoleExtractorAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractByDE9IM.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractByDE9IM.py index 9875090a4..e9721ce53 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractByDE9IM.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractByDE9IM.py @@ -220,7 +220,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Geometric Algorithms" + return "DSGTools - Geometric Algorithms" def tr(self, string): return QCoreApplication.translate("ExtractByDE9IMAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py index 44ce212c9..7bcd44e86 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py @@ -217,7 +217,7 @@ def initAlgorithm(self, config=None): ) self.addParameter( - QgsProcessingParameterFeatureSink(self.OUTPUT, "Output elevation points") + QgsProcessingParameterFeatureSink(self.OUTPUT, "Output spot elevation") ) def processAlgorithm(self, parameters, context, feedback): @@ -2084,13 +2084,13 @@ def name(self): return "extractelevationpoints" def displayName(self): - return self.tr("Extract Elevation Points") + return self.tr("Extract Spot Elevation") def group(self): - return self.tr("Geometric Algorithms") + return self.tr("QA Tools: Terrain Processes") def groupId(self): - return "DSGTools: Geometric Algorithms" + return "DSGTools - QA Tools: Terrain Processes" def shortHelpString(self): return self.tr("This algorithm extracts elevation points from DEM.") diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/line2Multiline.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/line2Multiline.py index 91a2326d0..7d9cf255b 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/line2Multiline.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/line2Multiline.py @@ -218,7 +218,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Geometric Algorithms" + return "DSGTools - Geometric Algorithms" def shortHelpString(self): return self.tr("O algoritmo converte linhas que se tocam para multilinha") diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/reclassifyAdjecentPolygonsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/reclassifyAdjecentPolygonsAlgorithm.py index 48e4892cb..8d6a3f1d0 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/reclassifyAdjecentPolygonsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/reclassifyAdjecentPolygonsAlgorithm.py @@ -481,7 +481,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Geometric Algorithms") + return self.tr("Generalization Algorithms") def groupId(self): """ @@ -491,7 +491,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Geometric Algorithms" + return "DSGTools - Generalization Algorithms" def tr(self, string): return QCoreApplication.translate("ReclassifyAdjacentPolygonsAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/selectByDE9IM.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/selectByDE9IM.py index 055100b1b..a4597dcad 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/selectByDE9IM.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/selectByDE9IM.py @@ -219,7 +219,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Geometric Algorithms" + return "DSGTools - Geometric Algorithms" def tr(self, string): return QCoreApplication.translate("SelectByDE9IMAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/smallHoleRemoverAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/smallHoleRemoverAlgorithm.py index e4fdec8f3..4623f6b12 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/smallHoleRemoverAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/smallHoleRemoverAlgorithm.py @@ -272,7 +272,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Geometric Algorithms") + return self.tr("QA Tools: Small Object Handling") def groupId(self): """ @@ -282,7 +282,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Geometric Algorithms" + return "DSGTools - QA Tools: Small Object Handling" def tr(self, string): return QCoreApplication.translate("SmallHoleRemoverAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsAlgorithm.py index e9d36e76f..08767699a 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsAlgorithm.py @@ -252,7 +252,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Geometric Algorithms") + return self.tr("Generalization Algorithms") def groupId(self): """ @@ -262,7 +262,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Geometric Algorithms" + return "DSGTools - Generalization Algorithms" def tr(self, string): return QCoreApplication.translate("SplitPolygons", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py index 948862c34..07737807c 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py @@ -72,7 +72,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Geometric Algorithms") + return self.tr("Generalization Algorithms") def groupId(self): """ @@ -82,7 +82,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Geometric Algorithms" + return "DSGTools - Generalization Algorithms" def shortHelpString(self): return self.tr( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/applyStylesFromDatabaseToLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/applyStylesFromDatabaseToLayersAlgorithm.py index 3dedce5a6..03cb5e7c7 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/applyStylesFromDatabaseToLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/applyStylesFromDatabaseToLayersAlgorithm.py @@ -167,7 +167,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignActionsToLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignActionsToLayersAlgorithm.py index f8220d2ca..59e52af63 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignActionsToLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignActionsToLayersAlgorithm.py @@ -194,7 +194,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate("AssignActionsToLayersAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignAliasesToLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignAliasesToLayersAlgorithm.py index 053ace56b..096941fdd 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignAliasesToLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignAliasesToLayersAlgorithm.py @@ -202,7 +202,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate("AssignAliasesToLayersAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignBoundingBoxFilterToLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignBoundingBoxFilterToLayersAlgorithm.py index 0fd5970bb..443baa120 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignBoundingBoxFilterToLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignBoundingBoxFilterToLayersAlgorithm.py @@ -191,7 +191,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignConditionalStyleToLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignConditionalStyleToLayersAlgorithm.py index 46b5d808d..0d47feef5 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignConditionalStyleToLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignConditionalStyleToLayersAlgorithm.py @@ -199,7 +199,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignCustomFormAndFormatRulesToLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignCustomFormAndFormatRulesToLayersAlgorithm.py index fe8a1db1e..8a2e73ab3 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignCustomFormAndFormatRulesToLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignCustomFormAndFormatRulesToLayersAlgorithm.py @@ -266,7 +266,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignDefaultFieldValueToLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignDefaultFieldValueToLayersAlgorithm.py index 34896b456..635a01064 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignDefaultFieldValueToLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignDefaultFieldValueToLayersAlgorithm.py @@ -187,7 +187,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignExpressionFieldToLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignExpressionFieldToLayersAlgorithm.py index 56a9c4734..043e0e424 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignExpressionFieldToLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignExpressionFieldToLayersAlgorithm.py @@ -182,7 +182,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignFilterToLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignFilterToLayersAlgorithm.py index 78ee57436..062bf7bcc 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignFilterToLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignFilterToLayersAlgorithm.py @@ -162,7 +162,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate("AssignFilterToLayersAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignFormatRulesToLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignFormatRulesToLayersAlgorithm.py index 793cec4bf..f20fafd8b 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignFormatRulesToLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignFormatRulesToLayersAlgorithm.py @@ -305,7 +305,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate("AssignFormatRulesToLayersAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignMeasureColumnToLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignMeasureColumnToLayersAlgorithm.py index 3cbfa55e1..28d231280 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignMeasureColumnToLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignMeasureColumnToLayersAlgorithm.py @@ -136,7 +136,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignValueMapToLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignValueMapToLayersAlgorithm.py index e15158318..d10b747cd 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignValueMapToLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/assignValueMapToLayersAlgorithm.py @@ -156,7 +156,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate("AssignValueMapToLayersAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/buildJoinsOnLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/buildJoinsOnLayersAlgorithm.py index bb2483ca9..45b8c7c34 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/buildJoinsOnLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/buildJoinsOnLayersAlgorithm.py @@ -169,7 +169,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): """ diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/groupLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/groupLayersAlgorithm.py index 45015903c..01763663a 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/groupLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/groupLayersAlgorithm.py @@ -198,7 +198,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): """ diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadLayersFromPostgisAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadLayersFromPostgisAlgorithm.py index db2539b19..3b10d2779 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadLayersFromPostgisAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadLayersFromPostgisAlgorithm.py @@ -183,7 +183,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate("LoadLayersFromPostgisAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadNonSpatialLayersFromPostgreSQLAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadNonSpatialLayersFromPostgreSQLAlgorithm.py index ba6c7c7e3..c06a6d404 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadNonSpatialLayersFromPostgreSQLAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadNonSpatialLayersFromPostgreSQLAlgorithm.py @@ -189,7 +189,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadRasterLayerFromServerAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadRasterLayerFromServerAlgorithm.py index 7f712fd19..b31adf126 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadRasterLayerFromServerAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadRasterLayerFromServerAlgorithm.py @@ -211,7 +211,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate("loadRasterLayerFromServerAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadShapefileAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadShapefileAlgorithm.py index 601ba04ca..7dabfb131 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadShapefileAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadShapefileAlgorithm.py @@ -127,7 +127,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): """ diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadThemesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadThemesAlgorithm.py index c2a49e1be..828fe5936 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadThemesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadThemesAlgorithm.py @@ -137,7 +137,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): """ diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/lockAttributeEditingAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/lockAttributeEditingAlgorithm.py index 34fe556b7..b9bffd2aa 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/lockAttributeEditingAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/lockAttributeEditingAlgorithm.py @@ -161,7 +161,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate("LockAttributeEditingAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/matchAndApplyQmlStylesToLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/matchAndApplyQmlStylesToLayersAlgorithm.py index d03de753c..6a2307cb3 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/matchAndApplyQmlStylesToLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/matchAndApplyQmlStylesToLayersAlgorithm.py @@ -204,7 +204,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/removeEmptyLayers.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/removeEmptyLayers.py index 40e85015b..0b9cbdb15 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/removeEmptyLayers.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/removeEmptyLayers.py @@ -85,7 +85,7 @@ def group(self): return self.tr("Layer Management Algorithms") def groupId(self): - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def shortHelpString(self): return self.tr( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/sapLoadLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/sapLoadLayersAlgorithm.py index ce88331fe..cebfd3262 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/sapLoadLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/sapLoadLayersAlgorithm.py @@ -163,7 +163,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate("SapLoadLayersAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/setRemoveDuplicateNodePropertyOnLayers.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/setRemoveDuplicateNodePropertyOnLayers.py index 99c718c69..723b0436c 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/setRemoveDuplicateNodePropertyOnLayers.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/setRemoveDuplicateNodePropertyOnLayers.py @@ -98,7 +98,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Layer Management Algorithms" + return "DSGTools - Layer Management Algorithms" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/azimuthCalculationAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/azimuthCalculationAlgorithm.py index 57390ee11..f8e33dd6f 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/azimuthCalculationAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/azimuthCalculationAlgorithm.py @@ -132,7 +132,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Utils") def groupId(self): """ @@ -142,7 +142,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Utils" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/batchRunAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/batchRunAlgorithm.py index b6e817ace..f31b0e051 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/batchRunAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/batchRunAlgorithm.py @@ -233,7 +233,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Model Helpers") def groupId(self): """ @@ -243,7 +243,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Model Helpers" def tr(self, string): return QCoreApplication.translate("BatchRunAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/convertLayer2LayerAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/convertLayer2LayerAlgorithm.py index b9c4ababd..bdb04f761 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/convertLayer2LayerAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/convertLayer2LayerAlgorithm.py @@ -186,7 +186,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Data Management Algorithms") def groupId(self): """ @@ -194,7 +194,7 @@ def groupId(self): string should be fixed for the algorithm, and must not be localised. The group id should be unique within each provider. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Data Management Algorithms" def tr(self, string): return QCoreApplication.translate("ConvertLayer2LayerAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createFrameAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createFrameAlgorithm.py index 91a2d6af8..b231fed21 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createFrameAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createFrameAlgorithm.py @@ -22,37 +22,17 @@ """ from DsgTools.core.GeometricTools.featureHandler import FeatureHandler from DsgTools.core.Utils.FrameTools.map_index import UtmGrid -from ...algRunner import AlgRunner -import processing, os, requests -from time import sleep from qgis.PyQt.Qt import QVariant from PyQt5.QtCore import QCoreApplication from qgis.core import ( - QgsProcessing, QgsFeatureSink, QgsProcessingAlgorithm, - QgsProcessingParameterFeatureSource, QgsProcessingParameterFeatureSink, - QgsFeature, - QgsDataSourceUri, - QgsProcessingOutputVectorLayer, - QgsProcessingParameterVectorLayer, QgsWkbTypes, - QgsProcessingParameterBoolean, QgsProcessingParameterEnum, QgsProcessingParameterNumber, - QgsProcessingParameterMultipleLayers, - QgsProcessingUtils, - QgsSpatialIndex, - QgsGeometry, - QgsProcessingParameterField, - QgsProcessingMultiStepFeedback, - QgsProcessingParameterFile, - QgsProcessingParameterExpression, QgsProcessingException, QgsProcessingParameterString, - QgsProcessingParameterDefinition, - QgsProcessingParameterType, QgsProcessingParameterCrs, QgsCoordinateTransform, QgsProject, @@ -225,7 +205,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Grid Algorithms") def groupId(self): """ @@ -235,7 +215,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Grid Algorithms" def tr(self, string): return QCoreApplication.translate("CreateFrameAlgorithm", string) @@ -389,53 +369,3 @@ def validateIndex(self, index): if word not in self.chars[11]: return False return True - - -# class ParameterFMEManagerType(QgsProcessingParameterType): - -# def __init__(self): -# super().__init__() - -# def create(self, name): -# return ParameterFMEManager(name) - -# def metadata(self): -# return {'widget_wrapper': 'DsgTools.gui.ProcessingUI.fmeManagerWrapper.FMEManagerWrapper'} - -# def name(self): -# return QCoreApplication.translate('Processing', 'FME Manager Parameters') - -# def id(self): -# return 'fme_manager' - -# def description(self): -# return QCoreApplication.translate('Processing', 'FME Manager parameters. Used on Run Remote FME Workspace') - -# class ParameterFMEManager(QgsProcessingParameterDefinition): - -# def __init__(self, name, description=''): -# super().__init__(name, description) - -# def clone(self): -# copy = ParameterFMEManager(self.name(), self.description()) -# return copy - -# def type(self): -# return self.typeName() - -# @staticmethod -# def typeName(): -# return 'fme_manager' - -# def checkValueIsAcceptable(self, value, context=None): -# return True - -# def valueAsPythonString(self, value, context): -# return str(value) - -# def asScriptCode(self): -# raise NotImplementedError() - -# @classmethod -# def fromScriptCode(cls, name, description, isOptional, definition): -# raise NotImplementedError() diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createFramesWithConstraintAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createFramesWithConstraintAlgorithm.py index f077eb73b..31bb6ed00 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createFramesWithConstraintAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createFramesWithConstraintAlgorithm.py @@ -21,39 +21,18 @@ ***************************************************************************/ """ from DsgTools.core.GeometricTools.featureHandler import FeatureHandler -from DsgTools.core.Utils.FrameTools.map_index import UtmGrid -from ...algRunner import AlgRunner -import processing, os, requests -from time import sleep from qgis.PyQt.Qt import QVariant from PyQt5.QtCore import QCoreApplication from qgis.core import ( QgsProcessing, QgsFeatureSink, QgsProcessingAlgorithm, - QgsProcessingParameterFeatureSource, QgsProcessingParameterFeatureSink, - QgsFeature, - QgsDataSourceUri, - QgsProcessingOutputVectorLayer, QgsProcessingParameterVectorLayer, QgsWkbTypes, - QgsProcessingParameterBoolean, QgsProcessingParameterEnum, QgsProcessingParameterNumber, - QgsProcessingParameterMultipleLayers, - QgsProcessingUtils, - QgsSpatialIndex, - QgsGeometry, - QgsProcessingParameterField, - QgsProcessingMultiStepFeedback, - QgsProcessingParameterFile, - QgsProcessingParameterExpression, QgsProcessingException, - QgsProcessingParameterString, - QgsProcessingParameterDefinition, - QgsProcessingParameterType, - QgsProcessingParameterCrs, QgsCoordinateTransform, QgsProject, QgsCoordinateReferenceSystem, @@ -195,7 +174,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Grid Algorithms") def groupId(self): """ @@ -205,7 +184,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Grid Algorithms" def tr(self, string): return QCoreApplication.translate("CreateFramesWithConstraintAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createReviewGridAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createReviewGridAlgorithm.py index 98e8e0ff0..e401067e1 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createReviewGridAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createReviewGridAlgorithm.py @@ -215,7 +215,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Grid Algorithms") def groupId(self): """ @@ -225,7 +225,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Grid Algorithms" def tr(self, string): return QCoreApplication.translate("CreateReviewGridAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/exportToMemoryLayer.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/exportToMemoryLayer.py index 7b602ff07..2f6f2ddd9 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/exportToMemoryLayer.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/exportToMemoryLayer.py @@ -128,7 +128,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Model Helpers") def groupId(self): """ @@ -138,7 +138,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Model Helpers" def tr(self, string): return QCoreApplication.translate("ExportToMemoryLayer", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/fileInventoryAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/fileInventoryAlgorithm.py index 567fbfffe..a5db572e0 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/fileInventoryAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/fileInventoryAlgorithm.py @@ -181,7 +181,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Data Management Algorithms") def groupId(self): """ @@ -191,7 +191,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Data Management Algorithms" def tr(self, string): return QCoreApplication.translate("FileInventoryAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/filterLayerListByGeometryType.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/filterLayerListByGeometryType.py index 8a149f23c..17ea184ba 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/filterLayerListByGeometryType.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/filterLayerListByGeometryType.py @@ -97,7 +97,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Model Helpers") def groupId(self): """ @@ -107,7 +107,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Model Helpers" def tr(self, string): return QCoreApplication.translate("FilterLayerListByGeometryType", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/identifyDifferencesBetweenDatabaseModelsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/identifyDifferencesBetweenDatabaseModelsAlgorithm.py index 4d2629f1e..325feff90 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/identifyDifferencesBetweenDatabaseModelsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/identifyDifferencesBetweenDatabaseModelsAlgorithm.py @@ -850,14 +850,14 @@ def displayName(self): Returns the translated algorithm name, which should be used for any user-visible display of the algorithm name. """ - return self.tr("Identify Differences Between banco de dados Models") + return self.tr("Identify Differences Between Database Models") def group(self): """ Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Utils") def groupId(self): """ @@ -867,7 +867,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Utils" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/loadTrackerAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/loadTrackerAlgorithm.py index 3b3c55cc8..1afcc1b0f 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/loadTrackerAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/loadTrackerAlgorithm.py @@ -390,7 +390,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Tracker Algorithms") def groupId(self): """ @@ -400,7 +400,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Tracker Algorithms" def tr(self, string): return QCoreApplication.translate("LoadTrackerAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/multipleOutputUnitTestAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/multipleOutputUnitTestAlgorithm.py index c7a469515..e092fea14 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/multipleOutputUnitTestAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/multipleOutputUnitTestAlgorithm.py @@ -95,7 +95,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Utils") def groupId(self): """ @@ -105,7 +105,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Utils" def tr(self, string): return QCoreApplication.translate("MultipleOutputUnitTestAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/pecCalculatorAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/pecCalculatorAlgorithm.py index 14faaf31b..a418a8652 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/pecCalculatorAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/pecCalculatorAlgorithm.py @@ -184,7 +184,7 @@ def displayName(self): Returns the translated algorithm name, which should be used for any user-visible display of the algorithm name. """ - return self.tr("Calculate RMS and Percentile 90 of Layer") + return self.tr("Compute RMS and Percentile 90 of Layer") def group(self): """ @@ -199,7 +199,7 @@ def groupId(self): string should be fixed for the algorithm, and must not be localised. The group id should be unique within each provider. """ - return "DSGTools: Data Quality" + return "DSGTools - Data Quality" def tr(self, string): return QCoreApplication.translate("PecCalculatorAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/raiseFlagsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/raiseFlagsAlgorithm.py index 4ec29352a..e6bd52918 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/raiseFlagsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/raiseFlagsAlgorithm.py @@ -205,7 +205,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Model Helpers") def groupId(self): """ @@ -215,7 +215,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Model Helpers" def tr(self, string): return QCoreApplication.translate("RaiseFlagsAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/ruleStatisticsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/ruleStatisticsAlgorithm.py index 9f031cc5b..3c0763ee4 100755 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/ruleStatisticsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/ruleStatisticsAlgorithm.py @@ -230,7 +230,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("QA Tools: Attribute Handling") def groupId(self): """ @@ -240,7 +240,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - QA Tools: Attribute Handling" def tr(self, string): return QCoreApplication.translate("RuleStatisticsAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/runFMESAPAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/runFMESAPAlgorithm.py index a417df9ff..adf058d44 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/runFMESAPAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/runFMESAPAlgorithm.py @@ -174,7 +174,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Utils") def groupId(self): """ @@ -184,7 +184,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Utils" def tr(self, string): return QCoreApplication.translate("RunFMESAPAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/runRemoteFMEAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/runRemoteFMEAlgorithm.py index 918ca4cae..eb59be57e 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/runRemoteFMEAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/runRemoteFMEAlgorithm.py @@ -259,7 +259,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Utils") def groupId(self): """ @@ -269,7 +269,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Utils" def tr(self, string): return QCoreApplication.translate("RunRemoteFMEAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/selectFeaturesOnCurrentCanvas.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/selectFeaturesOnCurrentCanvas.py index 77f7303c2..32f4afd7b 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/selectFeaturesOnCurrentCanvas.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/selectFeaturesOnCurrentCanvas.py @@ -86,7 +86,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Utils") def groupId(self): """ @@ -96,7 +96,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Utils" def tr(self, string): return QCoreApplication.translate("SelectFeaturesOnCurrentCanvas", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/singleOutputUnitTestAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/singleOutputUnitTestAlgorithm.py index dcc7dd3dd..e769bce87 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/singleOutputUnitTestAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/singleOutputUnitTestAlgorithm.py @@ -124,7 +124,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Utils") def groupId(self): """ @@ -134,7 +134,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Utils" def tr(self, string): return QCoreApplication.translate("SingleOutputUnitTestAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/stringCsvToFirstLayerWithElementsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/stringCsvToFirstLayerWithElementsAlgorithm.py index c34ee2690..979b3b844 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/stringCsvToFirstLayerWithElementsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/stringCsvToFirstLayerWithElementsAlgorithm.py @@ -88,7 +88,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Model Helpers") def groupId(self): """ @@ -98,7 +98,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Model Helpers" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/stringCsvToLayerListAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/stringCsvToLayerListAlgorithm.py index e32434597..a1b28cbdd 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/stringCsvToLayerListAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/stringCsvToLayerListAlgorithm.py @@ -109,7 +109,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Model Helpers") def groupId(self): """ @@ -119,7 +119,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Model Helpers" def tr(self, string): return QCoreApplication.translate("StringCsvToLayerListAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/updateRunwayAltitudeAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/updateRunwayAltitudeAlgorithm.py index f6d44ac40..ce27e02de 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/updateRunwayAltitudeAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/updateRunwayAltitudeAlgorithm.py @@ -143,7 +143,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Utils") def groupId(self): """ @@ -153,7 +153,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Utils" def tr(self, string): return QCoreApplication.translate("updateRunwayAltitudeAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/validateTrackerAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/validateTrackerAlgorithm.py index a9222b8c8..e9329dba7 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/validateTrackerAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/validateTrackerAlgorithm.py @@ -259,7 +259,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Other Algorithms") + return self.tr("Tracker Algorithms") def groupId(self): """ @@ -269,7 +269,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Other Algorithms" + return "DSGTools - Tracker Algorithms" def tr(self, string): return QCoreApplication.translate("validateTrackerAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/addUnsharedVertexOnIntersectionsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/addUnsharedVertexOnIntersectionsAlgorithm.py index eda36ff65..945a203c2 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/addUnsharedVertexOnIntersectionsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/addUnsharedVertexOnIntersectionsAlgorithm.py @@ -25,22 +25,13 @@ from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, - QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterDistance, - QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, - QgsProcessingParameterField, QgsProcessingParameterMultipleLayers, QgsProcessingParameterVectorLayer, - QgsWkbTypes, ) from ...algRunner import AlgRunner @@ -222,7 +213,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Correction Processes)") + return self.tr("QA Tools: Vertex Handling") def groupId(self): """ @@ -232,7 +223,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Correction Processes)" + return "DSGTools - QA Tools: Vertex Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/addUnsharedVertexOnSharedEdgesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/addUnsharedVertexOnSharedEdgesAlgorithm.py index 849eb4bd8..98baf67cf 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/addUnsharedVertexOnSharedEdgesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/addUnsharedVertexOnSharedEdgesAlgorithm.py @@ -217,7 +217,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Correction Processes)") + return self.tr("QA Tools: Vertex Handling") def groupId(self): """ @@ -227,7 +227,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Correction Processes)" + return "DSGTools - QA Tools: Vertex Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/adjustNetworkConnectivityAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/adjustNetworkConnectivityAlgorithm.py index 38f13416f..004324f40 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/adjustNetworkConnectivityAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/adjustNetworkConnectivityAlgorithm.py @@ -153,7 +153,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Network Processes)") + return self.tr("QA Tools: Network Processes") def groupId(self): """ @@ -163,7 +163,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Network Processes)" + return "DSGTools - QA Tools: Network Processes" def tr(self, string): return QCoreApplication.translate("AdjustNetworkConnectivityAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/buildPolygonsFromCenterPointsAndBoundariesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/buildPolygonsFromCenterPointsAndBoundariesAlgorithm.py index 19045fa30..75d57d300 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/buildPolygonsFromCenterPointsAndBoundariesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/buildPolygonsFromCenterPointsAndBoundariesAlgorithm.py @@ -22,33 +22,23 @@ import concurrent.futures import os -from uuid import uuid4 -from DsgTools.core.GeometricTools.spatialRelationsHandler import SpatialRelationsHandler import processing -from processing.tools import dataobjects from PyQt5.QtCore import QCoreApplication from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, QgsFeatureSink, QgsFields, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, - QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, - QgsProcessingParameterDistance, QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, QgsProcessingParameterField, QgsProcessingParameterMultipleLayers, QgsProcessingParameterVectorLayer, QgsWkbTypes, QgsProcessingUtils, - QgsVectorLayer, QgsProcessingFeatureSourceDefinition, QgsProcessingContext, ) @@ -1011,7 +1001,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("QA Tools: Polygon Handling") def groupId(self): """ @@ -1021,7 +1011,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - QA Tools: Polygon Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/cleanGeometriesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/cleanGeometriesAlgorithm.py index 29a36f199..cee897cdb 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/cleanGeometriesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/cleanGeometriesAlgorithm.py @@ -22,30 +22,17 @@ """ from PyQt5.QtCore import QCoreApplication -import processing from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, - QgsGeometry, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterDistance, - QgsProcessingParameterEnum, QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, - QgsProcessingParameterMultipleLayers, QgsProcessingParameterNumber, QgsProcessingParameterVectorLayer, - QgsProcessingUtils, - QgsProject, - QgsSpatialIndex, - QgsWkbTypes, ) from ...algRunner import AlgRunner @@ -212,7 +199,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("QA Tools: Snap Processes") def groupId(self): """ @@ -222,7 +209,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - QA Tools: Snap Processes" def tr(self, string): return QCoreApplication.translate("CleanGeometriesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/deaggregateGeometriesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/deaggregateGeometriesAlgorithm.py index 3e991c0b9..f95775b32 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/deaggregateGeometriesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/deaggregateGeometriesAlgorithm.py @@ -142,7 +142,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("Geometric Algorithms") def groupId(self): """ @@ -152,7 +152,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - Geometric Algorithms" def tr(self, string): return QCoreApplication.translate("DeaggregatorAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectChangesGroupAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectChangesGroupAlgorithm.py index 779458331..2e974cf4a 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectChangesGroupAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectChangesGroupAlgorithm.py @@ -41,7 +41,7 @@ from .validationAlgorithm import ValidationAlgorithm -class DetectChangesGroupAlgorithm(ValidationAlgorithm): +class DetectChangesBetweenGroups(ValidationAlgorithm): ORIGINAL = "ORIGINAL" REVIEWED = "REVIEWED" BLACK_ATTRIBUTES = "BLACK_ATTRIBUTES" @@ -77,7 +77,7 @@ def initAlgorithm(self, config): ) self.addParameter( - QgsProcessingParameterString(self.GROUP, self.tr("Attribute to group by")) + QgsProcessingParameterString(self.GROUP, self.tr("Primary key attribute on input layers to group by (id, for example)")) ) self.addParameter( @@ -365,21 +365,21 @@ def name(self): lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "detectchangesingroup" + return "detectchangesbetweengroups" def displayName(self): """ Returns the translated algorithm name, which should be used for any user-visible display of the algorithm name. """ - return self.tr("Detect Changes In Group") + return self.tr("Detect Changes Between Groups") def group(self): """ Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Identification") def groupId(self): """ @@ -389,13 +389,13 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Identification" def tr(self, string): - return QCoreApplication.translate("DetectChangesInGroup", string) + return QCoreApplication.translate("DetectChangesBetweenGroups", string) def createInstance(self): - return DetectChangesGroupAlgorithm() + return DetectChangesBetweenGroups() class GroupsWidgetWrapper(WidgetWrapper): diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectNullGeometriesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectNullGeometriesAlgorithm.py index bd25347c7..6ead5f282 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectNullGeometriesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectNullGeometriesAlgorithm.py @@ -146,7 +146,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Basic Geometry Construction Issues Handling") def groupId(self): """ @@ -156,7 +156,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Basic Geometry Construction Issues Handling" def tr(self, string): return QCoreApplication.translate("DetectNullGeometriesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/dissolvePolygonsWithSameAttributesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/dissolvePolygonsWithSameAttributesAlgorithm.py index d675d6a12..08d84cae7 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/dissolvePolygonsWithSameAttributesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/dissolvePolygonsWithSameAttributesAlgorithm.py @@ -173,14 +173,14 @@ def displayName(self): Returns the translated algorithm name, which should be used for any user-visible display of the algorithm name. """ - return self.tr("Dissolve polygons with same attribute set") + return self.tr("Dissolve Polygons With Same Attribute Set") def group(self): """ Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("QA Tools: Polygon Handling") def groupId(self): """ @@ -190,7 +190,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - QA Tools: Polygon Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/enforceAttributeRulesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/enforceAttributeRulesAlgorithm.py index 1d967be89..be68fd86a 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/enforceAttributeRulesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/enforceAttributeRulesAlgorithm.py @@ -314,7 +314,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Attribute Handling") def groupId(self): """ @@ -324,7 +324,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Attribute Handling" def tr(self, string): """ diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/enforceSpatialRulesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/enforceSpatialRulesAlgorithm.py index 2d457e268..cddf56e18 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/enforceSpatialRulesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/enforceSpatialRulesAlgorithm.py @@ -27,7 +27,6 @@ QgsFeature, QgsWkbTypes, QgsFeatureSink, - QgsProcessingContext, QgsProcessingException, QgsProcessingParameterType, QgsProcessingParameterDefinition, @@ -106,7 +105,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Object Proximity and Relationships") def groupId(self): """ @@ -116,7 +115,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Object Proximity and Relationships" def tr(self, string): return QCoreApplication.translate("EnforceSpatialRulesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/extendLinesToGeographicBoundsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/extendLinesToGeographicBoundsAlgorithm.py index 5a29b63d7..e42cb07cc 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/extendLinesToGeographicBoundsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/extendLinesToGeographicBoundsAlgorithm.py @@ -30,7 +30,6 @@ QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterDistance, - QgsProcessingParameterEnum, QgsProcessingParameterVectorLayer, QgsProcessingParameterFeatureSource, ) @@ -283,7 +282,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("QA Tools: Line Handling") def groupId(self): """ @@ -293,7 +292,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - QA Tools: Line Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixDrainageFlowAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixDrainageFlowAlgorithm.py index 7441980f2..0bdb8a291 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixDrainageFlowAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixDrainageFlowAlgorithm.py @@ -510,7 +510,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Network Processes)") + return self.tr("QA Tools: Drainage Network Processes") def groupId(self): """ @@ -520,7 +520,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Network Processes)" + return "DSGTools - QA Tools: Drainage Network Processes" def tr(self, string): return QCoreApplication.translate("FixDrainageFlowAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixNetworkAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixNetworkAlgorithm.py index ac7143eee..a2e440774 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixNetworkAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixNetworkAlgorithm.py @@ -270,7 +270,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Network Processes)") + return self.tr("QA Tools: Network Processes") def groupId(self): """ @@ -280,7 +280,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Network Processes)" + return "DSGTools - QA Tools: Network Processes" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixSegmentErrorsBetweenLinesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixSegmentErrorsBetweenLinesAlgorithm.py index ecb582791..9c953e11f 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixSegmentErrorsBetweenLinesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixSegmentErrorsBetweenLinesAlgorithm.py @@ -146,7 +146,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("QA Tools: Line Handling") def groupId(self): """ @@ -156,7 +156,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - QA Tools: Line Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/hierarchicalSnapLayerOnLayerAndUpdateAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/hierarchicalSnapLayerOnLayerAndUpdateAlgorithm.py index d3ff835dd..bc1044871 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/hierarchicalSnapLayerOnLayerAndUpdateAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/hierarchicalSnapLayerOnLayerAndUpdateAlgorithm.py @@ -308,7 +308,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("QA Tools: Snap Processes") def groupId(self): """ @@ -318,7 +318,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - QA Tools: Snap Processes" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyAndFixInvalidGeometriesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyAndFixInvalidGeometriesAlgorithm.py index 7cac5e668..9d6c8e479 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyAndFixInvalidGeometriesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyAndFixInvalidGeometriesAlgorithm.py @@ -161,7 +161,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Basic Geometry Construction Issues Handling") def groupId(self): """ @@ -171,7 +171,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Basic Geometry Construction Issues Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyAnglesInInvalidRangeAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyAnglesInInvalidRangeAlgorithm.py index 67ffafc5a..435bd3a54 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyAnglesInInvalidRangeAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyAnglesInInvalidRangeAlgorithm.py @@ -24,15 +24,9 @@ from DsgTools.core.GeometricTools.geometryHandler import GeometryHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, - QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, QgsProcessingParameterNumber, QgsProcessingParameterVectorLayer, QgsWkbTypes, @@ -154,7 +148,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Basic Geometry Construction Issues Handling") def groupId(self): """ @@ -164,7 +158,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Basic Geometry Construction Issues Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCloseFeaturesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCloseFeaturesAlgorithm.py index 55eaecb4f..1a839b401 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCloseFeaturesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCloseFeaturesAlgorithm.py @@ -258,7 +258,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Object Proximity and Relationships") def groupId(self): """ @@ -268,7 +268,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Object Proximity and Relationships" def tr(self, string): """ diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCountourStreamIntersectionAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCountourStreamIntersectionAlgorithm.py index 8edfc05b1..660ab4c8c 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCountourStreamIntersectionAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCountourStreamIntersectionAlgorithm.py @@ -265,7 +265,7 @@ def displayName(self): user-visible display of the algorithm name. """ return self.tr( - "Identifies intersections between contour lines and drainage lines" + "Identify Intersections Between Contour Lines and Drainage Lines" ) def group(self): @@ -273,7 +273,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Terrain Processes") def groupId(self): """ @@ -283,7 +283,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Terrain Processes" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCrossingLinesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCrossingLinesAlgorithm.py index 3955d7b93..11ab5aeed 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCrossingLinesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCrossingLinesAlgorithm.py @@ -255,7 +255,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Line Handling") def groupId(self): """ @@ -265,7 +265,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Line Handling" def tr(self, string): return QCoreApplication.translate("IdentifyCrossingLinesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDanglesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDanglesAlgorithm.py index e895653b1..7a1523b5a 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDanglesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDanglesAlgorithm.py @@ -539,7 +539,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Line Handling") def groupId(self): """ @@ -549,7 +549,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Line Handling" def tr(self, string): return QCoreApplication.translate("IdentifyDanglesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py index f1e3e5315..f8101d890 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py @@ -561,7 +561,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Network Processes)") + return self.tr("QA Tools: Terrain Processes") def groupId(self): """ @@ -571,7 +571,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Network Processes)" + return "DSGTools - QA Tools: Terrain Processes" def shortHelpString(self): return self.tr( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAngleIssues.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAngleIssues.py index b46993141..5ec5b3160 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAngleIssues.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAngleIssues.py @@ -20,25 +20,13 @@ ***************************************************************************/ """ -import math -import concurrent.futures -import os -from PyQt5.QtCore import QCoreApplication, QVariant +from PyQt5.QtCore import QCoreApplication from qgis.core import ( - QgsFeature, - QgsFeatureRequest, - QgsField, - QgsFields, QgsGeometry, - QgsGeometryUtils, - QgsPoint, - QgsPointXY, QgsProcessing, QgsProcessingParameterFeatureSink, QgsProcessingParameterFeatureSource, - QgsProcessingParameterNumber, - QgsProject, QgsWkbTypes, QgsProcessingMultiStepFeedback, ) @@ -170,7 +158,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Drainage Network Processes") def groupId(self): """ @@ -180,7 +168,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return self.tr("DSGTools: Quality Assurance Tools (Identification Processes)") + return "DSGTools - QA Tools: Drainage Network Processes" def tr(self, string): return QCoreApplication.translate("IdentifyDrainageAngleIssues", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssues.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssues.py index db5c553d3..fde12e2fc 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssues.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssues.py @@ -20,25 +20,13 @@ ***************************************************************************/ """ -import math -import concurrent.futures -import os -from PyQt5.QtCore import QCoreApplication, QVariant +from PyQt5.QtCore import QCoreApplication from qgis.core import ( - QgsFeature, - QgsFeatureRequest, - QgsField, - QgsFields, QgsGeometry, - QgsGeometryUtils, - QgsPoint, - QgsPointXY, QgsProcessing, QgsProcessingParameterFeatureSink, QgsProcessingParameterFeatureSource, - QgsProcessingParameterNumber, - QgsProject, QgsWkbTypes, QgsProcessingMultiStepFeedback, ) @@ -168,7 +156,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Drainage Network Processes") def groupId(self): """ @@ -178,7 +166,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return self.tr("DSGTools: Quality Assurance Tools (Identification Processes)") + return "DSGTools - QA Tools: Drainage Network Processes" def tr(self, string): return QCoreApplication.translate("IdentifyDrainageFlowIssues", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssuesWithOtherHydrographicClassesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssuesWithOtherHydrographicClassesAlgorithm.py index bb0da1141..208247d31 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssuesWithOtherHydrographicClassesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssuesWithOtherHydrographicClassesAlgorithm.py @@ -762,7 +762,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Network Processes)") + return self.tr("QA Tools: Drainage Network Processes") def groupId(self): """ @@ -772,7 +772,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Network Processes)" + return "DSGTools - QA Tools: Drainage Network Processes" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageLoops.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageLoops.py index e38fa0f60..ecaa1372f 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageLoops.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageLoops.py @@ -226,7 +226,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Drainage Network Processes") def groupId(self): """ @@ -236,7 +236,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return self.tr("DSGTools: Quality Assurance Tools (Identification Processes)") + return "DSGTools - QA Tools: Drainage Network Processes" def tr(self, string): return QCoreApplication.translate("IdentifyDrainageLoops", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedFeaturesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedFeaturesAlgorithm.py index 83ac21e06..74da7a1ef 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedFeaturesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedFeaturesAlgorithm.py @@ -24,23 +24,15 @@ from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, - QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, QgsProcessingParameterField, QgsProcessingParameterVectorLayer, - QgsWkbTypes, ) -from ...algRunner import AlgRunner from .validationAlgorithm import ValidationAlgorithm from ..Help.algorithmHelpCreator import HTMLHelpCreator as help @@ -175,7 +167,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Duplicated Object Handling") def groupId(self): """ @@ -185,7 +177,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Duplicated Object Handling" def tr(self, string): return QCoreApplication.translate("IdentifyDuplicatedFeaturesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedGeometriesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedGeometriesAlgorithm.py index 30e924b5b..0801aeea6 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedGeometriesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedGeometriesAlgorithm.py @@ -21,19 +21,12 @@ """ from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, - QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, QgsProcessingParameterVectorLayer, - QgsWkbTypes, ) from qgis.PyQt.QtCore import QCoreApplication @@ -131,7 +124,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Duplicated Object Handling") def groupId(self): """ @@ -141,7 +134,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Duplicated Object Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedLinesBetweenLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedLinesBetweenLayersAlgorithm.py index 6d91decc5..9ae67fbe0 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedLinesBetweenLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedLinesBetweenLayersAlgorithm.py @@ -23,19 +23,12 @@ from PyQt5.QtCore import QCoreApplication from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, - QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, QgsProcessingParameterMultipleLayers, - QgsProcessingParameterVectorLayer, QgsWkbTypes, ) @@ -150,7 +143,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Duplicated Object Handling") def groupId(self): """ @@ -160,7 +153,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Duplicated Object Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedPointsBetweenLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedPointsBetweenLayersAlgorithm.py index 159586035..0f09ce48d 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedPointsBetweenLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedPointsBetweenLayersAlgorithm.py @@ -23,19 +23,12 @@ from PyQt5.QtCore import QCoreApplication from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, - QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, QgsProcessingParameterMultipleLayers, - QgsProcessingParameterVectorLayer, QgsWkbTypes, ) @@ -146,7 +139,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Duplicated Object Handling") def groupId(self): """ @@ -156,7 +149,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Duplicated Object Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedPolygonsBetweenLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedPolygonsBetweenLayersAlgorithm.py index 865373001..c21dea9b0 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedPolygonsBetweenLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedPolygonsBetweenLayersAlgorithm.py @@ -23,19 +23,12 @@ from PyQt5.QtCore import QCoreApplication from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, - QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, QgsProcessingParameterMultipleLayers, - QgsProcessingParameterVectorLayer, QgsWkbTypes, ) @@ -148,7 +141,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Duplicated Object Handling") def groupId(self): """ @@ -158,7 +151,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Duplicated Object Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedVertexesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedVertexesAlgorithm.py index 08c159da0..9948130f6 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedVertexesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDuplicatedVertexesAlgorithm.py @@ -188,7 +188,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Vertex Handling") def groupId(self): """ @@ -198,7 +198,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Vertex Handling" def tr(self, string): return QCoreApplication.translate("IdentifyDuplicatedVertexesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyGapsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyGapsAlgorithm.py index d2a73d490..5373eb275 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyGapsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyGapsAlgorithm.py @@ -143,7 +143,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Polygon Handling") def groupId(self): """ @@ -153,7 +153,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Polygon Handling" def tr(self, string): return QCoreApplication.translate("IdentifyGapsAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyGapsAndOverlapsInCoverageAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyGapsAndOverlapsInCoverageAlgorithm.py index cc8392c3c..d5ed6a8be 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyGapsAndOverlapsInCoverageAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyGapsAndOverlapsInCoverageAlgorithm.py @@ -266,7 +266,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Polygon Handling") def groupId(self): """ @@ -276,7 +276,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Polygon Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyGeometriesWithLargeVertexDensityAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyGeometriesWithLargeVertexDensityAlgorithm.py index b4af48866..061cfc340 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyGeometriesWithLargeVertexDensityAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyGeometriesWithLargeVertexDensityAlgorithm.py @@ -228,7 +228,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Vertex Handling") def groupId(self): """ @@ -238,7 +238,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Vertex Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyIntertwinedLinesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyIntertwinedLinesAlgorithm.py index b967b661a..a39429dc7 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyIntertwinedLinesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyIntertwinedLinesAlgorithm.py @@ -226,7 +226,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Line Handling") def groupId(self): """ @@ -236,7 +236,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Line Handling" def tr(self, string): return QCoreApplication.translate("IdentifyIntertwinedLinesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidAttributeCombinationsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidAttributeCombinationsAlgorithm.py index fa502a2e4..fb6177152 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidAttributeCombinationsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidAttributeCombinationsAlgorithm.py @@ -22,35 +22,14 @@ """ from PyQt5.QtCore import QCoreApplication -import processing from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, - QgsGeometry, - QgsProcessing, - QgsProcessingAlgorithm, - QgsProcessingException, QgsProcessingMultiStepFeedback, - QgsProcessingOutputVectorLayer, - QgsProcessingParameterBoolean, QgsProcessingParameterDefinition, - QgsProcessingParameterDistance, QgsProcessingParameterEnum, - QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, - QgsProcessingParameterField, - QgsProcessingParameterMultipleLayers, - QgsProcessingParameterNumber, QgsProcessingParameterType, - QgsProcessingParameterVectorLayer, - QgsProcessingUtils, - QgsSpatialIndex, - QgsWkbTypes, ) -from ...algRunner import AlgRunner from .validationAlgorithm import ValidationAlgorithm @@ -155,7 +134,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Identification") def groupId(self): """ @@ -165,7 +144,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Identification" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidSpatialRelationshipAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidSpatialRelationshipAlgorithm.py index c62c67cd3..b743f7bde 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidSpatialRelationshipAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidSpatialRelationshipAlgorithm.py @@ -196,7 +196,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Object Proximity and Relationships") def groupId(self): """ @@ -206,7 +206,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Object Proximity and Relationships" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidUUIDsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidUUIDsAlgorithm.py index 7321cf099..4694f2219 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidUUIDsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidUUIDsAlgorithm.py @@ -216,14 +216,14 @@ def displayName(self): Returns the translated algorithm name, which should be used for any user-visible display of the algorithm name. """ - return self.tr("Verifies features UUIDs") + return self.tr("Identify Features with Invalid UUIDs") def group(self): """ Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Attribute Handling") def groupId(self): """ @@ -233,7 +233,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Attribute Handling" def tr(self, string): return QCoreApplication.translate("IdentifyInvalidUUIDsAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyMultiPartGeometriesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyMultiPartGeometriesAlgorithm.py index 938cd1b6e..537a50387 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyMultiPartGeometriesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyMultiPartGeometriesAlgorithm.py @@ -137,7 +137,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Identification") def groupId(self): """ @@ -147,7 +147,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Identification" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyNetworkConstructionIssuesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyNetworkConstructionIssuesAlgorithm.py index 43e031ca0..9c712d0ac 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyNetworkConstructionIssuesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyNetworkConstructionIssuesAlgorithm.py @@ -366,7 +366,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Network Processes") def groupId(self): """ @@ -376,7 +376,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Network Processes" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyOutOfBoundsAnglesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyOutOfBoundsAnglesAlgorithm.py index 461c03b43..86f9e5458 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyOutOfBoundsAnglesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyOutOfBoundsAnglesAlgorithm.py @@ -24,15 +24,9 @@ from DsgTools.core.GeometricTools.geometryHandler import GeometryHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, - QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, QgsProcessingParameterNumber, QgsProcessingParameterVectorLayer, QgsWkbTypes, @@ -136,7 +130,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Basic Geometry Construction Issues Handling") def groupId(self): """ @@ -146,7 +140,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Basic Geometry Construction Issues Handling" def tr(self, string): return QCoreApplication.translate("IdentifyOutOfBoundsAnglesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyOutOfBoundsAnglesInCoverageAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyOutOfBoundsAnglesInCoverageAlgorithm.py index 87007bc24..91a7e3410 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyOutOfBoundsAnglesInCoverageAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyOutOfBoundsAnglesInCoverageAlgorithm.py @@ -21,14 +21,10 @@ """ from collections import defaultdict import math -from itertools import chain, combinations +from itertools import combinations -import concurrent.futures -import os import processing from DsgTools.core.DSGToolsProcessingAlgs.algRunner import AlgRunner -from DsgTools.core.GeometricTools.geometryHandler import GeometryHandler -from DsgTools.core.GeometricTools.layerHandler import LayerHandler from PyQt5.QtCore import QCoreApplication from qgis.core import ( QgsGeometry, @@ -303,7 +299,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Basic Geometry Construction Issues Handling") def groupId(self): """ @@ -313,7 +309,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Basic Geometry Construction Issues Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyOverlapsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyOverlapsAlgorithm.py index f3f10b26a..802b96715 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyOverlapsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyOverlapsAlgorithm.py @@ -239,7 +239,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Polygon Handling") def groupId(self): """ @@ -249,7 +249,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Polygon Handling" def tr(self, string): return QCoreApplication.translate("IdentifyOverlapsAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyPolygonSliverAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyPolygonSliverAlgorithm.py index 83b1bb51c..68b8ccc04 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyPolygonSliverAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyPolygonSliverAlgorithm.py @@ -200,14 +200,14 @@ def displayName(self): Returns the translated algorithm name, which should be used for any user-visible display of the algorithm name. """ - return self.tr("Identify polygon slivers") + return self.tr("Identify Polygon Slivers") def group(self): """ Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Polygon Handling") def groupId(self): """ @@ -217,7 +217,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Polygon Handling" def tr(self, string): return QCoreApplication.translate("IdentifyPolygonSliverAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyPolygonUndershoots.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyPolygonUndershoots.py index b9e65798c..0e89d9a70 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyPolygonUndershoots.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyPolygonUndershoots.py @@ -259,7 +259,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Polygon Handling") def groupId(self): """ @@ -269,7 +269,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Polygon Handling" def tr(self, string): return QCoreApplication.translate("IdentifyPolygonUndershootsAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySegmentErrorsBetweenLinesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySegmentErrorsBetweenLinesAlgorithm.py index 2161310df..6d6c53984 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySegmentErrorsBetweenLinesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySegmentErrorsBetweenLinesAlgorithm.py @@ -258,7 +258,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Line Handling") def groupId(self): """ @@ -268,7 +268,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Line Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallFirstOrderDangle.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallFirstOrderDangle.py index b1cadcc69..6df906434 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallFirstOrderDangle.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallFirstOrderDangle.py @@ -201,7 +201,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Small Object Handling") def groupId(self): """ @@ -211,7 +211,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Small Object Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallHolesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallHolesAlgorithm.py index 54072ccfc..1533c710f 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallHolesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallHolesAlgorithm.py @@ -135,7 +135,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Small Object Handling") def groupId(self): """ @@ -145,7 +145,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Small Object Handling" def tr(self, string): return QCoreApplication.translate("IdentifySmallHolesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallLinesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallLinesAlgorithm.py index b236d6d36..3d01e964e 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallLinesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallLinesAlgorithm.py @@ -142,7 +142,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Small Object Handling") def groupId(self): """ @@ -152,7 +152,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Small Object Handling" def tr(self, string): return QCoreApplication.translate("IdentifySmallLinesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallObjectsOnLayersAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallObjectsOnLayersAlgorithm.py index b418f2678..b7fc381e2 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallObjectsOnLayersAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallObjectsOnLayersAlgorithm.py @@ -182,7 +182,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Small Object Handling") def groupId(self): """ @@ -192,7 +192,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Small Object Handling" def tr(self, string): """ diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallPolygonsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallPolygonsAlgorithm.py index 19017342d..69d4492fa 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallPolygonsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifySmallPolygonsAlgorithm.py @@ -136,7 +136,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Small Object Handling") def groupId(self): """ @@ -146,7 +146,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Small Object Handling" def tr(self, string): return QCoreApplication.translate("IdentifySmallPolygonsAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyTerrainModelErrorsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyTerrainModelErrorsAlgorithm.py index 142344eb4..4890be9a7 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyTerrainModelErrorsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyTerrainModelErrorsAlgorithm.py @@ -52,7 +52,7 @@ class IdentifyTerrainModelErrorsAlgorithm(ValidationAlgorithm): CONTOUR_INTERVAL = "CONTOUR_INTERVAL" GEOGRAPHIC_BOUNDS = "GEOGRAPHIC_BOUNDS" CONTOUR_ATTR = "CONTOUR_ATTR" - INPUT_ELEVATION_POINTS = "INPUT_ELEVATION_POINTS" + INPUT_SPOT_ELEVATION = "INPUT_ELEVATION_POINTS" ELEVATION_POINT_ATTR = "ELEVATION_POINT_ATTR" GROUP_BY_SPATIAL_PARTITION = "GROUP_BY_SPATIAL_PARTITION" POINT_FLAGS = "POINT_FLAGS" @@ -85,8 +85,8 @@ def initAlgorithm(self, config): ) self.addParameter( QgsProcessingParameterVectorLayer( - self.INPUT_ELEVATION_POINTS, - self.tr("Input elevation points layer"), + self.INPUT_SPOT_ELEVATION, + self.tr("Input spot elevation layer"), [QgsProcessing.TypeVectorPoint], optional=True, ) @@ -94,9 +94,9 @@ def initAlgorithm(self, config): self.addParameter( QgsProcessingParameterField( self.ELEVATION_POINT_ATTR, - self.tr("Elevation point height value field"), + self.tr("Spot elevation height value field"), None, - "INPUT_ELEVATION_POINTS", + "INPUT_SPOT_ELEVATION", QgsProcessingParameterField.Any, optional=True, ) @@ -154,7 +154,7 @@ def processAlgorithm(self, parameters, context, feedback): parameters, self.GROUP_BY_SPATIAL_PARTITION, context ) elevationPointsLyr = self.parameterAsVectorLayer( - parameters, self.INPUT_ELEVATION_POINTS, context + parameters, self.INPUT_SPOT_ELEVATION, context ) elevationPointHeightFieldName = self.parameterAsFields( parameters, self.ELEVATION_POINT_ATTR, context @@ -170,7 +170,7 @@ def processAlgorithm(self, parameters, context, feedback): "", ): raise QgsProcessingException( - self.tr("Elevation point height attribute must be selected.") + self.tr("Spot elevation height attribute must be selected.") ) point_flagSink, point_flag_id = self.prepareAndReturnFlagSink( parameters, inputLyr, QgsWkbTypes.Point, context, self.POINT_FLAGS @@ -375,7 +375,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Terrain Processes") def groupId(self): """ @@ -385,7 +385,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Terrain Processes" def tr(self, string): return QCoreApplication.translate("IdentifyTerrainModelErrorsAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyUnmergedLinesWithSameAttributeSetAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyUnmergedLinesWithSameAttributeSetAlgorithm.py index 29192bcab..3a3cdd9bd 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyUnmergedLinesWithSameAttributeSetAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyUnmergedLinesWithSameAttributeSetAlgorithm.py @@ -22,7 +22,6 @@ """ import concurrent.futures -from collections import defaultdict import os from DsgTools.core.DSGToolsProcessingAlgs.algRunner import AlgRunner @@ -30,8 +29,6 @@ from DsgTools.core.GeometricTools.layerHandler import LayerHandler from PyQt5.QtCore import QCoreApplication from qgis.core import ( - QgsFeatureRequest, - QgsGeometry, QgsProcessing, QgsProcessingFeatureSourceDefinition, QgsProcessingMultiStepFeedback, @@ -327,7 +324,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Line Handling") def groupId(self): """ @@ -337,7 +334,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Line Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyUnsharedVertexOnIntersectionsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyUnsharedVertexOnIntersectionsAlgorithm.py index d692495b5..443ab8e51 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyUnsharedVertexOnIntersectionsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyUnsharedVertexOnIntersectionsAlgorithm.py @@ -165,7 +165,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Vertex Handling") def groupId(self): """ @@ -175,7 +175,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Vertex Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyUnsharedVertexOnSharedEdgesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyUnsharedVertexOnSharedEdgesAlgorithm.py index 5c930dafc..d021ec7a1 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyUnsharedVertexOnSharedEdgesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyUnsharedVertexOnSharedEdgesAlgorithm.py @@ -166,7 +166,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Vertex Handling") def groupId(self): """ @@ -176,7 +176,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Vertex Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyVertexNearEdgesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyVertexNearEdgesAlgorithm.py index 868b0a912..09525138e 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyVertexNearEdgesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyVertexNearEdgesAlgorithm.py @@ -24,24 +24,16 @@ from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, - QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterDistance, QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, - QgsProcessingParameterField, QgsProcessingParameterVectorLayer, QgsWkbTypes, ) -from ...algRunner import AlgRunner from .validationAlgorithm import ValidationAlgorithm from ..Help.algorithmHelpCreator import HTMLHelpCreator as help @@ -154,7 +146,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Basic Geometry Construction Issues Handling") def groupId(self): """ @@ -164,7 +156,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Basic Geometry Construction Issues Handling" def tr(self, string): return QCoreApplication.translate("IdentifyVertexNearEdgesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyWrongBuildingAnglesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyWrongBuildingAnglesAlgorithm.py index fb783d7d5..231defeeb 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyWrongBuildingAnglesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyWrongBuildingAnglesAlgorithm.py @@ -158,7 +158,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Basic Geometry Construction Issues Handling") def groupId(self): """ @@ -168,7 +168,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Basic Geometry Construction Issues Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyZAnglesBetweenFeaturesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyZAnglesBetweenFeaturesAlgorithm.py index 2909e73cf..78b41d3e3 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyZAnglesBetweenFeaturesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyZAnglesBetweenFeaturesAlgorithm.py @@ -384,7 +384,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Basic Geometry Construction Issues Handling") def groupId(self): """ @@ -394,7 +394,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Basic Geometry Construction Issues Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/lineOnLineOverlayerAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/lineOnLineOverlayerAlgorithm.py index 5bae5cb95..7ea0b0a1e 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/lineOnLineOverlayerAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/lineOnLineOverlayerAlgorithm.py @@ -22,29 +22,14 @@ """ from PyQt5.QtCore import QCoreApplication -import processing from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, - QgsGeometry, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingMultiStepFeedback, QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterDistance, - QgsProcessingParameterEnum, - QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, - QgsProcessingParameterField, - QgsProcessingParameterMultipleLayers, - QgsProcessingParameterNumber, QgsProcessingParameterVectorLayer, - QgsProcessingUtils, - QgsSpatialIndex, - QgsWkbTypes, ) from ...algRunner import AlgRunner @@ -167,7 +152,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("QA Tools: Line Handling") def groupId(self): """ @@ -177,7 +162,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - QA Tools: Line Handling" def tr(self, string): return QCoreApplication.translate("LineOnLineOverlayerAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/mergeLinesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/mergeLinesAlgorithm.py index 925b0dc7e..f6211edfc 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/mergeLinesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/mergeLinesAlgorithm.py @@ -255,7 +255,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("QA Tools: Line Handling") def groupId(self): """ @@ -265,7 +265,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - QA Tools: Line Handling" def tr(self, string): return QCoreApplication.translate("MergeLinesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/overlayElementsWithAreasAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/overlayElementsWithAreasAlgorithm.py index 3b3e3725d..c7e191e6e 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/overlayElementsWithAreasAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/overlayElementsWithAreasAlgorithm.py @@ -22,30 +22,15 @@ """ from PyQt5.QtCore import QCoreApplication -import processing from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, - QgsGeometry, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, - QgsProcessingParameterDistance, QgsProcessingParameterEnum, - QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, - QgsProcessingParameterMultipleLayers, - QgsProcessingParameterNumber, QgsProcessingParameterVectorLayer, - QgsProcessingUtils, - QgsProject, - QgsSpatialIndex, - QgsWkbTypes, ) from ...algRunner import AlgRunner @@ -223,7 +208,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("Geometric Algorithms") def groupId(self): """ @@ -233,7 +218,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - Geometric Algorithms" def tr(self, string): return QCoreApplication.translate("OverlayElementsWithAreasAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeDuplicatedFeaturesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeDuplicatedFeaturesAlgorithm.py index d1a3bc2c3..5effc4abb 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeDuplicatedFeaturesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeDuplicatedFeaturesAlgorithm.py @@ -24,20 +24,13 @@ from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, - QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, QgsProcessingParameterField, QgsProcessingParameterVectorLayer, - QgsWkbTypes, ) from .validationAlgorithm import ValidationAlgorithm @@ -172,7 +165,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Correction Processes)") + return self.tr("QA Tools: Duplicated Object Handling") def groupId(self): """ @@ -182,7 +175,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Correction Processes)" + return "DSGTools - QA Tools: Duplicated Object Handling" def tr(self, string): return QCoreApplication.translate("RemoveDuplicatedFeaturesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeDuplicatedGeometriesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeDuplicatedGeometriesAlgorithm.py index b9fd6d56f..3cd2291df 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeDuplicatedGeometriesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeDuplicatedGeometriesAlgorithm.py @@ -23,19 +23,13 @@ from PyQt5.QtCore import QCoreApplication from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, QgsProcessingParameterVectorLayer, - QgsWkbTypes, ) from ...algRunner import AlgRunner @@ -155,7 +149,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Correction Processes)") + return self.tr("QA Tools: Duplicated Object Handling") def groupId(self): """ @@ -165,7 +159,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Correction Processes)" + return "DSGTools - QA Tools: Duplicated Object Handling" def tr(self, string): return QCoreApplication.translate("RemoveDuplicatedGeometriesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeEmptyAndUpdateAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeEmptyAndUpdateAlgorithm.py index ff5c18b8a..6d7d7a5ac 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeEmptyAndUpdateAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeEmptyAndUpdateAlgorithm.py @@ -22,30 +22,14 @@ """ from PyQt5.QtCore import QCoreApplication -import processing from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, - QgsGeometry, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, - QgsProcessingParameterDistance, - QgsProcessingParameterEnum, - QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, - QgsProcessingParameterField, - QgsProcessingParameterMultipleLayers, - QgsProcessingParameterNumber, QgsProcessingParameterVectorLayer, - QgsProcessingUtils, - QgsSpatialIndex, - QgsWkbTypes, ) from ...algRunner import AlgRunner @@ -145,7 +129,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("QA Tools: Basic Geometry Construction Issues Handling") def groupId(self): """ @@ -155,7 +139,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - QA Tools: Basic Geometry Construction Issues Handling" def tr(self, string): return QCoreApplication.translate("RemoveEmptyAndUpdateAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeSmallLinesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeSmallLinesAlgorithm.py index 4be218610..f1604897e 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeSmallLinesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeSmallLinesAlgorithm.py @@ -22,18 +22,11 @@ from PyQt5.QtCore import QCoreApplication from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, - QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, QgsProcessingParameterNumber, QgsProcessingParameterVectorLayer, - QgsWkbTypes, QgsProcessingMultiStepFeedback, QgsProcessingException, ) @@ -150,7 +143,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Correction Processes)") + return self.tr("QA Tools: Small Object Handling") def groupId(self): """ @@ -160,7 +153,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Correction Processes)" + return "DSGTools - QA Tools: Small Object Handling" def tr(self, string): return QCoreApplication.translate("RemoveSmallLinesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeSmallPolygonsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeSmallPolygonsAlgorithm.py index 7eb3fbac0..a06d4fc5b 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeSmallPolygonsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/removeSmallPolygonsAlgorithm.py @@ -23,20 +23,13 @@ from PyQt5.QtCore import QCoreApplication from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, - QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, QgsProcessingParameterNumber, QgsProcessingParameterVectorLayer, - QgsWkbTypes, ) from ...algRunner import AlgRunner @@ -153,7 +146,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Correction Processes)") + return self.tr("QA Tools: Small Object Handling") def groupId(self): """ @@ -163,7 +156,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Correction Processes)" + return "DSGTools - QA Tools: Small Object Handling" def tr(self, string): return QCoreApplication.translate("RemoveSmallPolygonsAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/snapLayerOnLayerAndUpdateAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/snapLayerOnLayerAndUpdateAlgorithm.py index 1752a69ae..75077c40e 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/snapLayerOnLayerAndUpdateAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/snapLayerOnLayerAndUpdateAlgorithm.py @@ -20,35 +20,20 @@ * * ***************************************************************************/ """ -from DsgTools.core.GeometricTools import layerHandler from PyQt5.QtCore import QCoreApplication -import processing from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, - QgsGeometry, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterDistance, QgsProcessingParameterEnum, - QgsProcessingParameterFeatureSink, QgsProcessingParameterFeatureSource, - QgsProcessingParameterField, - QgsProcessingParameterMultipleLayers, - QgsProcessingParameterNumber, QgsProcessingParameterVectorLayer, QgsProcessingParameterFeatureSource, - QgsProcessingUtils, - QgsSpatialIndex, - QgsWkbTypes, - QgsProject, ) from ...algRunner import AlgRunner @@ -215,7 +200,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("QA Tools: Snap Processes") def groupId(self): """ @@ -225,7 +210,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - QA Tools: Snap Processes" def tr(self, string): return QCoreApplication.translate("SnapLayerOnLayerAndUpdateAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/snapToGridAndUpdateAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/snapToGridAndUpdateAlgorithm.py index 76db5a7e3..54c552ffa 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/snapToGridAndUpdateAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/snapToGridAndUpdateAlgorithm.py @@ -22,30 +22,15 @@ """ from PyQt5.QtCore import QCoreApplication -import processing from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, - QgsGeometry, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterDistance, - QgsProcessingParameterEnum, - QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, - QgsProcessingParameterField, - QgsProcessingParameterMultipleLayers, - QgsProcessingParameterNumber, QgsProcessingParameterVectorLayer, - QgsProcessingUtils, - QgsSpatialIndex, - QgsWkbTypes, ) from ...algRunner import AlgRunner @@ -156,7 +141,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("QA Tools: Basic Geometry Construction Issues Handling") def groupId(self): """ @@ -166,7 +151,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - QA Tools: Basic Geometry Construction Issues Handling" def tr(self, string): return QCoreApplication.translate("SnapToGridAndUpdateAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/spatialRulesCheckerAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/spatialRulesCheckerAlgorithm.py index 55b72de29..9ba4b4085 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/spatialRulesCheckerAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/spatialRulesCheckerAlgorithm.py @@ -20,35 +20,9 @@ * * ***************************************************************************/ """ -from DsgTools.core.GeometricTools.layerHandler import LayerHandler -from ...algRunner import AlgRunner -import processing, os, requests -from time import sleep from PyQt5.QtCore import QCoreApplication from qgis.core import ( - QgsProcessing, - QgsFeatureSink, QgsProcessingAlgorithm, - QgsProcessingParameterFeatureSource, - QgsProcessingParameterFeatureSink, - QgsFeature, - QgsDataSourceUri, - QgsProcessingOutputVectorLayer, - QgsProcessingParameterVectorLayer, - QgsWkbTypes, - QgsProcessingParameterBoolean, - QgsProcessingParameterEnum, - QgsProcessingParameterNumber, - QgsProcessingParameterMultipleLayers, - QgsProcessingUtils, - QgsSpatialIndex, - QgsGeometry, - QgsProcessingParameterField, - QgsProcessingMultiStepFeedback, - QgsProcessingParameterFile, - QgsProcessingParameterExpression, - QgsProcessingException, - QgsProcessingParameterString, QgsProcessingParameterDefinition, QgsProcessingParameterType, ) @@ -104,7 +78,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Identification") def groupId(self): """ @@ -114,7 +88,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Identification" def tr(self, string): return QCoreApplication.translate("RunRemoteFMEAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/spellCheckerAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/spellCheckerAlgorithm.py index 2f3e2540a..5ba08872d 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/spellCheckerAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/spellCheckerAlgorithm.py @@ -150,14 +150,14 @@ def name(self): return "spellchecker" def displayName(self): - return self.tr("Spell check") + return self.tr("Spell Check") def group(self): """ Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Attribute Handling") def groupId(self): """ @@ -167,7 +167,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Attribute Handling" def tr(self, string): return QCoreApplication.translate("SpellCheckerAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/streamOrder.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/streamOrder.py index 09eebf69f..47ac56e0c 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/streamOrder.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/streamOrder.py @@ -160,7 +160,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Network Processes)") + return self.tr("QA Tools: Drainage Network Processes") def groupId(self): """ @@ -170,7 +170,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Network Processes)" + return "DSGTools - QA Tools: Drainage Network Processes" def shortHelpString(self): return self.tr( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalCleanAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalCleanAlgorithm.py index be155efb6..138ab02db 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalCleanAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalCleanAlgorithm.py @@ -215,7 +215,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Topological Processes)") + return self.tr("QA Tools: Topological Processes") def groupId(self): """ @@ -225,7 +225,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Topological Processes)" + return "DSGTools - QA Tools: Topological Processes" def tr(self, string): return QCoreApplication.translate("TopologicalCleanAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalCleanLinesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalCleanLinesAlgorithm.py index e5a612c5e..52532853c 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalCleanLinesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalCleanLinesAlgorithm.py @@ -120,7 +120,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Topological Processes)") + return self.tr("QA Tools: Topological Processes") def groupId(self): """ @@ -130,7 +130,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Topological Processes)" + return "DSGTools - QA Tools: Topological Processes" def tr(self, string): return QCoreApplication.translate("TopologicalCleanLinesAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalDouglasAreaSimplificationAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalDouglasAreaSimplificationAlgorithm.py index c0ef78af9..c11593361 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalDouglasAreaSimplificationAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalDouglasAreaSimplificationAlgorithm.py @@ -227,7 +227,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Topological Processes)") + return self.tr("QA Tools: Topological Processes") def groupId(self): """ @@ -237,7 +237,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Topological Processes)" + return "DSGTools - QA Tools: Topological Processes" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalDouglasLineSimplificationAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalDouglasLineSimplificationAlgorithm.py index 5a719c4ec..07feb01dc 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalDouglasLineSimplificationAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalDouglasLineSimplificationAlgorithm.py @@ -216,7 +216,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Topological Processes)") + return self.tr("QA Tools: Topological Processes") def groupId(self): """ @@ -226,7 +226,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Topological Processes)" + return "DSGTools - QA Tools: Topological Processes" def tr(self, string): """ diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalLineConnectivityAdjustmentAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalLineConnectivityAdjustmentAlgorithm.py index 87b8d39c5..e84bbc60d 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalLineConnectivityAdjustmentAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/topologicalLineConnectivityAdjustmentAlgorithm.py @@ -167,7 +167,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Network Processes)") + return self.tr("QA Tools: Network Processes") def groupId(self): """ @@ -177,7 +177,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Network Processes)" + return "DSGTools - QA Tools: Network Processes" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/unbuildPolygonsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/unbuildPolygonsAlgorithm.py index 755d42615..462721fb3 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/unbuildPolygonsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/unbuildPolygonsAlgorithm.py @@ -24,19 +24,11 @@ from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingException, QgsProcessingMultiStepFeedback, - QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, - QgsProcessingParameterDistance, QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, - QgsProcessingParameterField, QgsProcessingParameterMultipleLayers, QgsProcessingParameterVectorLayer, QgsWkbTypes, @@ -201,7 +193,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Manipulation Processes)") + return self.tr("QA Tools: Polygon Handling") def groupId(self): """ @@ -211,7 +203,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Manipulation Processes)" + return "DSGTools - QA Tools: Polygon Handling" def tr(self, string): return QCoreApplication.translate("UnbuildPolygonsAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/unicodeFilterAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/unicodeFilterAlgorithm.py index 1a3c6da02..673473fbc 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/unicodeFilterAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/unicodeFilterAlgorithm.py @@ -182,14 +182,14 @@ def name(self): return "unicodefilter" def displayName(self): - return self.tr("Identify features with invalid unicode") + return self.tr("Identify Features With Invalid Unicode") def group(self): """ Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Attribute Handling") def groupId(self): """ @@ -199,7 +199,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Attribute Handling" def shortHelpString(self): return self.tr( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/verifyAdjacentGeographicBoundaryDataAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/verifyAdjacentGeographicBoundaryDataAlgorithm.py index 726a21d7b..b414e7006 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/verifyAdjacentGeographicBoundaryDataAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/verifyAdjacentGeographicBoundaryDataAlgorithm.py @@ -647,7 +647,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("Quality Assurance Tools (Identification Processes)") + return self.tr("QA Tools: Identification") def groupId(self): """ @@ -657,7 +657,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools: Quality Assurance Tools (Identification Processes)" + return "DSGTools - QA Tools: Identification" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py b/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py index 5b10ead86..7062e997b 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py @@ -244,7 +244,7 @@ DeaggregatorAlgorithm, ) from DsgTools.core.DSGToolsProcessingAlgs.Algs.ValidationAlgs.detectChangesGroupAlgorithm import ( - DetectChangesGroupAlgorithm, + DetectChangesBetweenGroups, ) from DsgTools.core.DSGToolsProcessingAlgs.Algs.ValidationAlgs.detectNullGeometriesAlgorithm import ( DetectNullGeometriesAlgorithm, @@ -615,7 +615,7 @@ def getAlgList(self): FixSegmentErrorsBetweenLinesAlgorithm(), IdentifyDifferencesBetweenDatabaseModelsAlgorithm(), AzimuthCalculationAlgorithm(), - DetectChangesGroupAlgorithm(), + DetectChangesBetweenGroups(), ] return algList diff --git a/DsgTools/i18n/DsgTools_pt.ts b/DsgTools/i18n/DsgTools_pt.ts index 5b6244ec4..ed2d71e32 100644 --- a/DsgTools/i18n/DsgTools_pt.ts +++ b/DsgTools/i18n/DsgTools_pt.ts @@ -2051,7 +2051,7 @@ Mensagens de erro para cada banco de dados foram registradas no log do QGIS. - Other Algorithms + Utils Outros algoritmos @@ -3433,7 +3433,7 @@ A conversão deve ser entre bancos de dados com a mesma versão! - Other Algorithms + Utils Outros algoritmos @@ -3827,7 +3827,7 @@ A conversão deve ser entre bancos de dados com a mesma versão! - Other Algorithms + Utils Outros algoritmos @@ -3860,7 +3860,7 @@ A conversão deve ser entre bancos de dados com a mesma versão! - Other Algorithms + Utils Outros algoritmos @@ -8809,7 +8809,7 @@ Ao segurar a tecla Control, a obrigatoriedade de ângulos retos é desligada enq - Other Algorithms + Utils Outros algoritmos @@ -9414,7 +9414,7 @@ Ao segurar a tecla Control, a obrigatoriedade de ângulos retos é desligada enq - Other Algorithms + Utils Outros algoritmos @@ -15367,7 +15367,7 @@ Camada - Other Algorithms + Utils Outros algoritmos @@ -18483,7 +18483,7 @@ Versão do modelo: {1} - Other Algorithms + Utils Outros algoritmos @@ -19081,7 +19081,7 @@ Camada - Other Algorithms + Utils Outros algoritmos @@ -19159,7 +19159,7 @@ Camada - Other Algorithms + Utils Outros algoritmos @@ -20051,7 +20051,7 @@ Se existe um atributo restritivo na classe selecionada, clique com o botão dire - Other Algorithms + Utils Outros algoritmos @@ -21276,7 +21276,7 @@ Camada - Other Algorithms + Utils Outros algoritmos @@ -22159,7 +22159,7 @@ Camada - Other Algorithms + Utils Outros algoritmos From 203203b43c58d12824f88acd1d23c8126aa718db Mon Sep 17 00:00:00 2001 From: phborba Date: Mon, 2 Oct 2023 18:57:47 -0300 Subject: [PATCH 05/53] =?UTF-8?q?Vers=C3=A3o=204.11.18:=20bug=20fix=20no?= =?UTF-8?q?=20ClipAndCopyFeaturesBetweenDatabasesAlgorithm?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 4 +++- .../clipAndCopyFeaturesBetweenDatabasesAlgorithm.py | 2 +- DsgTools/metadata.txt | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index c06aef59b..fcd46fbb3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.17 - dev +## 4.11.18 - dev Novas Funcionalidades: @@ -17,6 +17,7 @@ Melhorias: - Melhoria de desempenho no processo Unir Linhas com Mesmo Conjunto de Atributos (Merge Lines With Same Attribute Set): Código refatorado para usar busca utilizando grafo. Além disso, o processo pega casos que não eram unidos anteriormente (linhas com mesmo conjunto de atributos e encadeadas); - Melhoria de desempenho no processo Identify Unmerged Lines With Same Attribute Set: Código refatorado para usar busca utilizando grafo; - O detecta nula agora indica quais camadas tem que ser verificadas; +- Algoritmos da caixa de ferramentas reorganizados por temática para facilitar o uso; Correção de bug: @@ -29,6 +30,7 @@ Correção de bug: - Corrige bug na ferramenta de inverter o sentido de linhas (flip lines) quando é uma camada não salva do banco de dados; - Corrige bug na geração de moldura relativo a camada (Generate Systematic Grid Related to Layer) quando se usa memory layer (o memory layer não atualiza seu extent automaticamente, logo foi necessário colocar um layer.updateExtents() no código antes de calcular o extent); - Corrige bug no processo de calcular azimute (estava sendo calculado com +90 graus); +- Corrige bug no ClipAndCopyFeaturesBetweenDatabasesAlgorithm; ## 4.10.1 - 2023-10-02 diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/clipAndCopyFeaturesBetweenDatabasesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/clipAndCopyFeaturesBetweenDatabasesAlgorithm.py index 83d935920..630816614 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/clipAndCopyFeaturesBetweenDatabasesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/clipAndCopyFeaturesBetweenDatabasesAlgorithm.py @@ -236,7 +236,7 @@ def getLayersFromDbConnectionName( withElements=withElements ) inputParamList = list(map(lambda x: x.split(".")[-1], inputParamList)) - if layerNameList is not None: + if layerNameList is not None and layerNameList != []: inputParamList = list(filter(lambda x: x in layerNameList, inputParamList)) loadedLayerList = layerLoader.loadLayersInsideProcessing( inputParamList, addToCanvas=addToCanvas, feedback=feedback diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index e84cbfbcd..c89ee1335 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.17 +version=4.11.18 author=Brazilian Army Geographic Service email=suporte.dsgtools@dsg.eb.mil.br about= From 20bfacd5f7fd4b08f3a425c413b1993e4d7d5025 Mon Sep 17 00:00:00 2001 From: phborba Date: Mon, 2 Oct 2023 19:12:23 -0300 Subject: [PATCH 06/53] bug fix --- .../clipAndCopyFeaturesBetweenDatabasesAlgorithm.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/clipAndCopyFeaturesBetweenDatabasesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/clipAndCopyFeaturesBetweenDatabasesAlgorithm.py index 630816614..ae4bc26c7 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/clipAndCopyFeaturesBetweenDatabasesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/DataManagementAlgs/clipAndCopyFeaturesBetweenDatabasesAlgorithm.py @@ -277,7 +277,7 @@ def clipInputLayerList(self, inputLayerList, geom, context, feedback): self.layerHandler.createMemoryLayerFromGeometry( geom=geom, crs=QgsProject.instance().crs() ) - if geom is not None + if geom is not None and not geom.isEmpty() else None ) for currentIdx, lyr in enumerate(inputLayerList): From bb56b6fec5817f9ef6672c493759b7ef2313ec05 Mon Sep 17 00:00:00 2001 From: phborba Date: Tue, 3 Oct 2023 12:55:56 -0300 Subject: [PATCH 07/53] processing group refactor --- .../detectChangesGroupAlgorithm.py | 4 +- .../fixDrainageFlowAlgorithm.py | 4 +- .../identifyDrainageAngleIssues.py | 4 +- .../identifyDrainageFlowIssues.py | 4 +- ...esWithOtherHydrographicClassesAlgorithm.py | 4 +- .../ValidationAlgs/identifyDrainageLoops.py | 4 +- ...fyInvalidAttributeCombinationsAlgorithm.py | 220 ------------------ .../identifyMultiPartGeometriesAlgorithm.py | 4 +- .../spatialRulesCheckerAlgorithm.py | 150 ------------ .../Algs/ValidationAlgs/streamOrder.py | 4 +- ...AdjacentGeographicBoundaryDataAlgorithm.py | 4 +- 11 files changed, 18 insertions(+), 388 deletions(-) delete mode 100644 DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidAttributeCombinationsAlgorithm.py delete mode 100644 DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/spatialRulesCheckerAlgorithm.py diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectChangesGroupAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectChangesGroupAlgorithm.py index 2e974cf4a..f75a22138 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectChangesGroupAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/detectChangesGroupAlgorithm.py @@ -379,7 +379,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("QA Tools: Identification") + return self.tr("QA Tools: Dataset Processes") def groupId(self): """ @@ -389,7 +389,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools - QA Tools: Identification" + return "DSGTools - QA Tools: Dataset Processes" def tr(self, string): return QCoreApplication.translate("DetectChangesBetweenGroups", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixDrainageFlowAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixDrainageFlowAlgorithm.py index 0bdb8a291..3952ca728 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixDrainageFlowAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixDrainageFlowAlgorithm.py @@ -510,7 +510,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("QA Tools: Drainage Network Processes") + return self.tr("QA Tools: Drainage Flow Processes") def groupId(self): """ @@ -520,7 +520,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools - QA Tools: Drainage Network Processes" + return "DSGTools - QA Tools: Drainage Flow Processes" def tr(self, string): return QCoreApplication.translate("FixDrainageFlowAlgorithm", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAngleIssues.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAngleIssues.py index 5ec5b3160..e2509e73e 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAngleIssues.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAngleIssues.py @@ -158,7 +158,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("QA Tools: Drainage Network Processes") + return self.tr("QA Tools: Drainage Flow Processes") def groupId(self): """ @@ -168,7 +168,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools - QA Tools: Drainage Network Processes" + return "DSGTools - QA Tools: Drainage Flow Processes" def tr(self, string): return QCoreApplication.translate("IdentifyDrainageAngleIssues", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssues.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssues.py index fde12e2fc..8440ba18d 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssues.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssues.py @@ -156,7 +156,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("QA Tools: Drainage Network Processes") + return self.tr("QA Tools: Drainage Flow Processes") def groupId(self): """ @@ -166,7 +166,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools - QA Tools: Drainage Network Processes" + return "DSGTools - QA Tools: Drainage Flow Processes" def tr(self, string): return QCoreApplication.translate("IdentifyDrainageFlowIssues", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssuesWithOtherHydrographicClassesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssuesWithOtherHydrographicClassesAlgorithm.py index 208247d31..4a826759c 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssuesWithOtherHydrographicClassesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageFlowIssuesWithOtherHydrographicClassesAlgorithm.py @@ -762,7 +762,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("QA Tools: Drainage Network Processes") + return self.tr("QA Tools: Drainage Flow Processes") def groupId(self): """ @@ -772,7 +772,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools - QA Tools: Drainage Network Processes" + return "DSGTools - QA Tools: Drainage Flow Processes" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageLoops.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageLoops.py index ecaa1372f..78f75d7bb 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageLoops.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageLoops.py @@ -226,7 +226,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("QA Tools: Drainage Network Processes") + return self.tr("QA Tools: Drainage Flow Processes") def groupId(self): """ @@ -236,7 +236,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools - QA Tools: Drainage Network Processes" + return "DSGTools - QA Tools: Drainage Flow Processes" def tr(self, string): return QCoreApplication.translate("IdentifyDrainageLoops", string) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidAttributeCombinationsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidAttributeCombinationsAlgorithm.py deleted file mode 100644 index fb6177152..000000000 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyInvalidAttributeCombinationsAlgorithm.py +++ /dev/null @@ -1,220 +0,0 @@ -# -*- coding: utf-8 -*- -""" -/*************************************************************************** - DsgTools - A QGIS plugin - Brazilian Army Cartographic Production Tools - ------------------- - begin : 2018-12-10 - git sha : $Format:%H$ - copyright : (C) 2018 by Philipe Borba - Cartographic Engineer @ Brazilian Army - email : borba.philipe@eb.mil.br - ***************************************************************************/ - -/*************************************************************************** - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * * - ***************************************************************************/ -""" -from PyQt5.QtCore import QCoreApplication - -from DsgTools.core.GeometricTools.layerHandler import LayerHandler -from qgis.core import ( - QgsProcessingMultiStepFeedback, - QgsProcessingParameterDefinition, - QgsProcessingParameterEnum, - QgsProcessingParameterType, -) - -from .validationAlgorithm import ValidationAlgorithm - - -class IdentifyInvalidAttributeCombinationsAlgorithm(ValidationAlgorithm): - ATTRIBUTE_RULES = "ATTRIBUTE_RULES" - BEHAVIOR = "BEHAVIOR" - - def initAlgorithm(self, config): - """ - Parameter setting. - """ - - hierarchy = ParameterAttributeRules( - self.ATTRIBUTE_RULES, description=self.tr("Attribute Rules") - ) - hierarchy.setMetadata( - { - "widget_wrapper": "DsgTools.gui.ProcessingUI.attributeRulesWrapper.AttributeRulesWrapper" - } - ) - self.addParameter(hierarchy) - - self.modes = [ - self.tr("Prefer aligning nodes, insert extra vertices where required"), - self.tr("Prefer closest point, insert extra vertices where required"), - self.tr("Prefer aligning nodes, don't insert new vertices"), - self.tr("Prefer closest point, don't insert new vertices"), - self.tr("Move end points only, prefer aligning nodes"), - self.tr("Move end points only, prefer closest point"), - self.tr("Snap end points to end points only"), - ] - - self.addParameter( - QgsProcessingParameterEnum( - self.BEHAVIOR, self.tr("Behavior"), options=self.modes, defaultValue=0 - ) - ) - - def parameterAsAttributeRules(self, parameters, name, context): - return parameters[name] - - def processAlgorithm(self, parameters, context, feedback): - """ - Here is where the processing itself takes place. - """ - layerHandler = LayerHandler() - snapDict = self.parameterAsSnapHierarchy( - parameters, self.SNAP_HIERARCHY, context - ) - - onlySelected = self.parameterAsBool(parameters, self.SELECTED, context) - - behavior = self.parameterAsEnum(parameters, self.BEHAVIOR, context) - nSteps = 0 - for item in snapDict: - nSteps += len(item["snapLayerList"]) - currStep = 0 - multiStepFeedback = QgsProcessingMultiStepFeedback(nSteps, feedback) - for current, item in enumerate(snapDict): - refLyr = item["referenceLayer"] - for i, lyr in enumerate(item["snapLayerList"]): - if multiStepFeedback.isCanceled(): - break - multiStepFeedback.setCurrentStep(currStep) - multiStepFeedback.pushInfo( - self.tr( - "Snapping geometries from layer {input} to {reference} with snap {snap}..." - ).format( - input=lyr.name(), reference=refLyr.name(), snap=item["snap"] - ) - ) - layerHandler.snapToLayer( - lyr, - refLyr, - item["snap"], - behavior, - onlySelected=onlySelected, - feedback=multiStepFeedback, - ) - currStep += 1 - return {} - - def name(self): - """ - Returns the algorithm name, used for identifying the algorithm. This - string should be fixed for the algorithm, and must not be localised. - The name should be unique within each provider. Names should contain - lowercase alphanumeric characters only and no spaces or other - formatting characters. - """ - return "identifyinvalidattributecombinations" - - def displayName(self): - """ - Returns the translated algorithm name, which should be used for any - user-visible display of the algorithm name. - """ - return self.tr("Identify Invalid Attribute Combinations") - - def group(self): - """ - Returns the name of the group this algorithm belongs to. This string - should be localised. - """ - return self.tr("QA Tools: Identification") - - def groupId(self): - """ - Returns the unique ID of the group this algorithm belongs to. This - string should be fixed for the algorithm, and must not be localised. - The group id should be unique within each provider. Group id should - contain lowercase alphanumeric characters only and no spaces or other - formatting characters. - """ - return "DSGTools - QA Tools: Identification" - - def tr(self, string): - return QCoreApplication.translate( - "IdentifyInvalidAttributeCombinationsAlgorithm", string - ) - - def createInstance(self): - return IdentifyInvalidAttributeCombinationsAlgorithm() - - -class ParameterAttributeRulesType(QgsProcessingParameterType): - def __init__(self): - super().__init__() - - def create(self, name): - return ParameterAttributeRules(name) # mudar - - def metadata(self): - return { - "widget_wrapper": "DSGTools.gui.ProcessingUI.attributeRulesWrapper.AttributeRulesWrapper" - } # mudar - - def name(self): - return QCoreApplication.translate("Processing", "Attribute Rules") - - def id(self): - return "attribute_rules" - - def description(self): - return QCoreApplication.translate( - "Processing", - "An attribute rules type. Used in the Identify Invalid Attribute Combinations algorithm.", - ) - - -class ParameterAttributeRules(QgsProcessingParameterDefinition): - def __init__(self, name, description=""): - super().__init__(name, description) - - def clone(self): - copy = ParameterAttributeRules(self.name(), self.description()) - return copy - - def type(self): - return self.typeName() - - @staticmethod - def typeName(): - return "attribute_rules" - - def checkValueIsAcceptable(self, value, context=None): - # if not isinstance(value, list): - # return False - # for field_def in value: - # if not isinstance(field_def, dict): - # return False - # if 'name' not in field_def.keys(): - # return False - # if 'type' not in field_def.keys(): - # return False - # if 'expression' not in field_def.keys(): - # return False - return True - - def valueAsPythonString(self, value, context): - return str(value) - - def asScriptCode(self): - raise NotImplementedError() - - @classmethod - def fromScriptCode(cls, name, description, isOptional, definition): - raise NotImplementedError() diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyMultiPartGeometriesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyMultiPartGeometriesAlgorithm.py index 537a50387..4ce34f968 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyMultiPartGeometriesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyMultiPartGeometriesAlgorithm.py @@ -137,7 +137,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("QA Tools: Identification") + return self.tr("QA Tools: Basic Geometry Construction Issues Handling") def groupId(self): """ @@ -147,7 +147,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools - QA Tools: Identification" + return "DSGTools - QA Tools: Basic Geometry Construction Issues Handling" def tr(self, string): return QCoreApplication.translate( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/spatialRulesCheckerAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/spatialRulesCheckerAlgorithm.py deleted file mode 100644 index 9ba4b4085..000000000 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/spatialRulesCheckerAlgorithm.py +++ /dev/null @@ -1,150 +0,0 @@ -# -*- coding: utf-8 -*- -""" -/*************************************************************************** - DsgTools - A QGIS plugin - Brazilian Army Cartographic Production Tools - ------------------- - begin : 2019-01-16 - git sha : $Format:%H$ - copyright : (C) 2019 by Philipe Borba - Cartographic Engineer @ Brazilian Army - email : borba.philipe@eb.mil.br - ***************************************************************************/ - -/*************************************************************************** - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * * - ***************************************************************************/ -""" -from PyQt5.QtCore import QCoreApplication -from qgis.core import ( - QgsProcessingAlgorithm, - QgsProcessingParameterDefinition, - QgsProcessingParameterType, -) - - -class SpatialRulesCheckerAlgorithm(QgsProcessingAlgorithm): - RULES_SET = "RULES_SET" - - def initAlgorithm(self, config): - """ - Parameter setting. - """ - spatialRulesSet = ParameterSpatialRulesSet( - self.RULES_SET, description=self.tr("Spatial Rules Set") - ) - managerParameter.setMetadata( - { - "widget_wrapper": "DsgTools.gui.ProcessingUI.spatialRulesSetWrapper.SpatialRulesSetWrapper" - } - ) - self.addParameter(managerParameter) - - def parameterAsSpatialRulesSet(self, parameters, name, context): - return parameters[name] - - def processAlgorithm(self, parameters, context, feedback): - """ - Here is where the processing itself takes place. - """ - rulesDict = self.parameterAsSpatialRulesSet(parameters, self.RULES_SET, context) - - return {} - - def name(self): - """ - Returns the algorithm name, used for identifying the algorithm. This - string should be fixed for the algorithm, and must not be localised. - The name should be unique within each provider. Names should contain - lowercase alphanumeric characters only and no spaces or other - formatting characters. - """ - return "spatialruleschecker" - - def displayName(self): - """ - Returns the translated algorithm name, which should be used for any - user-visible display of the algorithm name. - """ - return self.tr("Spatial Rules Checker") - - def group(self): - """ - Returns the name of the group this algorithm belongs to. This string - should be localised. - """ - return self.tr("QA Tools: Identification") - - def groupId(self): - """ - Returns the unique ID of the group this algorithm belongs to. This - string should be fixed for the algorithm, and must not be localised. - The group id should be unique within each provider. Group id should - contain lowercase alphanumeric characters only and no spaces or other - formatting characters. - """ - return "DSGTools - QA Tools: Identification" - - def tr(self, string): - return QCoreApplication.translate("RunRemoteFMEAlgorithm", string) - - def createInstance(self): - return RunRemoteFMEAlgorithm() - - -class ParameterSpatialRulesSetType(QgsProcessingParameterType): - def __init__(self): - super().__init__() - - def create(self, name): - return ParameterSpatialRulesSet(name) - - def metadata(self): - return { - "widget_wrapper": "DsgTools.gui.ProcessingUI.spatialRulesSetWrapper.SpatialRulesSetWrapper" - } - - def name(self): - return QCoreApplication.translate("Processing", "Spatial Rules Set") - - def id(self): - return "spatial_rules_set_type" - - def description(self): - return QCoreApplication.translate( - "Processing", "Set of spatial rules. Used on Spatial Rules Checker." - ) - - -class ParameterSpatialRulesSet(QgsProcessingParameterDefinition): - def __init__(self, name, description=""): - super().__init__(name, description) - - def clone(self): - copy = ParameterSpatialRulesSet(self.name(), self.description()) - return copy - - def type(self): - return self.typeName() - - @staticmethod - def typeName(): - return "spatial_rules_set" - - def checkValueIsAcceptable(self, value, context=None): - return True - - def valueAsPythonString(self, value, context): - return str(value) - - def asScriptCode(self): - raise NotImplementedError() - - @classmethod - def fromScriptCode(cls, name, description, isOptional, definition): - raise NotImplementedError() diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/streamOrder.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/streamOrder.py index 47ac56e0c..b8b8f5d21 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/streamOrder.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/streamOrder.py @@ -160,7 +160,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("QA Tools: Drainage Network Processes") + return self.tr("QA Tools: Drainage Flow Processes") def groupId(self): """ @@ -170,7 +170,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools - QA Tools: Drainage Network Processes" + return "DSGTools - QA Tools: Drainage Flow Processes" def shortHelpString(self): return self.tr( diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/verifyAdjacentGeographicBoundaryDataAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/verifyAdjacentGeographicBoundaryDataAlgorithm.py index b414e7006..41c18358e 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/verifyAdjacentGeographicBoundaryDataAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/verifyAdjacentGeographicBoundaryDataAlgorithm.py @@ -647,7 +647,7 @@ def group(self): Returns the name of the group this algorithm belongs to. This string should be localised. """ - return self.tr("QA Tools: Identification") + return self.tr("QA Tools: Dataset Processes") def groupId(self): """ @@ -657,7 +657,7 @@ def groupId(self): contain lowercase alphanumeric characters only and no spaces or other formatting characters. """ - return "DSGTools - QA Tools: Identification" + return "DSGTools - QA Tools: Dataset Processes" def tr(self, string): return QCoreApplication.translate( From 49f2d1b156dcc902d9b8e2ffb14bc205f9fd5922 Mon Sep 17 00:00:00 2001 From: Pedro Martins Date: Tue, 3 Oct 2023 17:08:01 -0300 Subject: [PATCH 08/53] =?UTF-8?q?Vers=C3=A3o=204.11.19:=20bug=20fix=20no?= =?UTF-8?q?=20VerifyAdjacentGeographicBoundaryDataAlgorithm?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 ++- .../verifyAdjacentGeographicBoundaryDataAlgorithm.py | 2 ++ DsgTools/metadata.txt | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index fcd46fbb3..5d84a327f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.18 - dev +## 4.11.19 - dev Novas Funcionalidades: @@ -31,6 +31,7 @@ Correção de bug: - Corrige bug na geração de moldura relativo a camada (Generate Systematic Grid Related to Layer) quando se usa memory layer (o memory layer não atualiza seu extent automaticamente, logo foi necessário colocar um layer.updateExtents() no código antes de calcular o extent); - Corrige bug no processo de calcular azimute (estava sendo calculado com +90 graus); - Corrige bug no ClipAndCopyFeaturesBetweenDatabasesAlgorithm; +- Corrige bug no VerifyAdjacentGeographicBoundaryDataAlgorithm (verifica interseção na moldura, não apenas no boundingbox); ## 4.10.1 - 2023-10-02 diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/verifyAdjacentGeographicBoundaryDataAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/verifyAdjacentGeographicBoundaryDataAlgorithm.py index 41c18358e..e484a1d1e 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/verifyAdjacentGeographicBoundaryDataAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/verifyAdjacentGeographicBoundaryDataAlgorithm.py @@ -567,6 +567,8 @@ def verticesInFrame( bboxlineBuffFrame = lineBuffFrame.boundingBox() for vertId in specifVertSpatialIdx.intersects(bboxlineBuffFrame): geomVert = specifVertFeatDict[vertId].geometry() + if not geomVert.intersects(lineBuffFrame): + continue vertWkt = geomVert.asWkt() dictVertInFrame[vertWkt].append(specifVertFeatDict[vertId]) diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index c89ee1335..1e3d761a0 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.18 +version=4.11.19 author=Brazilian Army Geographic Service email=suporte.dsgtools@dsg.eb.mil.br about= From fe64471b96639f9f6b1b68a27fd74ba1c4861564 Mon Sep 17 00:00:00 2001 From: phborba Date: Tue, 3 Oct 2023 20:13:39 -0300 Subject: [PATCH 09/53] =?UTF-8?q?Vers=C3=A3o=204.11.20:=20bug=20fixes=20na?= =?UTF-8?q?=20extra=C3=A7=C3=A3o=20de=20pontos=20cotados?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 +- .../GeometricAlgs/extractElevationPoints.py | 197 ++++++++++++------ .../GeometricTools/spatialRelationsHandler.py | 104 ++++++++- DsgTools/metadata.txt | 2 +- 4 files changed, 235 insertions(+), 71 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5d84a327f..308ab9ca9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.19 - dev +## 4.11.20 - dev Novas Funcionalidades: @@ -32,6 +32,7 @@ Correção de bug: - Corrige bug no processo de calcular azimute (estava sendo calculado com +90 graus); - Corrige bug no ClipAndCopyFeaturesBetweenDatabasesAlgorithm; - Corrige bug no VerifyAdjacentGeographicBoundaryDataAlgorithm (verifica interseção na moldura, não apenas no boundingbox); +- Corrige bug na rotina de extrair automaticamente pontos cotados (Extract Spot Elevation); ## 4.10.1 - 2023-10-02 diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py index 7bcd44e86..98812a731 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py @@ -55,6 +55,9 @@ QgsVectorLayerUtils, QgsProcessingParameterVectorLayer, QgsSpatialIndex, + QgsProject, + QgsProcessingParameterExpression, + QgsProcessingParameterBoolean, ) @@ -69,10 +72,12 @@ class ExtractElevationPoints(QgsProcessingAlgorithm): WATER_BODIES = "WATER_BODIES" AREA_WITHOUT_INFORMATION_POLYGONS = "AREA_WITHOUT_INFORMATION_POLYGONS" NATURAL_POINT_FEATURES = "NATURAL_POINT_FEATURES" - DRAINAGE_LINES_WITH_NAME = "DRAINAGE_LINES_WITH_NAME" - DRAINAGE_LINES_WITHOUT_NAME = "DRAINAGE_LINES_WITHOUT_NAME" - MAIN_ROADS = "MAIN_ROADS" - OTHER_ROADS = "OTHER_ROADS" + DRAINAGE_LINES = "DRAINAGE_LINES" + DRAINAGE_LINES_NAME_ATTRIBUTE = "DRAINAGE_LINES_NAME_ATTRIBUTE" + CONSIDER_DRAINAGES_WITHOUT_NAMES = "CONSIDER_DRAINAGES_WITHOUT_NAMES" + ROADS = "ROADS" + MAIN_ROADS_EXPRESSION = "MAIN_ROADS_EXPRESSION" + OTHER_ROADS_EXPRESSION = "OTHER_ROADS_EXPRESSION" OUTPUT = "OUTPUT" def initAlgorithm(self, config=None): @@ -87,6 +92,7 @@ def initAlgorithm(self, config=None): self.CONTOUR_LINES, self.tr("Contour Lines"), [QgsProcessing.TypeVectorLine], + defaultValue="elemnat_curva_nivel_l", ) ) @@ -94,7 +100,7 @@ def initAlgorithm(self, config=None): QgsProcessingParameterField( self.CONTOUR_ATTR, self.tr("Contour value field"), - None, + "cota", self.CONTOUR_LINES, QgsProcessingParameterField.Numeric, ) @@ -115,6 +121,7 @@ def initAlgorithm(self, config=None): self.tr("Geographic bounds layer"), [QgsProcessing.TypeVectorPolygon], optional=False, + defaultValue="aux_moldura_a", ) ) @@ -184,34 +191,55 @@ def initAlgorithm(self, config=None): self.addParameter( QgsProcessingParameterVectorLayer( - self.DRAINAGE_LINES_WITH_NAME, - self.tr("Drainage lines with name"), + self.DRAINAGE_LINES, + self.tr("Drainage lines"), [QgsProcessing.TypeVectorLine], + defaultValue="elemnat_trecho_drenagem_l", ) ) self.addParameter( - QgsProcessingParameterVectorLayer( - self.DRAINAGE_LINES_WITHOUT_NAME, - self.tr("Drainage lines without name"), - [QgsProcessing.TypeVectorLine], - optional=True, + QgsProcessingParameterField( + self.DRAINAGE_LINES_NAME_ATTRIBUTE, + self.tr("Drainage name field"), + "nome", + self.DRAINAGE_LINES, + QgsProcessingParameterField.String, ) ) self.addParameter( - QgsProcessingParameterVectorLayer( - self.MAIN_ROADS, - self.tr("Main Roads"), - [QgsProcessing.TypeVectorLine], + QgsProcessingParameterBoolean( + self.CONSIDER_DRAINAGES_WITHOUT_NAMES, + self.tr("Consider drainages without names"), + defaultValue=True, ) ) self.addParameter( QgsProcessingParameterVectorLayer( - self.OTHER_ROADS, - self.tr("Other Roads"), + self.ROADS, + self.tr("Roads"), [QgsProcessing.TypeVectorLine], + defaultValue="infra_via_deslocamento_l", + ) + ) + + self.addParameter( + QgsProcessingParameterExpression( + self.MAIN_ROADS_EXPRESSION, + self.tr("Filter expression for main roads"), + '''"tipo" = 4 or "jurisdicao" in (1,2)''', + self.ROADS, + ) + ) + + self.addParameter( + QgsProcessingParameterExpression( + self.OTHER_ROADS_EXPRESSION, + self.tr("Filter expression for other roads"), + '''"tipo" in (2,4)''', + self.ROADS, optional=True, ) ) @@ -221,6 +249,7 @@ def initAlgorithm(self, config=None): ) def processAlgorithm(self, parameters, context, feedback): + algRunner = AlgRunner() inputRaster = self.parameterAsRasterLayer(parameters, self.INPUT_DEM, context) contourLyr = self.parameterAsVectorLayer(parameters, self.CONTOUR_LINES, context) heightFieldName = self.parameterAsFields( @@ -245,16 +274,27 @@ def processAlgorithm(self, parameters, context, feedback): naturalPointFeaturesLyr = self.parameterAsVectorLayer( parameters, self.NATURAL_POINT_FEATURES, context ) - drainagesWithNameLyr = self.parameterAsVectorLayer( - parameters, self.DRAINAGE_LINES_WITH_NAME, context + drainagesLyr = self.parameterAsVectorLayer( + parameters, self.DRAINAGE_LINES, context ) - drainagesWithoutNameLyr = self.parameterAsVectorLayer( - parameters, self.DRAINAGE_LINES_WITHOUT_NAME, context + drainageNameAttribute = self.parameterAsFields( + parameters, self.DRAINAGE_LINES_NAME_ATTRIBUTE, context + )[0] + getDrainagesWithoutName = self.parameterAsBool( + parameters, self.CONSIDER_DRAINAGES_WITHOUT_NAMES, context ) - mainRoadsLyr = self.parameterAsVectorLayer(parameters, self.MAIN_ROADS, context) - otherRoadsLyr = self.parameterAsVectorLayer( - parameters, self.OTHER_ROADS, context + + roadsLyr = self.parameterAsVectorLayer( + parameters, self.ROADS, context ) + mainRoadsFilterExpression = self.parameterAsExpression(parameters, self.MAIN_ROADS_EXPRESSION, context) + if mainRoadsFilterExpression == '': + mainRoadsFilterExpression = None + + otherRoadsFilterExpression = self.parameterAsExpression(parameters, self.OTHER_ROADS_EXPRESSION, context) + if otherRoadsFilterExpression == '': + otherRoadsFilterExpression = None + self.bufferDist = self.distances[scale] self.minContourLength = self.minContourLenghts[scale] self.gridSpacing = self.gridSpacingDict[scale] @@ -286,8 +326,58 @@ def processAlgorithm(self, parameters, context, feedback): ) layerHandler = LayerHandler() nFeats = geoBoundsLyr.featureCount() - multiStepFeedback = QgsProcessingMultiStepFeedback(nFeats, feedback) - for currentStep, feat in enumerate(geoBoundsLyr.getFeatures()): + nSteps = nFeats + 4 + 2 * (otherRoadsFilterExpression is not None) + 2 * getDrainagesWithoutName + multiStepFeedback = QgsProcessingMultiStepFeedback(nSteps, feedback) + currentStep = 0 + + multiStepFeedback.setCurrentStep(currentStep) + multiStepFeedback.pushInfo(self.tr("Getting roads")) + mainRoadsLyr = algRunner.runFilterExpression( + inputLyr=roadsLyr, expression=mainRoadsFilterExpression, context=context, feedback=multiStepFeedback + ) if mainRoadsFilterExpression is not None else roadsLyr + currentStep += 1 + + multiStepFeedback.setCurrentStep(currentStep) + algRunner.runCreateSpatialIndex(mainRoadsLyr, context, multiStepFeedback, is_child_algorithm=True) + currentStep += 1 + + if otherRoadsFilterExpression is not None: + multiStepFeedback.setCurrentStep(currentStep) + otherRoadsLyr = algRunner.runFilterExpression( + inputLyr=roadsLyr, expression=otherRoadsFilterExpression, context=context, feedback=multiStepFeedback + ) + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + algRunner.runCreateSpatialIndex(otherRoadsLyr, context, multiStepFeedback, is_child_algorithm=True) + currentStep += 1 + else: + otherRoadsLyr = None + + multiStepFeedback.pushInfo(self.tr("Getting drainages")) + multiStepFeedback.setCurrentStep(currentStep) + drainagesWithNameLyr = algRunner.runFilterExpression( + inputLyr=drainagesLyr, expression=f'"{drainageNameAttribute}" is not NULL', context=context, feedback=multiStepFeedback + ) + currentStep += 1 + + multiStepFeedback.setCurrentStep(currentStep) + algRunner.runCreateSpatialIndex(drainagesWithNameLyr, context, multiStepFeedback, is_child_algorithm=True) + currentStep += 1 + + if getDrainagesWithoutName: + multiStepFeedback.setCurrentStep(currentStep) + drainagesWithoutNameLyr = algRunner.runFilterExpression( + inputLyr=drainagesLyr, expression=f'"{drainageNameAttribute}" is NULL', context=context, feedback=multiStepFeedback + ) + currentStep += 1 + + multiStepFeedback.setCurrentStep(currentStep) + algRunner.runCreateSpatialIndex(drainagesWithoutNameLyr, context, multiStepFeedback, is_child_algorithm=True) + currentStep += 1 + else: + drainagesWithoutNameLyr = None + + for currentStep, feat in enumerate(geoBoundsLyr.getFeatures(), currentStep): if multiStepFeedback.isCanceled(): break multiStepFeedback.setCurrentStep(currentStep) @@ -348,7 +438,7 @@ def computePoints( ): algRunner = AlgRunner() layerHandler = LayerHandler() - nSteps = 18 + ( + nSteps = 17 + ( naturalPointFeaturesLyr is not None ) + 3 * (waterBodiesLyr is not None) # handle this count after alg is done multiStepFeedback = ( @@ -426,7 +516,7 @@ def computePoints( multiStepFeedback.setCurrentStep(currentStep) multiStepFeedback.setProgressText(self.tr(f"{self.currentStepText}:Evaluating buffer on water bodies...")) localBufferedWaterBodiesLyr = algRunner.runBuffer( - inputLayer=localWaterBodiesLyr, distance=localContourBufferLength, context=context, feedback=multiStepFeedback, is_child_algorithm=True + inputLayer=localWaterBodiesLyr, distance=2*localContourBufferLength, context=context, feedback=multiStepFeedback, is_child_algorithm=True ) if multiStepFeedback is not None: currentStep += 1 @@ -487,6 +577,7 @@ def computePoints( context, feedback=multiStepFeedback, ) + # QgsProject.instance().addMapLayer(exclusionLyr) if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) @@ -498,6 +589,7 @@ def computePoints( context=context, feedback=multiStepFeedback, ) + # QgsProject.instance().addMapLayer(polygonLyr) if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) @@ -796,40 +888,6 @@ def computePoints( ) ) - elevationPointsFromIntersectionsOfRiversWithNames = ( - self.getElevationPointsFromLineIntersections( - lineLyr1=drainagesWithNameLyr, - lineLyr2=drainagesWithNameLyr, - geographicBoundsLyr=minusBufferedGeographicBoundsLyr, - npRaster=npRaster, - transform=transform, - polygonLyr=polygonLyr, - bufferDistance=localBufferDistance, - exclusionLyr=exclusionLyr, - contourAreaDict=contourAreaDict, - contourHeightInterval=contourHeightInterval, - gridLyr=gridLyr, - gridDict=gridDict, - maxPointsPerGridUnit=maxPointsPerGridUnit, - fields=fields, - context=context, - feedback=multiStepFeedback, - ) - ) - self.updateExclusionLyr( - exclusionLyr, - elevationPointsFromIntersectionsOfRiversWithNames, - distance=localBufferDistance, - context=context, - ) - self.addPointsToMemoryLayer( - elevationPointsLayer, - elevationPointsFromIntersectionsOfRiversWithNames, - context, - ) - if elevationPointsLayer.featureCount() > maxNPoints: - return elevationPointsLayer.getFeatures() - if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) @@ -1174,6 +1232,7 @@ def buildGrid( context=context, feedback=multiStepFeedback, ) + # QgsProject.instance().addMapLayer(gridLyr) if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) @@ -1356,7 +1415,6 @@ def getElevationPointsFromLineIntersections( inputLayer=lineIntersectionPointsLyr, distance=1e-5, context=context, - is_child_algorithm=True, ) if multiStepFeedback is not None: currentStep += 1 @@ -1367,12 +1425,14 @@ def getElevationPointsFromLineIntersections( feedback=multiStepFeedback, is_child_algorithm=True, ) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) extractedLines1 = algRunner.runExtractByLocation( inputLyr=localLineLyr1, intersectLyr=intersectionBuffers, context=context, feedback=multiStepFeedback, - is_child_algorithm=True, ) if multiStepFeedback is not None: currentStep += 1 @@ -1388,7 +1448,6 @@ def getElevationPointsFromLineIntersections( intersectLyr=intersectionBuffers, context=context, feedback=multiStepFeedback, - is_child_algorithm=True, ) if multiStepFeedback is not None: currentStep += 1 @@ -1420,6 +1479,7 @@ def getElevationPointsFromLineIntersections( if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) + # QgsProject.instance().addMapLayer(intersectedLines) filteredPointsIntersections = self.keepThirdOrderOrHigherPoints( points=lineIntersectionPointsLyr, linesLyr=intersectedLines, @@ -1784,6 +1844,8 @@ def getElevationPointsFromHilltops( context=context, feedback=multiStepFeedback, ) + # hillTopsLyr.setName('hilltops') + # QgsProject.instance().addMapLayer(hillTopsLyr) if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) @@ -1835,6 +1897,7 @@ def extractElevationPointsFromHilltops( multiStepFeedback.pushInfo(self.tr("Finding hilltops...")) hillTopsLyr = spatialRelationsHandler.createHilltopLayerFromPolygonLayer( polygonLayer=polygonLayer, + geographicBoundsLyr=geographicBoundsLyr, context=context, feedback=multiStepFeedback, computeOrder=True, @@ -1866,7 +1929,7 @@ def extractElevationPointsFromHilltops( multiStepFeedback.setCurrentStep(currentStep) nFeats = hillTopsLyr.featureCount() if nFeats == 0: - return [] + return [], hillTopsLyr stepSize = 100 / nFeats featList = [] minArea = minContourLength**2 / (4 * math.pi) diff --git a/DsgTools/core/GeometricTools/spatialRelationsHandler.py b/DsgTools/core/GeometricTools/spatialRelationsHandler.py index fd04ef414..91415deac 100644 --- a/DsgTools/core/GeometricTools/spatialRelationsHandler.py +++ b/DsgTools/core/GeometricTools/spatialRelationsHandler.py @@ -351,11 +351,12 @@ def buildTerrainPolygonLayerFromContours( def createHilltopLayerFromPolygonLayer( self, polygonLayer: QgsVectorLayer, + geographicBoundsLyr: QgsVectorLayer, context: QgsProcessingContext, feedback: QgsProcessingFeedback = None, computeOrder: bool = False, ) -> QgsVectorLayer: - nSteps = 4 if not computeOrder else 7 + nSteps = 13 if not computeOrder else 16 multiStepFeedback = ( QgsProcessingMultiStepFeedback(nSteps, feedback) if feedback is not None @@ -421,7 +422,106 @@ def createHilltopLayerFromPolygonLayer( context=context, feedback=multiStepFeedback ) - return hilltopsWithOrder + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + hilltopsWithOrder = self.algRunner.runCreateFieldWithExpression( + inputLyr=hilltopsWithOrder, + expression="$id", + fieldType=1, + fieldName="hfid", + feedback=multiStepFeedback, + context=context, + ) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + self.algRunner.runCreateSpatialIndex( + inputLyr=hilltopsWithOrder, + context=context, + feedback=multiStepFeedback, + is_child_algorithm=True + ) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + geographicBoundsLineLyr = self.algRunner.runPolygonsToLines( + inputLyr=geographicBoundsLyr, + context=context, + feedback=multiStepFeedback, + ) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + geographicBoundsLineLyr = self.algRunner.runExplodeLines( + geographicBoundsLineLyr, + context=context, + feedback=multiStepFeedback + ) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + self.algRunner.runAddUnsharedVertexOnSharedEdges( + inputLinesList=[geographicBoundsLineLyr], + inputPolygonsList=[hilltopsWithOrder], + searchRadius=1e-5 if geographicBoundsLyr.crs().isGeographic() else 1e-2, + context=context, + feedback=multiStepFeedback + ) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + intersectedLines = self.algRunner.runIntersection( + inputLyr=geographicBoundsLineLyr, + overlayLyr=hilltopsWithOrder, + context=context, + feedback=multiStepFeedback, + ) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + singleParts = self.algRunner.runMultipartToSingleParts( + inputLayer=intersectedLines, + context=context, + feedback=multiStepFeedback + ) + nFeats = singleParts.featureCount() + if nFeats == 0: + return hilltopsWithOrder + groupDict = defaultdict(set) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + stepSize = 100/nFeats + for current, feat in enumerate(singleParts.getFeatures()): + if multiStepFeedback is not None and multiStepFeedback.isCanceled(): + return hilltopsWithOrder + groupDict[feat['hfid']].add(feat) + if multiStepFeedback is not None: + multiStepFeedback.setProgress(current * stepSize) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + stepSize = 100/len(groupDict) + idsToIgnoreSet = set() + for current, (featId, featSet) in enumerate(groupDict.items()): + if multiStepFeedback is not None and multiStepFeedback.isCanceled(): + return hilltopsWithOrder + if len(featSet) <= 1: + continue + idsToIgnoreSet.add(featId) + if multiStepFeedback is not None: + multiStepFeedback.setProgress(current * stepSize) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + outputHilltopWithOrder = self.algRunner.runFilterExpression( + inputLyr=hilltopsWithOrder, + context=context, + expression=f"hfid not in {tuple(idsToIgnoreSet)}".replace(",)", ")"), + feedback=multiStepFeedback, + ) if len(idsToIgnoreSet) > 0 else hilltopsWithOrder + return outputHilltopWithOrder def populateContourAreaDict( diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 1e3d761a0..c4457fc4e 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.19 +version=4.11.20 author=Brazilian Army Geographic Service email=suporte.dsgtools@dsg.eb.mil.br about= From f1db90f91edc13758907cadc99288a8f308f3f47 Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 4 Oct 2023 11:45:29 -0300 Subject: [PATCH 10/53] about update --- DsgTools/gui/AboutAndFurtherInfo/ui_about.ui | 203 +++++++++---------- DsgTools/metadata.txt | 4 +- 2 files changed, 103 insertions(+), 104 deletions(-) diff --git a/DsgTools/gui/AboutAndFurtherInfo/ui_about.ui b/DsgTools/gui/AboutAndFurtherInfo/ui_about.ui index caa2cd25f..e2583d912 100644 --- a/DsgTools/gui/AboutAndFurtherInfo/ui_about.ui +++ b/DsgTools/gui/AboutAndFurtherInfo/ui_about.ui @@ -6,7 +6,7 @@ 0 0 - 870 + 920 360 @@ -18,122 +18,121 @@ - 870 + 900 360 - 870 + 920 360 About - - - - 670 - 320 - 160 - 25 - - - - Qt::Horizontal - - - QDialogButtonBox::Cancel|QDialogButtonBox::Ok - - - - - - 550 - 20 - 331 - 271 - - - - - 0 - 0 - - - - - - - :/plugins/DsgTools/icons/DSGTools.png - - - true - - - - - - 9 - 9 - 221 - 291 - - - - - 0 - 0 - - - - - - - :/plugins/DsgTools/icons/eb.jpg - - - true - - - - - true - - - - 250 - 10 - 341 - 291 - - - - - 0 - 0 - - - - QFrame::NoFrame - - - QFrame::Sunken - - - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> + + + + + Qt::Horizontal + + + QDialogButtonBox::Cancel|QDialogButtonBox::Ok + + + + + + + + + + 0 + 0 + + + + + 221 + 291 + + + + + + + :/plugins/DsgTools/icons/eb.jpg + + + true + + + + + + + true + + + + 0 + 0 + + + + + 16777215 + 291 + + + + QFrame::NoFrame + + + QFrame::Sunken + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } </style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:14pt; font-weight:600;">Brazilian Army</span></p> -<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:14pt; font-weight:600;">Geographic Service Bureau</span></p> -<p align="center" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:14pt; font-weight:600;"><br /></p> -<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:14pt; font-weight:600;">This plugin was developed in accordance with the Technical Specifications of Brazilian National Spatial Data Infrastructure.</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:14pt; font-weight:600;">This plugin was developed by the Brazilian Army Geographic Service in accordance with the Technical Specifications of Brazilian National Spatial Data Infrastructure.</span></p> <p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:14pt; font-weight:600;"><br /></p> -<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:14pt; font-weight:600;">Version: ${version}</span></p></body></html> - - +<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:14pt; font-weight:600;">Plugin Version: ${version}</span></p> +<p align="center" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:14pt; font-weight:600;"><br /></p> +<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:14pt; font-weight:600;">For suggestions and feedback, feel free to contact us at dsgtools@dsg.eb.mil.br</span></p></body></html> + + + + + + + + 0 + 0 + + + + + 331 + 271 + + + + + + + :/plugins/DsgTools/icons/DSGTools.png + + + true + + + + + + diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index c4457fc4e..35feba2b0 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -12,12 +12,12 @@ qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools version=4.11.20 author=Brazilian Army Geographic Service -email=suporte.dsgtools@dsg.eb.mil.br +email=dsgtools@dsg.eb.mil.br about= DSGTools with the following features: -Creation, Storage and Deletion of PostGIS servers configurations -Database creation using Spatialite and PostGIS according to EDGV version 2.1.3 and 3.0 (cadaster) - -Layer loading by category and class as defined by EDGV version 2.1.3 and EDGV version FTer_2a_Ed (cadaster) + -Layer loading by category and class as defined by EDGV version 2.1.3 and EDGV version 3.0 (cadaster) -Manipulation of complex features (Creation, Editing, Deletion, Zoom, Association, Disassociation) and -Access to some WM(T)S services provided by BDGEx. -Inventory Tool for all geospatial data supported by GDAL/OGR. From 2125b8cbaf3d5278e01ab74d4df856f86d70d53a Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 4 Oct 2023 11:52:28 -0300 Subject: [PATCH 11/53] fix --- DsgTools/gui/AboutAndFurtherInfo/ui_about.ui | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DsgTools/gui/AboutAndFurtherInfo/ui_about.ui b/DsgTools/gui/AboutAndFurtherInfo/ui_about.ui index e2583d912..738004443 100644 --- a/DsgTools/gui/AboutAndFurtherInfo/ui_about.ui +++ b/DsgTools/gui/AboutAndFurtherInfo/ui_about.ui @@ -97,7 +97,7 @@ <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } </style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:14pt; font-weight:600;">This plugin was developed by the Brazilian Army Geographic Service in accordance with the Technical Specifications of Brazilian National Spatial Data Infrastructure.</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:14pt; font-weight:600;">This plugin was developed by the Brazilian Army Geographic Service according to the Technical Specifications of Brazilian National Spatial Data Infrastructure.</span></p> <p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:14pt; font-weight:600;"><br /></p> <p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:14pt; font-weight:600;">Plugin Version: ${version}</span></p> <p align="center" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:14pt; font-weight:600;"><br /></p> From e0b09e982d972bfc3c8ee88ec5f5d96cc3829510 Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 4 Oct 2023 17:33:50 -0300 Subject: [PATCH 12/53] bug fixes --- .../GeometricAlgs/extractElevationPoints.py | 149 +++++++++++------- .../core/DSGToolsProcessingAlgs/algRunner.py | 8 +- DsgTools/core/GeometricTools/rasterHandler.py | 19 ++- 3 files changed, 111 insertions(+), 65 deletions(-) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py index 98812a731..0df90a4d8 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py @@ -333,7 +333,7 @@ def processAlgorithm(self, parameters, context, feedback): multiStepFeedback.setCurrentStep(currentStep) multiStepFeedback.pushInfo(self.tr("Getting roads")) mainRoadsLyr = algRunner.runFilterExpression( - inputLyr=roadsLyr, expression=mainRoadsFilterExpression, context=context, feedback=multiStepFeedback + inputLyr=roadsLyr, expression=mainRoadsFilterExpression, context=context, feedback=multiStepFeedback, is_child_algorithm=True, ) if mainRoadsFilterExpression is not None else roadsLyr currentStep += 1 @@ -344,7 +344,7 @@ def processAlgorithm(self, parameters, context, feedback): if otherRoadsFilterExpression is not None: multiStepFeedback.setCurrentStep(currentStep) otherRoadsLyr = algRunner.runFilterExpression( - inputLyr=roadsLyr, expression=otherRoadsFilterExpression, context=context, feedback=multiStepFeedback + inputLyr=roadsLyr, expression=otherRoadsFilterExpression, context=context, feedback=multiStepFeedback, is_child_algorithm=True, ) currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) @@ -356,7 +356,7 @@ def processAlgorithm(self, parameters, context, feedback): multiStepFeedback.pushInfo(self.tr("Getting drainages")) multiStepFeedback.setCurrentStep(currentStep) drainagesWithNameLyr = algRunner.runFilterExpression( - inputLyr=drainagesLyr, expression=f'"{drainageNameAttribute}" is not NULL', context=context, feedback=multiStepFeedback + inputLyr=drainagesLyr, expression=f'"{drainageNameAttribute}" is not NULL', context=context, feedback=multiStepFeedback, is_child_algorithm=True, ) currentStep += 1 @@ -367,7 +367,7 @@ def processAlgorithm(self, parameters, context, feedback): if getDrainagesWithoutName: multiStepFeedback.setCurrentStep(currentStep) drainagesWithoutNameLyr = algRunner.runFilterExpression( - inputLyr=drainagesLyr, expression=f'"{drainageNameAttribute}" is NULL', context=context, feedback=multiStepFeedback + inputLyr=drainagesLyr, expression=f'"{drainageNameAttribute}" is NULL', context=context, feedback=multiStepFeedback, is_child_algorithm=True, ) currentStep += 1 @@ -377,11 +377,11 @@ def processAlgorithm(self, parameters, context, feedback): else: drainagesWithoutNameLyr = None - for currentStep, feat in enumerate(geoBoundsLyr.getFeatures(), currentStep): + for currentStepInsideLoop, feat in enumerate(geoBoundsLyr.getFeatures(), currentStep): if multiStepFeedback.isCanceled(): break - multiStepFeedback.setCurrentStep(currentStep) - self.currentStepText = self.tr(f"Evaluating region {currentStep+1}/{nFeats}") + multiStepFeedback.setCurrentStep(currentStepInsideLoop) + self.currentStepText = self.tr(f"Evaluating region {currentStepInsideLoop-currentStep+1}/{nFeats}") multiStepFeedback.pushInfo(self.currentStepText) localBoundsLyr = layerHandler.createMemoryLayerWithFeature( geographicBoundaryLyr, feat, context @@ -494,7 +494,7 @@ def computePoints( ) contourBufferLyr = algRunner.runBuffer( inputLayer=contourLyr, - distance=localContourBufferLength, + distance=localContourBufferLength/4, context=context, feedback=multiStepFeedback, ) @@ -516,7 +516,7 @@ def computePoints( multiStepFeedback.setCurrentStep(currentStep) multiStepFeedback.setProgressText(self.tr(f"{self.currentStepText}:Evaluating buffer on water bodies...")) localBufferedWaterBodiesLyr = algRunner.runBuffer( - inputLayer=localWaterBodiesLyr, distance=2*localContourBufferLength, context=context, feedback=multiStepFeedback, is_child_algorithm=True + inputLayer=localWaterBodiesLyr, distance=localContourBufferLength, context=context, feedback=multiStepFeedback, is_child_algorithm=True ) if multiStepFeedback is not None: currentStep += 1 @@ -533,7 +533,7 @@ def computePoints( currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) multiStepFeedback.setProgressText(self.tr(f"{self.currentStepText}: Building masked raster...")) - npRaster, transform = self.readAndMaskRaster( + npRaster, transform, maskLyr = self.readAndMaskRaster( clippedRasterLyr, geographicBoundsLyr, areaWithoutInformationLyr, @@ -551,7 +551,7 @@ def computePoints( self.tr("Getting max min feats...") ) minMaxFeats = self.getMinMaxFeatures( - fields, npRaster, transform, distance=localBufferDistance, feedback=multiStepFeedback, + fields, npRaster, transform, distance=localBufferDistance, maskLyr=maskLyr, feedback=multiStepFeedback, ) elevationPointsLayer = layerHandler.createMemoryLayerWithFeatures( featList=minMaxFeats, @@ -577,7 +577,6 @@ def computePoints( context, feedback=multiStepFeedback, ) - # QgsProject.instance().addMapLayer(exclusionLyr) if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) @@ -1007,6 +1006,7 @@ def computePoints( self.addPointsToMemoryLayer( elevationPointsLayer, planeAreasElevationPoints, context ) + QgsProject.instance().addMapLayer(exclusionLyr) return elevationPointsLayer.getFeatures() def readAndMaskRaster( @@ -1020,9 +1020,7 @@ def readAndMaskRaster( algRunner, feedback, ): - nSteps = ( - 3 + (areaWithoutInformationLyr is not None) + (waterBodiesLyr is not None) - ) + nSteps = 6 multiStepFeedback = ( QgsProcessingMultiStepFeedback(nSteps, feedback) if feedback is not None @@ -1036,43 +1034,26 @@ def readAndMaskRaster( if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) - if ( - areaWithoutInformationLyr is not None - and areaWithoutInformationLyr.featureCount() > 0 - ): - npRaster = self.maskFeaturesFromLayerOnRaster( - rasterLyr=clippedRasterLyr, - geographicBoundsLyr=geographicBoundsLyr, - maskLyr=areaWithoutInformationLyr, - context=context, - algRunner=algRunner, - feedback=multiStepFeedback, - npRaster=npRaster, - ) - if multiStepFeedback is not None: - currentStep += 1 - multiStepFeedback.setCurrentStep(currentStep) + layerList = list(filter(lambda x: x is not None, [areaWithoutInformationLyr, waterBodiesLyr, contourBufferLyr])) + if layerList == []: + return npRaster, transform, None + maskLyr = AlgRunner().runMergeVectorLayers( + layerList, context, feedback=multiStepFeedback + ) if len(layerList) > 1 else layerList[0] + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + maskLyr = AlgRunner().runClip(maskLyr, geographicBoundsLyr, context, feedback=multiStepFeedback) - if waterBodiesLyr is not None and waterBodiesLyr.featureCount() > 0: - npRaster = self.maskFeaturesFromLayerOnRaster( - rasterLyr=clippedRasterLyr, - geographicBoundsLyr=geographicBoundsLyr, - maskLyr=waterBodiesLyr, - context=context, - algRunner=algRunner, - feedback=multiStepFeedback, - npRaster=npRaster, - ) - if multiStepFeedback is not None: - currentStep += 1 - multiStepFeedback.setCurrentStep(currentStep) + if maskLyr.featureCount() == 0: + return npRaster if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) npRaster = self.maskFeaturesFromLayerOnRaster( rasterLyr=clippedRasterLyr, geographicBoundsLyr=geographicBoundsLyr, - maskLyr=contourBufferLyr, + maskLyr=maskLyr, context=context, algRunner=algRunner, feedback=multiStepFeedback, @@ -1081,7 +1062,7 @@ def readAndMaskRaster( nanIndexes = np.isnan(npRaster) npRaster = (np.rint(npRaster)).astype(float) npRaster[nanIndexes] = np.nan - return npRaster, transform + return npRaster, transform, maskLyr def getRangeOfNumberOfPoints(self, featList): minValue = min(featList, key=lambda x: x["cota"])["cota"] @@ -1364,7 +1345,7 @@ def getElevationPointsFromLineIntersections( return [] algRunner = AlgRunner() multiStepFeedback = ( - QgsProcessingMultiStepFeedback(14, feedback) + QgsProcessingMultiStepFeedback(17, feedback) if feedback is not None else None ) @@ -1415,6 +1396,7 @@ def getElevationPointsFromLineIntersections( inputLayer=lineIntersectionPointsLyr, distance=1e-5, context=context, + is_child_algorithm=True, ) if multiStepFeedback is not None: currentStep += 1 @@ -1433,6 +1415,7 @@ def getElevationPointsFromLineIntersections( intersectLyr=intersectionBuffers, context=context, feedback=multiStepFeedback, + is_child_algorithm=True, ) if multiStepFeedback is not None: currentStep += 1 @@ -1448,6 +1431,7 @@ def getElevationPointsFromLineIntersections( intersectLyr=intersectionBuffers, context=context, feedback=multiStepFeedback, + is_child_algorithm=True, ) if multiStepFeedback is not None: currentStep += 1 @@ -1458,15 +1442,32 @@ def getElevationPointsFromLineIntersections( feedback=multiStepFeedback, is_child_algorithm=True, ) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + merged = AlgRunner().runMergeVectorLayers( + inputList=[extractedLines1, extractedLines2], + context=context, + feedback=multiStepFeedback + ) if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) intersectedLines = AlgRunner().runSplitLinesWithLines( - inputLyr=extractedLines1, - linesLyr=extractedLines2, + inputLyr=merged, + linesLyr=merged, + context=context, + feedback=multiStepFeedback, + ) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + AlgRunner().runRemoveDuplicatedGeometries( + inputLyr=intersectedLines, context=context, feedback=multiStepFeedback, ) + intersectedLines.commitChanges() if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) @@ -1479,7 +1480,6 @@ def getElevationPointsFromLineIntersections( if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) - # QgsProject.instance().addMapLayer(intersectedLines) filteredPointsIntersections = self.keepThirdOrderOrHigherPoints( points=lineIntersectionPointsLyr, linesLyr=intersectedLines, @@ -1518,7 +1518,7 @@ def getElevationPointsFromLineIntersections( feedback=multiStepFeedback, ) - def getMinMaxFeatures(self, fields, npRaster, transform, distance, feedback=None): + def getMinMaxFeatures(self, fields, npRaster, transform, distance, maskLyr, feedback=None): featSet = set() multiStepFeedback = QgsProcessingMultiStepFeedback(4, feedback) if feedback is not None else None if multiStepFeedback is not None: @@ -1548,17 +1548,53 @@ def getMinMaxFeatures(self, fields, npRaster, transform, distance, feedback=None if multiStepFeedback is not None: multiStepFeedback.setCurrentStep(3) multiStepFeedback.pushInfo(self.tr("Creating min feature list from pixel coordinates array...")) + npRasterCopy = np.array(npRaster) minFeatList = ( rasterHandler.createFeatureListWithPixelValuesFromPixelCoordinatesArray( minCoordinatesArray, fieldName="cota", fields=fields, - npRaster=npRaster, + npRaster=npRasterCopy, transform=transform, defaultAtributeMap=dict(self.defaultAttrMap), ) ) - featSet |= self.filterFeaturesByBuffer(minFeatList, distance, feedback=multiStepFeedback) + cota = min(f['cota'] for f in minFeatList) + while True: + minFeatLyr = LayerHandler().createMemoryLayerWithFeatures( + featList=minFeatList, + fields=fields, + crs=maskLyr.crs(), + wkbType=QgsWkbTypes.Point, + context=QgsProcessingContext(), + ) + filteredFeatureList = self.filterFeaturesByDistanceAndExclusionLayer( + candidatesPointLyr=minFeatLyr, + exclusionLyr=maskLyr, + distance=distance, + context=QgsProcessingContext(), + feedback=None, + ) + if filteredFeatureList != []: + featSet |= set(filteredFeatureList) + break + npRasterCopy[npRasterCopy == cota] = np.nan + minCoordinatesArray = rasterHandler.getMinCoordinatesFromNpArray(npRasterCopy) + if minCoordinatesArray == []: + return list(featSet) + minFeatList = ( + rasterHandler.createFeatureListWithPixelValuesFromPixelCoordinatesArray( + minCoordinatesArray, + fieldName="cota", + fields=fields, + npRaster=npRasterCopy, + transform=transform, + defaultAtributeMap=dict(self.defaultAttrMap), + ) + ) + cota += 1 + if multiStepFeedback is not None and multiStepFeedback.isCanceled(): + break return list(featSet) def filterWithAllCriteria( @@ -1680,7 +1716,7 @@ def filterFeaturesByDistanceAndExclusionLayer( disjointLyr = AlgRunner().runExtractByLocation( candidatesPointLyr, exclusionLyr, - predicate=[2], + predicate=[AlgRunner.Disjoint], context=context, feedback=multiStepFeedback, ) @@ -1696,7 +1732,8 @@ def filterFeaturesByDistanceAndExclusionLayer( if multiStepFeedback is not None and multiStepFeedback.isCanceled(): break if feat.id() in exclusionSet: - multiStepFeedback.setProgress(current * stepSize) + if multiStepFeedback is not None: + multiStepFeedback.setProgress(current * stepSize) continue outputSet.add(feat) geom = feat.geometry() @@ -2018,7 +2055,7 @@ def keepThirdOrderOrHigherPoints( for _ in ( i for i in linesLyr.getFeatures(bbox) - if i.geometry().intersects(geom) + if i.geometry().intersects(buffer) ) ) if nFeats < 3: diff --git a/DsgTools/core/DSGToolsProcessingAlgs/algRunner.py b/DsgTools/core/DSGToolsProcessingAlgs/algRunner.py index ce2d3dce7..7f96d26a0 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/algRunner.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/algRunner.py @@ -660,12 +660,16 @@ def runIntersection( return output["OUTPUT"] def runFilterExpression( - self, inputLyr, expression, context, outputLyr=None, feedback=None + self, inputLyr, expression, context, outputLyr=None, feedback=None, is_child_algorithm=False, ): outputLyr = "memory:" if outputLyr is None else outputLyr parameters = {"EXPRESSION": expression, "INPUT": inputLyr, "OUTPUT": outputLyr} output = processing.run( - "native:extractbyexpression", parameters, context=context, feedback=feedback + "native:extractbyexpression", + parameters, + context=context, + feedback=feedback, + is_child_algorithm=is_child_algorithm, ) return output["OUTPUT"] diff --git a/DsgTools/core/GeometricTools/rasterHandler.py b/DsgTools/core/GeometricTools/rasterHandler.py index 326f8f704..b110167eb 100644 --- a/DsgTools/core/GeometricTools/rasterHandler.py +++ b/DsgTools/core/GeometricTools/rasterHandler.py @@ -79,7 +79,10 @@ def createFeatureWithPixelValueFromPixelCoordinates( newFeat = QgsFeature(fields) terrainCoordinates = transform * pixelCoordinates newFeat.setGeometry(QgsGeometry(QgsPoint(*terrainCoordinates))) - newFeat[fieldName] = int(npRaster[pixelCoordinates]) + value = npRaster[pixelCoordinates] + if np.isnan(value): + return None + newFeat[fieldName] = int(value) if defaultAtributeMap is None: return newFeat for attr, value in defaultAtributeMap.items(): @@ -95,13 +98,15 @@ def createFeatureListWithPixelValuesFromPixelCoordinatesArray( transform: Affine, defaultAtributeMap: Dict = None, ) -> List[QgsFeature]: - return [ - createFeatureWithPixelValueFromPixelCoordinates( - tuple(coords), fieldName, fields, npRaster, transform, defaultAtributeMap=defaultAtributeMap + return list( + filter( + lambda x: x is not None, ( + createFeatureWithPixelValueFromPixelCoordinates( + tuple(coords), fieldName, fields, npRaster, transform, defaultAtributeMap=defaultAtributeMap + ) for coords in pixelCoordinates + ) ) - for coords in pixelCoordinates - ] - + ) def createFeatureListWithPointList( pointList: List[QgsPoint], From b64fae859e52892a1d1e3564f78599850fd35611 Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 4 Oct 2023 17:34:42 -0300 Subject: [PATCH 13/53] fix --- .../Algs/GeometricAlgs/extractElevationPoints.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py index 0df90a4d8..887252d25 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py @@ -1006,7 +1006,7 @@ def computePoints( self.addPointsToMemoryLayer( elevationPointsLayer, planeAreasElevationPoints, context ) - QgsProject.instance().addMapLayer(exclusionLyr) + # QgsProject.instance().addMapLayer(exclusionLyr) return elevationPointsLayer.getFeatures() def readAndMaskRaster( From 17ffefdfccb277b8bd7e3846e769618a48243698 Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 4 Oct 2023 18:23:50 -0300 Subject: [PATCH 14/53] cleanup --- .../Algs/GeometricAlgs/extractElevationPoints.py | 6 ------ 1 file changed, 6 deletions(-) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py index 887252d25..2d23e91e0 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py @@ -55,7 +55,6 @@ QgsVectorLayerUtils, QgsProcessingParameterVectorLayer, QgsSpatialIndex, - QgsProject, QgsProcessingParameterExpression, QgsProcessingParameterBoolean, ) @@ -588,7 +587,6 @@ def computePoints( context=context, feedback=multiStepFeedback, ) - # QgsProject.instance().addMapLayer(polygonLyr) if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) @@ -1006,7 +1004,6 @@ def computePoints( self.addPointsToMemoryLayer( elevationPointsLayer, planeAreasElevationPoints, context ) - # QgsProject.instance().addMapLayer(exclusionLyr) return elevationPointsLayer.getFeatures() def readAndMaskRaster( @@ -1213,7 +1210,6 @@ def buildGrid( context=context, feedback=multiStepFeedback, ) - # QgsProject.instance().addMapLayer(gridLyr) if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) @@ -1881,8 +1877,6 @@ def getElevationPointsFromHilltops( context=context, feedback=multiStepFeedback, ) - # hillTopsLyr.setName('hilltops') - # QgsProject.instance().addMapLayer(hillTopsLyr) if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) From 49a34064d2c02d822bcb5af991a66e43f2b9f8a0 Mon Sep 17 00:00:00 2001 From: phborba Date: Thu, 5 Oct 2023 17:03:54 -0300 Subject: [PATCH 15/53] =?UTF-8?q?Vers=C3=A3o=204.11.21:=20Corre=C3=A7?= =?UTF-8?q?=C3=A3o=20de=20bug=20e=20melhorias=20na=20interface=20de=20carr?= =?UTF-8?q?egamento?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 4 +- ...tifyCountourStreamIntersectionAlgorithm.py | 2 +- ...entifyDrainageAndContourInconsistencies.py | 4 +- .../LayerLoaderFactory/edgvLayerLoader.py | 5 +- .../LayerLoaderFactory/postgisLayerLoader.py | 3 +- .../SqlFactory/postgisSqlGenerator.py | 14 +-- .../SelectionWidgets/customTableSelector.py | 113 ++++++++++-------- .../loadLayersFromServer.py | 3 +- DsgTools/metadata.txt | 2 +- 9 files changed, 82 insertions(+), 68 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 308ab9ca9..de3e8681e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.20 - dev +## 4.11.21 - dev Novas Funcionalidades: @@ -18,6 +18,7 @@ Melhorias: - Melhoria de desempenho no processo Identify Unmerged Lines With Same Attribute Set: Código refatorado para usar busca utilizando grafo; - O detecta nula agora indica quais camadas tem que ser verificadas; - Algoritmos da caixa de ferramentas reorganizados por temática para facilitar o uso; +- A interface de carregamento agora filtra também na coluna de categoria da camada; Correção de bug: @@ -33,6 +34,7 @@ Correção de bug: - Corrige bug no ClipAndCopyFeaturesBetweenDatabasesAlgorithm; - Corrige bug no VerifyAdjacentGeographicBoundaryDataAlgorithm (verifica interseção na moldura, não apenas no boundingbox); - Corrige bug na rotina de extrair automaticamente pontos cotados (Extract Spot Elevation); +- Corrige bug da interface de carregamento não listar camadas do tipo GEOMETRY (genéricas normalmente criadas pelo FME). A camada que tiver esse tipo vai ser carregada em um nó chamado Geometry; ## 4.10.1 - 2023-10-02 diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCountourStreamIntersectionAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCountourStreamIntersectionAlgorithm.py index 660ab4c8c..12a03354b 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCountourStreamIntersectionAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyCountourStreamIntersectionAlgorithm.py @@ -265,7 +265,7 @@ def displayName(self): user-visible display of the algorithm name. """ return self.tr( - "Identify Intersections Between Contour Lines and Drainage Lines" + "Identify Invalid Intersections Between Contour Lines and Drainage Lines" ) def group(self): diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py index f8101d890..c67a0972e 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py @@ -554,7 +554,7 @@ def displayName(self): Returns the translated algorithm name, which should be used for any user-visible display of the algorithm name. """ - return self.tr("Identify Drainage and Contour Inconsistencies") + return self.tr("Identify Drainage Flow and Contour Inconsistencies") def group(self): """ @@ -575,5 +575,5 @@ def groupId(self): def shortHelpString(self): return self.tr( - "O algoritmo orderna ou direciona fluxo, como linhas de drenagem " + "O algoritmo orderna ou direciona fluxo, como linhas de drenagem e confronta com as curvas de nível, verificando se as drenagens estão correndo de montante para jusante." ) diff --git a/DsgTools/core/Factories/LayerLoaderFactory/edgvLayerLoader.py b/DsgTools/core/Factories/LayerLoaderFactory/edgvLayerLoader.py index bc73ed7e2..68354f1bf 100644 --- a/DsgTools/core/Factories/LayerLoaderFactory/edgvLayerLoader.py +++ b/DsgTools/core/Factories/LayerLoaderFactory/edgvLayerLoader.py @@ -60,6 +60,7 @@ def __init__(self, iface, abstractDb, loadCentroids): "MULTILINESTRING": "Line", "POLYGON": "Area", "MULTIPOLYGON": "Area", + "GEOMETRY": "Geometry", } def preLoadStep(self, inputList): @@ -146,16 +147,12 @@ def getLyrDict(self, inputList, isEdgv=True): if isinstance(inputList, list) and len(inputList) > 0: if isinstance(inputList[0], dict): for elem in inputList: - if elem["geomType"] == "GEOMETRY": - continue lyrDict[self.correspondenceDict[elem["geomType"]]][ elem["cat"] ].append(elem) else: for type in list(self.geomTypeDict.keys()): # some tables are only registered as GEOMETRY and should not be considered - if type == "GEOMETRY": - continue for lyr in self.geomTypeDict[type]: if lyr not in inputList: continue diff --git a/DsgTools/core/Factories/LayerLoaderFactory/postgisLayerLoader.py b/DsgTools/core/Factories/LayerLoaderFactory/postgisLayerLoader.py index e271ff5a3..67e1d6ba6 100644 --- a/DsgTools/core/Factories/LayerLoaderFactory/postgisLayerLoader.py +++ b/DsgTools/core/Factories/LayerLoaderFactory/postgisLayerLoader.py @@ -150,7 +150,7 @@ def load( useInheritance=False, stylePath=None, onlyWithElements=False, - geomFilterList=[], + geomFilterList=None, customForm=False, loadEditingStructure=False, parent=None, @@ -163,6 +163,7 @@ def load( 5. Build Groups; 6. Load Layers; """ + geomFilterList = [] if geomFilterList is None else geomFilterList self.iface.mapCanvas().freeze() # done to speedup things layerList, isDictList = self.preLoadStep(inputList) # 2. Filter Layers: diff --git a/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py b/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py index b368fdc08..242ee4ccd 100644 --- a/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py +++ b/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py @@ -1370,20 +1370,20 @@ def getGeomColumnDict(self): def getGeomColumnTupleList(self, showViews=False, filterList=None): filterLayersClause = ( - "AND f_table_name in ({table_name_list})".format( + " f_table_name in ({table_name_list})".format( table_name_list=",".join(filterList) ) if filterList - else """ """ + else """""" ) showViewsClause = ( - """ AND table_type = 'BASE TABLE'""" if not showViews else """ """ + """ table_type = 'BASE TABLE'""" if not showViews else """""" ) - sql = """select f_table_schema, f_table_name, f_geometry_column, type, table_type from (select distinct f_table_schema, f_table_name, f_geometry_column, type, f_table_schema || '.' || f_table_name as jc from public.geometry_columns as gc) as inn + whereClause = "" if not showViews and filterList is None else f"WHERE {' AND '.join([filterLayersClause, showViewsClause])}" + + sql = f"""select f_table_schema, f_table_name, f_geometry_column, type, table_type from (select distinct f_table_schema, f_table_name, f_geometry_column, type, f_table_schema || '.' || f_table_name as jc from public.geometry_columns as gc) as inn left join (select table_schema || '.' || table_name as jc, table_type from information_schema.tables) as infs on inn.jc = infs.jc - where inn.type <> 'GEOMETRY' {where_layer_filter} {where_show_views}""".format( - where_layer_filter=filterLayersClause, where_show_views=showViewsClause - ) + {whereClause}""" return sql def getNotNullDict(self, layerFilter=None): diff --git a/DsgTools/gui/CustomWidgets/SelectionWidgets/customTableSelector.py b/DsgTools/gui/CustomWidgets/SelectionWidgets/customTableSelector.py index a74e82e4b..76d7a2b3c 100644 --- a/DsgTools/gui/CustomWidgets/SelectionWidgets/customTableSelector.py +++ b/DsgTools/gui/CustomWidgets/SelectionWidgets/customTableSelector.py @@ -21,6 +21,7 @@ ***************************************************************************/ """ from builtins import range +from copy import deepcopy import os # Qt imports @@ -46,6 +47,7 @@ def __init__(self, customNumber=None, parent=None): self.toLs = [] self.utils = Utils() self.setupUi(self) + self.filterColumnKeyList = [0] def resizeTrees(self): """ @@ -81,12 +83,14 @@ def setFilterColumn(self, customNumber=None): """ Chooses which column is going to be used in the filter """ - if isinstance(customNumber, int): - self.filterColumnKey = self.headerList[customNumber] + if isinstance(customNumber, list): + self.filterColumnKeyList = deepcopy(customNumber) + elif isinstance(customNumber, int): + self.filterColumnKeyList = [customNumber] elif self.headerList: - self.filterColumnKey = self.headerList[1] + self.filterColumnKeyList = [1] else: - self.filterColumnKey = self.headerList[0] + self.filterColumnKeyList = [0] def clearAll(self): """ @@ -103,10 +107,11 @@ def setHeaders(self, headerList, customNumber=None): self.toTreeWidget.setHeaderLabels(headerList) self.setFilterColumn(customNumber=customNumber) - def setInitialState(self, fromDictList, unique=False, selectedDictList=[]): + def setInitialState(self, fromDictList, unique=False, selectedDictList=None): """ Sets the initial state """ + selectedDictList = [] if selectedDictList is None else selectedDictList self.fromLs = [] self.toLs = [] self.fromTreeWidget.clear() @@ -143,13 +148,14 @@ def addItemsToTree( addItemDictList, controlList, unique=False, - selectedDictList=[], + selectedDictList=None, ): """ Adds items from addItemDictList in treeWidget. addItemDictList = [-list of dicts with keys corresponding to header list texts-] unique: only adds item if it is not in already in tree """ + selectedDictList = [] if selectedDictList is None else selectedDictList rootNode = treeWidget.invisibleRootItem() # invisible root item for dictItem in addItemDictList: firstColumnChild = self.getChildNode( @@ -163,19 +169,19 @@ def addItemsToTree( textList = [ dictItem[self.headerList[i]] for i in range(len(self.headerList)) ] - if unique: - childNode = self.getChildNode(firstColumnChild, textList) - if not childNode: - item = self.utils.createWidgetItem(firstColumnChild, textList) - if selectedDictList: - item.setSelected(True) - itemList = self.getItemList(item) - if itemList not in controlList: - controlList.append(itemList) - else: + if not unique: item = self.utils.createWidgetItem(firstColumnChild, textList) itemList = self.getItemList(item) controlList.append(itemList) + continue + childNode = self.getChildNode(firstColumnChild, textList) + if not childNode: + item = self.utils.createWidgetItem(firstColumnChild, textList) + if selectedDictList: + item.setSelected(True) + itemList = self.getItemList(item) + if itemList not in controlList: + controlList.append(itemList) self.resizeTrees() self.sortItems(treeWidget) @@ -183,10 +189,7 @@ def getItemList(self, item, returnAsDict=False): """ Gets item as a list """ - if returnAsDict: - returnItem = dict() - else: - returnItem = [] + returnItem = dict() if returnAsDict else [] for i in range(item.columnCount()): if returnAsDict: returnItem[self.headerList[i]] = item.text(i) @@ -212,11 +215,12 @@ def getLists(self, sender): @pyqtSlot(bool, name="on_pushButtonDeselectOne_clicked") @pyqtSlot(bool, name="on_pushButtonSelectAll_clicked") @pyqtSlot(bool, name="on_pushButtonDeselectAll_clicked") - def selectItems(self, isSelected, selectedItems=[]): + def selectItems(self, isSelected, selectedItems=None): """ Adds the selected items to the "to" list """ # gets lists + selectedItems = [] if selectedItems is None else selectedItems ( originTreeWidget, originControlLs, @@ -267,12 +271,11 @@ def moveChild(self, parentNode, idx, destinationNode, isSelected): """ If node is selected, removes node from parentNode and adds it to destinationNode """ - if isSelected: - child = parentNode.takeChild(idx) - destinationNode.addChild(child) - return True - else: + if not isSelected: return False + child = parentNode.takeChild(idx) + destinationNode.addChild(child) + return True def getDestinationNode(self, destinationRoot, catChild, returnNew=True): """ @@ -305,16 +308,23 @@ def on_filterLineEdit_textChanged(self, text): """ Filters the items to make it easier to spot and select them """ - classes = [ - node[1].lower() for node in self.fromLs if text.lower() in node[1].lower() - ] # text list - filteredClasses = [ - i for i in classes if i.lower() not in [j[1].lower() for j in self.toLs] - ] # text list - self.filterTree(self.fromTreeWidget, self.fromLs, filteredClasses, 1) + lowerText = text.lower() + allTuples = [tuple(node[i].lower() for i in self.filterColumnKeyList) for node in self.fromLs] + itemTupleList = set( + t for t in allTuples if any(lowerText in i for i in t) + ) + destinationTupleSet = set( + tuple( + node[i].lower() for i in self.filterColumnKeyList for node in self.toLs + ) + ) + filteredItems = itemTupleList - destinationTupleSet + if filteredItems == set(): + filteredItems = itemTupleList + self.filterTree(self.fromTreeWidget, self.fromLs, filteredItems) self.resizeTrees() - def filterTree(self, treeWidget, controlList, filterList, columnIdx): + def filterTree(self, treeWidget, controlList, filterList): """ Actual filter """ @@ -322,13 +332,14 @@ def filterTree(self, treeWidget, controlList, filterList, columnIdx): rootNode = treeWidget.invisibleRootItem() # remove items that are not in filterList for item in controlList: - if item[columnIdx].lower() in filterList: - firstColumnChild = self.getChildNode( - rootNode, [item[0]] + [""] * (len(item) - 1) - ) # looks for a item in the format ['first column text', '','',...,''] - if not firstColumnChild: - firstColumnChild = self.utils.createWidgetItem(rootNode, item[0], 0) - QTreeWidgetItem(firstColumnChild, item) + if tuple(item[i].lower() for i in self.filterColumnKeyList) not in filterList: + continue + firstColumnChild = self.getChildNode( + rootNode, [item[0]] + [""] * (len(item) - 1) + ) # looks for a item in the format ['first column text', '','',...,''] + if firstColumnChild is None: + firstColumnChild = self.utils.createWidgetItem(rootNode, item[0], 0) + QTreeWidgetItem(firstColumnChild, item) rootNode.sortChildren(0, Qt.AscendingOrder) for i in range(rootNode.childCount()): rootNode.child(i).sortChildren(1, Qt.AscendingOrder) @@ -372,15 +383,17 @@ def removeItemsFromTree(self, dictItemList, treeWidget, controlList): returnList = [] for i in range(treeRoot.childCount())[::-1]: catChild = treeRoot.child(i) - if catChild.text(0) in catList: - for j in range(catChild.childCount())[::-1]: - nodeChild = catChild.child(j) - nodeChildDict = self.getItemList(nodeChild, returnAsDict=True) - nodeChildDict[self.headerList[0]] = catChild.text(0) - if nodeChildDict in dictItemList: - catChild.takeChild(j) - itemList = self.getItemList(nodeChild) - controlList.pop(controlList.index(itemList)) + if catChild.text(0) not in catList: + continue + for j in range(catChild.childCount())[::-1]: + nodeChild = catChild.child(j) + nodeChildDict = self.getItemList(nodeChild, returnAsDict=True) + nodeChildDict[self.headerList[0]] = catChild.text(0) + if nodeChildDict not in dictItemList: + continue + catChild.takeChild(j) + itemList = self.getItemList(nodeChild) + controlList.pop(controlList.index(itemList)) for i in range(treeRoot.childCount())[::-1]: if treeRoot.child(i).childCount() == 0: treeRoot.takeChild(i) diff --git a/DsgTools/gui/LayerTools/LoadLayersFromServer/loadLayersFromServer.py b/DsgTools/gui/LayerTools/LoadLayersFromServer/loadLayersFromServer.py index 71ec63d49..94313c38a 100644 --- a/DsgTools/gui/LayerTools/LoadLayersFromServer/loadLayersFromServer.py +++ b/DsgTools/gui/LayerTools/LoadLayersFromServer/loadLayersFromServer.py @@ -81,6 +81,7 @@ def __init__(self, iface, parent=None): self.tr("Layer\nType"), ] self.layersCustomSelector.setHeaders(self.headerList) + self.layersCustomSelector.setFilterColumn([0, 1]) self.customServerConnectionWidget.serverConnectionTab.currentChanged.connect( self.layersCustomSelector.setInitialState ) @@ -117,7 +118,7 @@ def updateLayersFromDbs(self, type, dbList, showViews=False): dbName ].getGeomColumnTupleList(showViews=showViews) for tableSchema, tableName, geom, geomType, tableType in geomList: - if self.tr("Unknown model") in dbName: + if "EDGV" not in dbName: lyrName = tableName cat = tableSchema else: diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 35feba2b0..c2097e9ca 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.20 +version=4.11.21 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From 263ad6e216d5f5b572a284a0cc65c30bebb2cdcc Mon Sep 17 00:00:00 2001 From: phborba Date: Thu, 5 Oct 2023 18:54:47 -0300 Subject: [PATCH 16/53] =?UTF-8?q?Vers=C3=A3o=204.11.22:=20Novo=20processo?= =?UTF-8?q?=20massa=20d'=C3=A1gua=20versus=20curva=20de=20n=C3=ADvel?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 +- ...ntifyWaterBodyAndContourInconsistencies.py | 207 ++++++++++++++++++ .../dsgtoolsProcessingAlgorithmProvider.py | 4 + DsgTools/metadata.txt | 2 +- 4 files changed, 214 insertions(+), 2 deletions(-) create mode 100644 DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyWaterBodyAndContourInconsistencies.py diff --git a/CHANGELOG.md b/CHANGELOG.md index de3e8681e..b5bbb0f77 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,12 +1,13 @@ # CHANGELOG -## 4.11.21 - dev +## 4.11.22 - dev Novas Funcionalidades: - Novo processo de corrigir erros de segmentação em linhas (barragem versus rodovias); - Novo processo para validar a estrutura do banco de dados em relação ao masterfile; - Novo processo de detectar as mudanças entre dois banco de dados, realizados em dias distintos; +- Novo processo de identificar erros de intersecção entre curvas de nível e massas d'água; Melhorias: diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyWaterBodyAndContourInconsistencies.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyWaterBodyAndContourInconsistencies.py new file mode 100644 index 000000000..af37c2e11 --- /dev/null +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyWaterBodyAndContourInconsistencies.py @@ -0,0 +1,207 @@ +# -*- coding: utf-8 -*- +""" +/*************************************************************************** + DsgTools + A QGIS plugin + Brazilian Army Cartographic Production Tools + ------------------- + begin : 2023-10-05 + git sha : $Format:%H$ + copyright : (C) 2023 by Philipe Borba - Cartographic Engineer @ Brazilian Army + email : borba.philipe@eb.mil.br + ***************************************************************************/ +/*************************************************************************** + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + ***************************************************************************/ +""" + +from itertools import product +import os +import concurrent.futures +import processing + +from collections import defaultdict +from DsgTools.core.DSGToolsProcessingAlgs.Algs.ValidationAlgs.validationAlgorithm import ( + ValidationAlgorithm, +) +from DsgTools.core.DSGToolsProcessingAlgs.algRunner import AlgRunner +from qgis.PyQt.QtCore import QCoreApplication +from qgis.core import ( + QgsProcessing, + QgsProcessingParameterFeatureSink, + QgsProcessingException, + QgsProcessingMultiStepFeedback, + QgsProcessingParameterFeatureSource, + QgsProcessingParameterNumber, + QgsProcessingParameterField, + QgsWkbTypes, + QgsProcessingParameterExpression, +) +from DsgTools.core.GeometricTools import graphHandler + + +class IdentifyWaterBodyAndContourInconsistencies(ValidationAlgorithm): + + INPUT_WATER_BODIES = "INPUT_WATER_BODIES" + INPUT_CONTOURS = "INPUT_CONTOURS" + CONTOUR_ATTR = "CONTOUR_ATTR" + CONTOUR_INSIDE_WATER_BODY_EXPRESSION = "CONTOUR_INSIDE_WATER_BODY_EXPRESSION" + FLAGS = "FLAGS" + + def initAlgorithm(self, config=None): + self.addParameter( + QgsProcessingParameterFeatureSource( + self.INPUT_WATER_BODIES, + self.tr("Input water bodies"), + [QgsProcessing.TypeVectorPolygon], + optional=False, + ) + ) + + self.addParameter( + QgsProcessingParameterFeatureSource( + self.INPUT_CONTOURS, + self.tr("Input contours"), + [QgsProcessing.TypeVectorLine], + optional=False, + ) + ) + + self.addParameter( + QgsProcessingParameterField( + self.CONTOUR_ATTR, + self.tr("Contour value field"), + "cota", + self.INPUT_CONTOURS, + QgsProcessingParameterField.Any, + ) + ) + + self.addParameter( + QgsProcessingParameterExpression( + self.CONTOUR_INSIDE_WATER_BODY_EXPRESSION, + self.tr("Filter expression for cotours inside water bodies"), + """"dentro_de_massa_dagua" = 1""", + self.INPUT_CONTOURS, + ) + ) + + self.addParameter( + QgsProcessingParameterFeatureSink( + self.FLAGS, self.tr("{0} Flags").format(self.displayName()) + ) + ) + + def processAlgorithm(self, parameters, context, feedback): + algRunner = AlgRunner() + multiStepFeedback = QgsProcessingMultiStepFeedback(4, feedback) + inputContours = self.parameterAsVectorLayer( + parameters, self.INPUT_CONTOURS, context + ) + contourExpression = self.parameterAsExpression( + parameters, self.CONTOUR_INSIDE_WATER_BODY_EXPRESSION, context + ) + self.prepareFlagSink( + parameters, inputContours, QgsWkbTypes.MultiLineString, context + ) + currentStep = 0 + multiStepFeedback.setCurrentStep(currentStep) + inputWaterBodiesLyr = algRunner.runCreateFieldWithExpression( + inputLyr=self.INPUT_WATER_BODIES, + expression="$id", + fieldName="featid", + fieldType=1, + context=context, + feedback=multiStepFeedback, + is_child_algorithm=True, + ) + + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + clippedContours = algRunner.runClip( + inputLayer=parameters[self.INPUT_CONTOURS], + overlayLayer=inputWaterBodiesLyr, + context=context, + feedback=multiStepFeedback, + ) + if clippedContours.featureCount() == 0: + return {self.FLAGS: self.flag_id} + + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + expectedContours = algRunner.runFilterExpression( + inputLyr=parameters[self.INPUT_CONTOURS], + expression=contourExpression, + context=context, + feedback=multiStepFeedback, + ) + flagLambda = lambda x: self.flagFeature( + x, flagText=self.tr("Invalid intersection between water body and contours") + ) + if expectedContours.featureCount() == 0: + list(map(flagLambda, clippedContours.getFeatures())) + return {self.FLAGS: self.flag_id} + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + flagCandidatesLyr = processing.run( + "native:joinattributesbylocation", + { + "INPUT": clippedContours, + "PREDICATE": [2], # equal + "JOIN": expectedContours, + "JOIN_FIELDS": [], + "METHOD": 0, + "DISCARD_NONMATCHING": False, + "PREFIX": "", + "NON_MATCHING": "memory:", + }, + context=context, + feedback=multiStepFeedback, + is_child_algorithm=False, + )["NON_MATCHING"] + list(map(flagLambda, flagCandidatesLyr.getFeatures())) + + return {self.FLAGS: self.flag_id} + + def tr(self, string): + return QCoreApplication.translate("Processing", string) + + def createInstance(self): + return IdentifyWaterBodyAndContourInconsistencies() + + def name(self): + return "identifywaterbodyandcontourinconsistencies" + + def displayName(self): + """ + Returns the translated algorithm name, which should be used for any + user-visible display of the algorithm name. + """ + return self.tr("Identify Water Bodies and Contour Inconsistencies") + + def group(self): + """ + Returns the name of the group this algorithm belongs to. This string + should be localised. + """ + return self.tr("QA Tools: Terrain Processes") + + def groupId(self): + """ + Returns the unique ID of the group this algorithm belongs to. This + string should be fixed for the algorithm, and must not be localised. + The group id should be unique within each provider. Group id should + contain lowercase alphanumeric characters only and no spaces or other + formatting characters. + """ + return "DSGTools - QA Tools: Terrain Processes" + + def shortHelpString(self): + return self.tr( + "O algoritmo confronta massas d'água com as curvas de nível, verificando se uma curva intersecta mais de uma vez uma curva de nível." + ) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py b/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py index 7062e997b..52ce6798d 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py @@ -39,6 +39,9 @@ from DsgTools.core.DSGToolsProcessingAlgs.Algs.ValidationAlgs.identifySmallObjectsOnLayersAlgorithm import ( IdentifySmallObjectsOnLayersAlgorithm, ) +from DsgTools.core.DSGToolsProcessingAlgs.Algs.ValidationAlgs.identifyWaterBodyAndContourInconsistencies import ( + IdentifyWaterBodyAndContourInconsistencies, +) from processing.core.ProcessingConfig import ProcessingConfig, Setting from PyQt5.QtCore import QCoreApplication from qgis.core import QgsApplication, QgsProcessingProvider @@ -616,6 +619,7 @@ def getAlgList(self): IdentifyDifferencesBetweenDatabaseModelsAlgorithm(), AzimuthCalculationAlgorithm(), DetectChangesBetweenGroups(), + IdentifyWaterBodyAndContourInconsistencies(), ] return algList diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index c2097e9ca..ed5dafb8d 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.21 +version=4.11.22 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From 516e2613e0cfd87329d487f3ec063f05029f733c Mon Sep 17 00:00:00 2001 From: phborba Date: Thu, 5 Oct 2023 19:14:00 -0300 Subject: [PATCH 17/53] bug fix --- .../core/Factories/SqlFactory/postgisSqlGenerator.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py b/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py index 242ee4ccd..75d01ae4d 100644 --- a/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py +++ b/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py @@ -1376,10 +1376,13 @@ def getGeomColumnTupleList(self, showViews=False, filterList=None): if filterList else """""" ) - showViewsClause = ( - """ table_type = 'BASE TABLE'""" if not showViews else """""" + showViewsClause = """ table_type = 'BASE TABLE'""" if not showViews else """""" + whereStrList = list( + filter(lambda x: x != "", [filterLayersClause, showViewsClause]) + ) + whereClause = ( + "" if whereStrList == [] else f"WHERE {' AND '.join(whereStrList)}" ) - whereClause = "" if not showViews and filterList is None else f"WHERE {' AND '.join([filterLayersClause, showViewsClause])}" sql = f"""select f_table_schema, f_table_name, f_geometry_column, type, table_type from (select distinct f_table_schema, f_table_name, f_geometry_column, type, f_table_schema || '.' || f_table_name as jc from public.geometry_columns as gc) as inn left join (select table_schema || '.' || table_name as jc, table_type from information_schema.tables) as infs on inn.jc = infs.jc From 21ff36cb0f5d73bbca0a7f7018e5eca03492afe7 Mon Sep 17 00:00:00 2001 From: phborba Date: Thu, 5 Oct 2023 19:17:13 -0300 Subject: [PATCH 18/53] bug fixes --- ...ntifyWaterBodyAndContourInconsistencies.py | 23 ++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyWaterBodyAndContourInconsistencies.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyWaterBodyAndContourInconsistencies.py index af37c2e11..2c7089b22 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyWaterBodyAndContourInconsistencies.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyWaterBodyAndContourInconsistencies.py @@ -99,7 +99,7 @@ def initAlgorithm(self, config=None): def processAlgorithm(self, parameters, context, feedback): algRunner = AlgRunner() - multiStepFeedback = QgsProcessingMultiStepFeedback(4, feedback) + multiStepFeedback = QgsProcessingMultiStepFeedback(6, feedback) inputContours = self.parameterAsVectorLayer( parameters, self.INPUT_CONTOURS, context ) @@ -112,7 +112,7 @@ def processAlgorithm(self, parameters, context, feedback): currentStep = 0 multiStepFeedback.setCurrentStep(currentStep) inputWaterBodiesLyr = algRunner.runCreateFieldWithExpression( - inputLyr=self.INPUT_WATER_BODIES, + inputLyr=parameters[self.INPUT_WATER_BODIES], expression="$id", fieldName="featid", fieldType=1, @@ -141,13 +141,30 @@ def processAlgorithm(self, parameters, context, feedback): feedback=multiStepFeedback, ) flagLambda = lambda x: self.flagFeature( - x, flagText=self.tr("Invalid intersection between water body and contours") + x.geometry(), + flagText=self.tr("Invalid intersection between water body and contours"), ) if expectedContours.featureCount() == 0: list(map(flagLambda, clippedContours.getFeatures())) return {self.FLAGS: self.flag_id} currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) + algRunner.runCreateSpatialIndex( + inputLyr=clippedContours, + context=context, + feedback=multiStepFeedback, + is_child_algorithm=True, + ) + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + algRunner.runCreateSpatialIndex( + inputLyr=expectedContours, + context=context, + feedback=multiStepFeedback, + is_child_algorithm=True, + ) + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) flagCandidatesLyr = processing.run( "native:joinattributesbylocation", { From 33214b5793347daac4280c04ae43f05ce9e375d4 Mon Sep 17 00:00:00 2001 From: dinizime Date: Mon, 9 Oct 2023 14:09:30 -0300 Subject: [PATCH 19/53] bug fix --- .../identifyDrainageAndContourInconsistencies.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py index c67a0972e..364005f9f 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py @@ -521,6 +521,14 @@ def findMissingErrorsOnGraphConsideringRamificationsAndConfluences( continue succ = list(G.successors(node)) pred = list(G.predecessors(node)) + if len(succ) == 0 or len(pred) == 0: + t = "in" if len(succ) == 0 else "out" + flagText = self.tr( + f"Drainage flow issue: All drainage lines are flowing {t}." + ) + flagGeom = nodesDict[node].geometry() + flagDict[flagGeom.asWkb()] = flagText + continue n1, n2 = succ if len(pred) == 1 else pred h1, h2 = d[n1], d[n2] processedNodes.add(node) From 0de82d3d9acefaa81206da88e18f70be00dd7749 Mon Sep 17 00:00:00 2001 From: dinizime Date: Mon, 9 Oct 2023 14:16:43 -0300 Subject: [PATCH 20/53] bug fix --- .../ValidationAlgs/identifyDrainageAndContourInconsistencies.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py index 364005f9f..3b39126d1 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyDrainageAndContourInconsistencies.py @@ -521,7 +521,7 @@ def findMissingErrorsOnGraphConsideringRamificationsAndConfluences( continue succ = list(G.successors(node)) pred = list(G.predecessors(node)) - if len(succ) == 0 or len(pred) == 0: + if G.degree(node) > 1 and ((len(succ) == 0 and len(pred) > 0) or (len(pred) == 0 and len(succ) > 0)): t = "in" if len(succ) == 0 else "out" flagText = self.tr( f"Drainage flow issue: All drainage lines are flowing {t}." From bd9bc19c3d8932fee96d82c77a4635391363d43c Mon Sep 17 00:00:00 2001 From: phborba Date: Mon, 9 Oct 2023 15:40:27 -0300 Subject: [PATCH 21/53] bug fix --- .../Algs/GeometricAlgs/splitPolygonsByGrid.py | 20 ++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py index 07737807c..56d34c99e 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py @@ -38,6 +38,7 @@ QgsFields, QgsVectorLayer, QgsFeatureRequest, + QgsFeature, ) from qgis.PyQt.QtCore import QCoreApplication @@ -167,6 +168,7 @@ def processAlgorithm(self, parameters, context, feedback): self.algRunner = AlgRunner() self.layerHandler = LayerHandler() source = self.parameterAsSource(parameters, self.INPUT, context) + inputLyr = self.parameterAsVectorLayer(parameters, self.INPUT, context) x_distance = self.parameterAsDouble(parameters, self.X_DISTANCE, context) y_distance = self.parameterAsDouble(parameters, self.Y_DISTANCE, context) min_area = self.parameterAsDouble(parameters, self.MIN_AREA, context) @@ -203,7 +205,7 @@ def processAlgorithm(self, parameters, context, feedback): multiStepFeedback.setCurrentStep(1) multiStepFeedback.setProgressText(self.tr("Creating spatial index...")) self.algRunner.runCreateSpatialIndex( - verticesLyr, context=context, feedback=multiStepFeedback + verticesLyr, context=context, feedback=multiStepFeedback, is_child_algorithm=True, ) multiStepFeedback.setProgressText(self.tr("Processing features...")) @@ -226,6 +228,13 @@ def prepare_data(feature): return None, None return featureLayer, localNeighborVertexes + def output_data(feature): + newFeat = QgsFeature(source.fields()) + newFeat.setGeometry(feature.geometry()) + newFeat[classFieldName] = feature[classFieldName] + return newFeat + + if max_concurrency == 1: for current, feature in enumerate(iterator, start=2): if multiStepFeedback.isCanceled(): @@ -256,7 +265,7 @@ def prepare_data(feature): self.tr(f"Processed {current}/{nFeats}.") ) continue - sink.addFeatures(list(outputFeatures)) + sink.addFeatures(list(map(output_data, outputFeatures))) if current % 500 == 0: multiStepFeedback.pushInfo( self.tr(f"Processed {current}/{nFeats}.") @@ -286,7 +295,7 @@ def compute_in_paralel(feature): return {self.OUTPUT: dest_id} if outputFeatures is None or outputFeatures == set(): continue - sink.addFeatures(list(outputFeatures)) + sink.addFeatures(list(map(output_data, outputFeatures))) if current % 500 == 0: multiStepFeedback.pushInfo(self.tr(f"Processed {current}/{nFeats}.")) @@ -357,10 +366,11 @@ def compute( hSpacing=xSpacing, vSpacing=ySpacing, context=context, + is_child_algorithm=True, ) if feedback is not None and feedback.isCanceled(): return set() - algRunner.runCreateSpatialIndex(gridLayer, context=context) + algRunner.runCreateSpatialIndex(gridLayer, context=context, is_child_algorithm=True) if feedback is not None and feedback.isCanceled(): return set() try: @@ -390,7 +400,7 @@ def compute( clippedPolygons.startEditing() if feedback is not None and feedback.isCanceled(): return set() - algRunner.runCreateSpatialIndex(clippedPolygons, context=context) + algRunner.runCreateSpatialIndex(clippedPolygons, context=context, is_child_algorithm=True) nFeats = clippedPolygons.featureCount() if nFeats == 0: return None From e1e2886a8518f4593a7c3a3a40af0abdc575b663 Mon Sep 17 00:00:00 2001 From: phborba Date: Tue, 10 Oct 2023 11:16:27 -0300 Subject: [PATCH 22/53] fix --- .../Algs/GeometricAlgs/splitPolygonsByGrid.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py index 56d34c99e..ebe09b91c 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py @@ -274,6 +274,8 @@ def output_data(feature): def compute_in_paralel(feature): featureLayer, localNeighborVertexes = prepare_data(feature) + if featureLayer is None: + return set() return self.compute( localNeighborVertexes=localNeighborVertexes, feature=feature, From e51a8c0d72a0c468d1194fe898beb868c4e8063c Mon Sep 17 00:00:00 2001 From: phborba Date: Tue, 10 Oct 2023 12:06:20 -0300 Subject: [PATCH 23/53] =?UTF-8?q?Vers=C3=A3o=204.11.23:=20Melhoria=20no=20?= =?UTF-8?q?menu=20de=20aquisi=C3=A7=C3=A3o?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 ++- .../Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py | 2 ++ DsgTools/metadata.txt | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b5bbb0f77..0ccf0014c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.22 - dev +## 4.11.23 - dev Novas Funcionalidades: @@ -20,6 +20,7 @@ Melhorias: - O detecta nula agora indica quais camadas tem que ser verificadas; - Algoritmos da caixa de ferramentas reorganizados por temática para facilitar o uso; - A interface de carregamento agora filtra também na coluna de categoria da camada; +- O menu de aquisição agora mantém a camada ativa quando reclassifica uma feição no modo de reclassificação; Correção de bug: diff --git a/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py b/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py index 51bb41524..edc865c01 100644 --- a/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py +++ b/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py @@ -246,6 +246,7 @@ def validLayersToReclassification(self, buttonConfig): def reclassify(self, buttonConfig, reclassifyData): + currentActiveLayer = iface.activeLayer() destinatonLayerName = buttonConfig["buttonLayer"] destinatonLayer = self.qgis.getVectorLayerByName(destinatonLayerName) selectedLayers = reclassifyData["layers"] @@ -258,6 +259,7 @@ def reclassify(self, buttonConfig, reclassifyData): self.qgis.cutAndPasteSelectedFeatures( layer, destinatonLayer, attributes ) + iface.setActiveLayer(currentActiveLayer) def getLayersForReclassification(self, layerName, geometryType): layers = self.qgis.getLoadedVectorLayers() diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index ed5dafb8d..ffc64b6ca 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.22 +version=4.11.23 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From 75bfc81e4359b8bbe9a6245260b852b9e79dd201 Mon Sep 17 00:00:00 2001 From: diogooliveira-dsg Date: Tue, 10 Oct 2023 12:24:05 -0300 Subject: [PATCH 24/53] bug fix --- .../Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py | 2 -- DsgTools/Modules/acquisitionMenu/widgets/menuDock.py | 3 +++ 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py b/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py index edc865c01..51bb41524 100644 --- a/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py +++ b/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py @@ -246,7 +246,6 @@ def validLayersToReclassification(self, buttonConfig): def reclassify(self, buttonConfig, reclassifyData): - currentActiveLayer = iface.activeLayer() destinatonLayerName = buttonConfig["buttonLayer"] destinatonLayer = self.qgis.getVectorLayerByName(destinatonLayerName) selectedLayers = reclassifyData["layers"] @@ -259,7 +258,6 @@ def reclassify(self, buttonConfig, reclassifyData): self.qgis.cutAndPasteSelectedFeatures( layer, destinatonLayer, attributes ) - iface.setActiveLayer(currentActiveLayer) def getLayersForReclassification(self, layerName, geometryType): layers = self.qgis.getLoadedVectorLayers() diff --git a/DsgTools/Modules/acquisitionMenu/widgets/menuDock.py b/DsgTools/Modules/acquisitionMenu/widgets/menuDock.py index d079b46c6..7807bcbcf 100644 --- a/DsgTools/Modules/acquisitionMenu/widgets/menuDock.py +++ b/DsgTools/Modules/acquisitionMenu/widgets/menuDock.py @@ -2,6 +2,7 @@ from PyQt5 import QtCore, uic, QtWidgets, QtGui import json from DsgTools.Modules.utils.factories.utilsFactory import UtilsFactory +from qgis.utils import iface class MenuDock(QtWidgets.QDockWidget): @@ -51,6 +52,7 @@ def getMenuWidget(self): def setCurrentButton(self, buttonConfig): try: + currentActiveLayer = iface.activeLayer() if self.reclassifyCkb.isChecked(): self.getController().validLayersToReclassification(buttonConfig) @@ -62,6 +64,7 @@ def setCurrentButton(self, buttonConfig): if not self.reclassifyCkb.isChecked(): return self.getController().openReclassifyDialog(buttonConfig, self.reclassify) + iface.setActiveLayer(currentActiveLayer) except Exception as e: self.showError("Erro", str(e)) From 6940683c7559c2848dee8db541f97a36cc35dc88 Mon Sep 17 00:00:00 2001 From: phborba Date: Tue, 10 Oct 2023 13:34:13 -0300 Subject: [PATCH 25/53] =?UTF-8?q?Vers=C3=A3o=204.11.24:=20Melhoria=20na=20?= =?UTF-8?q?barra=20de=20ferramentas=20de=20revis=C3=A3o?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 ++- .../Toolbars/ReviewTools/reviewToolbar.py | 14 +++++++++++ .../Toolbars/ReviewTools/review_ui.py | 25 +++++++++++++++++++ DsgTools/metadata.txt | 2 +- 4 files changed, 42 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0ccf0014c..533583bae 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.23 - dev +## 4.11.24 - dev Novas Funcionalidades: @@ -21,6 +21,7 @@ Melhorias: - Algoritmos da caixa de ferramentas reorganizados por temática para facilitar o uso; - A interface de carregamento agora filtra também na coluna de categoria da camada; - O menu de aquisição agora mantém a camada ativa quando reclassifica uma feição no modo de reclassificação; +- Adicionado botão de selecionar a camada ativa na barra de ferramentas de revisão; Correção de bug: diff --git a/DsgTools/gui/ProductionTools/Toolbars/ReviewTools/reviewToolbar.py b/DsgTools/gui/ProductionTools/Toolbars/ReviewTools/reviewToolbar.py index 4575c7b93..448a2a6ed 100644 --- a/DsgTools/gui/ProductionTools/Toolbars/ReviewTools/reviewToolbar.py +++ b/DsgTools/gui/ProductionTools/Toolbars/ReviewTools/reviewToolbar.py @@ -534,6 +534,20 @@ def removeLayerFromGenericSelectionBlackList(self, layer=None): if self.mMapLayerComboBox.currentIndex() == 0: return self.removeLayerNameToGenericSelectionBlackList(layer.name()) + + @pyqtSlot(bool) + def on_setActiveLayerPushButton_clicked(self): + activeLayer = self.iface.activeLayer() + if isinstance(activeLayer, QgsVectorLayer): + self.mMapLayerComboBox.setLayer(activeLayer) + else: + self.iface.messageBar().pushMessage( + self.tr("Warning!"), + self.tr("Active layer is not valid to be used in this tool."), + level=Qgis.Warning, + duration=2, + ) + def addLayerNameToGenericSelectionBlackList(self, layerName: str): settings = QSettings() diff --git a/DsgTools/gui/ProductionTools/Toolbars/ReviewTools/review_ui.py b/DsgTools/gui/ProductionTools/Toolbars/ReviewTools/review_ui.py index 3cd0cb8d8..498954206 100644 --- a/DsgTools/gui/ProductionTools/Toolbars/ReviewTools/review_ui.py +++ b/DsgTools/gui/ProductionTools/Toolbars/ReviewTools/review_ui.py @@ -68,6 +68,31 @@ def setupUi(self, ReviewToolbar): self.mMapLayerComboBox.setMinimumSize(QtCore.QSize(0, 24)) self.mMapLayerComboBox.setObjectName("mMapLayerComboBox") self.mMapLayerComboBox.setFilters(core.QgsMapLayerProxyModel.PolygonLayer) + + self.setActiveLayerPushButton = QtWidgets.QPushButton(self.splitter) + sizePolicy = QtWidgets.QSizePolicy( + QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed + ) + sizePolicy.setHorizontalStretch(0) + sizePolicy.setVerticalStretch(0) + sizePolicy.setHeightForWidth( + self.setActiveLayerPushButton.sizePolicy().hasHeightForWidth() + ) + self.setActiveLayerPushButton.setSizePolicy(sizePolicy) + self.setActiveLayerPushButton.setMinimumSize(QtCore.QSize(0, 24)) + self.setActiveLayerPushButton.setMaximumSize(QtCore.QSize(24, 24)) + self.setActiveLayerPushButton.setText("") + iconSetCurrentLayer = QtGui.QIcon() + iconSetCurrentLayer.addPixmap( + QtGui.QPixmap(":/plugins/DsgTools/icons/reload.png"), + QtGui.QIcon.Normal, + QtGui.QIcon.Off, + ) + self.setActiveLayerPushButton.setIcon(iconSetCurrentLayer) + self.setActiveLayerPushButton.setIconSize(QtCore.QSize(16, 16)) + self.setActiveLayerPushButton.setObjectName("setActiveLayerPushButton") + + self.rankFieldComboBox = QgsFieldComboBox(self.splitter) sizePolicy = QtWidgets.QSizePolicy( QtWidgets.QSizePolicy.MinimumExpanding, QtWidgets.QSizePolicy.Fixed diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index ffc64b6ca..9a10e3475 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.23 +version=4.11.24 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From cace80d0a9445dcbf84ee240ff0ce9aaa7264b4d Mon Sep 17 00:00:00 2001 From: phborba Date: Tue, 10 Oct 2023 18:22:00 -0300 Subject: [PATCH 26/53] =?UTF-8?q?Vers=C3=A3o=204.11.25:=20corrige=20bug=20?= =?UTF-8?q?de=20casas=20decimais=20do=20clean?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 +- .../cleanGeometriesAlgorithm.py | 32 +++++++++---------- DsgTools/metadata.txt | 2 +- 3 files changed, 19 insertions(+), 18 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 533583bae..ec3411606 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.24 - dev +## 4.11.25 - dev Novas Funcionalidades: @@ -38,6 +38,7 @@ Correção de bug: - Corrige bug no VerifyAdjacentGeographicBoundaryDataAlgorithm (verifica interseção na moldura, não apenas no boundingbox); - Corrige bug na rotina de extrair automaticamente pontos cotados (Extract Spot Elevation); - Corrige bug da interface de carregamento não listar camadas do tipo GEOMETRY (genéricas normalmente criadas pelo FME). A camada que tiver esse tipo vai ser carregada em um nó chamado Geometry; +- Corrige bug dos parâmetros do clean não permitirem casas decimais o suficiente; ## 4.10.1 - 2023-10-02 diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/cleanGeometriesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/cleanGeometriesAlgorithm.py index cee897cdb..b31a0ca1a 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/cleanGeometriesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/cleanGeometriesAlgorithm.py @@ -63,24 +63,24 @@ def initAlgorithm(self, config): self.SELECTED, self.tr("Process only selected features") ) ) - self.addParameter( - QgsProcessingParameterDistance( - self.TOLERANCE, - self.tr("Snap radius"), - parentParameterName=self.INPUT, - minValue=-1.0, - defaultValue=1.0, - ) + param = QgsProcessingParameterDistance( + self.TOLERANCE, + self.tr("Snap Radius"), + parentParameterName=self.INPUT, + defaultValue=1.0, ) - self.addParameter( - QgsProcessingParameterNumber( - self.MINAREA, - self.tr("Minimum area"), - minValue=0, - defaultValue=0.0001, - type=QgsProcessingParameterNumber.Double, - ) + param.setMetadata({"widget_wrapper": {"decimals": 8}}) + self.addParameter(param) + + areaParam = QgsProcessingParameterNumber( + self.MINAREA, + self.tr("Minimum area"), + minValue=0, + defaultValue=1e-8, + type=QgsProcessingParameterNumber.Double, ) + areaParam.setMetadata({"widget_wrapper": {"decimals": 16}}) + self.addParameter(areaParam) self.addParameter( QgsProcessingParameterFeatureSink( diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 9a10e3475..c33adfd9b 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.24 +version=4.11.25 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From 6a9aceaa0dc3c1b171bb00bd95a323969e88fb67 Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 11 Oct 2023 10:14:10 -0300 Subject: [PATCH 27/53] bug fix na rotina de extrair pontos cotados --- .../GeometricAlgs/extractElevationPoints.py | 81 +++++++++++++++---- DsgTools/core/GeometricTools/rasterHandler.py | 5 +- 2 files changed, 69 insertions(+), 17 deletions(-) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py index 2d23e91e0..1485110b2 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py @@ -151,10 +151,10 @@ def initAlgorithm(self, config=None): 3: 40000, } self.contourBufferLengths = { - 0: 3.2e-3 * 25_000, - 1: 3.2e-3 * 50_000, - 2: 3.2e-3 * 100_000, - 3: 3.2e-3 * 250_000, + 0: 3.2e-4 * 25_000, + 1: 3.2e-4 * 50_000, + 2: 3.2e-4 * 100_000, + 3: 3.2e-4 * 250_000, } self.planeGridSpacingDict = { @@ -439,7 +439,7 @@ def computePoints( layerHandler = LayerHandler() nSteps = 17 + ( naturalPointFeaturesLyr is not None - ) + 3 * (waterBodiesLyr is not None) # handle this count after alg is done + ) + 3 * (waterBodiesLyr is not None) + (areaWithoutInformationLyr is not None)# handle this count after alg is done multiStepFeedback = ( QgsProcessingMultiStepFeedback(nSteps, feedback) if feedback is not None @@ -493,7 +493,7 @@ def computePoints( ) contourBufferLyr = algRunner.runBuffer( inputLayer=contourLyr, - distance=localContourBufferLength/4, + distance=localContourBufferLength, context=context, feedback=multiStepFeedback, ) @@ -528,11 +528,22 @@ def computePoints( context=context, feedback=multiStepFeedback ) + if areaWithoutInformationLyr is not None: + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + multiStepFeedback.setProgressText(self.tr(f"{self.currentStepText}: Running clip on area without information...")) + areaWithoutInformationLyr = algRunner.runClip( + areaWithoutInformationLyr, + overlayLayer=geographicBoundsLyr, + context=context, + feedback=multiStepFeedback + ) if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) multiStepFeedback.setProgressText(self.tr(f"{self.currentStepText}: Building masked raster...")) - npRaster, transform, maskLyr = self.readAndMaskRaster( + npRaster, maskedNpRaster, transform, maskLyr = self.readAndMaskRaster( clippedRasterLyr, geographicBoundsLyr, areaWithoutInformationLyr, @@ -1028,12 +1039,15 @@ def readAndMaskRaster( multiStepFeedback.setCurrentStep(currentStep) ds, npRaster = rasterHandler.readAsNumpy(clippedRasterLyr) transform = rasterHandler.getCoordinateTransform(ds) + nanIndexes = np.isnan(npRaster) + npRaster = (np.rint(npRaster)).astype(float) + npRaster[nanIndexes] = np.nan if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) layerList = list(filter(lambda x: x is not None, [areaWithoutInformationLyr, waterBodiesLyr, contourBufferLyr])) if layerList == []: - return npRaster, transform, None + return npRaster, npRaster, transform, contourBufferLyr maskLyr = AlgRunner().runMergeVectorLayers( layerList, context, feedback=multiStepFeedback ) if len(layerList) > 1 else layerList[0] @@ -1047,7 +1061,7 @@ def readAndMaskRaster( if multiStepFeedback is not None: currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) - npRaster = self.maskFeaturesFromLayerOnRaster( + maskedNpRaster = self.maskFeaturesFromLayerOnRaster( rasterLyr=clippedRasterLyr, geographicBoundsLyr=geographicBoundsLyr, maskLyr=maskLyr, @@ -1056,10 +1070,10 @@ def readAndMaskRaster( feedback=multiStepFeedback, npRaster=npRaster, ) - nanIndexes = np.isnan(npRaster) - npRaster = (np.rint(npRaster)).astype(float) - npRaster[nanIndexes] = np.nan - return npRaster, transform, maskLyr + nanIndexes = np.isnan(maskedNpRaster) + maskedNpRaster = (np.rint(maskedNpRaster)).astype(float) + maskedNpRaster[nanIndexes] = np.nan + return npRaster, maskedNpRaster, transform, maskLyr def getRangeOfNumberOfPoints(self, featList): minValue = min(featList, key=lambda x: x["cota"])["cota"] @@ -1521,6 +1535,7 @@ def getMinMaxFeatures(self, fields, npRaster, transform, distance, maskLyr, feed multiStepFeedback.setCurrentStep(0) multiStepFeedback.pushInfo(self.tr("Getting max coordinates from numpy array...")) maxCoordinatesArray = rasterHandler.getMaxCoordinatesFromNpArray(npRaster) + npRasterCopy = np.array(npRaster) if multiStepFeedback is not None: multiStepFeedback.setCurrentStep(1) multiStepFeedback.pushInfo(self.tr("Creating max feature list from pixel coordinates array...")) @@ -1534,17 +1549,51 @@ def getMinMaxFeatures(self, fields, npRaster, transform, distance, maskLyr, feed defaultAtributeMap=dict(self.defaultAttrMap), ) ) - featSet |= self.filterFeaturesByBuffer(maxFeatList, distance, cotaMaisAlta=True, feedback=multiStepFeedback) + cotaMax = min(f['cota'] for f in maxFeatList) + while True: + maxFeatLyr = LayerHandler().createMemoryLayerWithFeatures( + featList=maxFeatList, + fields=fields, + crs=maskLyr.crs(), + wkbType=QgsWkbTypes.Point, + context=QgsProcessingContext(), + ) + filteredFeatureList = self.filterFeaturesByDistanceAndExclusionLayer( + candidatesPointLyr=maxFeatLyr, + exclusionLyr=maskLyr, + distance=distance, + context=QgsProcessingContext(), + feedback=None, + ) + if filteredFeatureList != []: + featSet |= self.filterFeaturesByBuffer(filteredFeatureList, distance, cotaMaisAlta=True) + break + npRasterCopy[npRasterCopy == cotaMax] = np.nan + maxCoordinatesArray = rasterHandler.getMaxCoordinatesFromNpArray(npRasterCopy) + if maxCoordinatesArray == []: + return list(featSet) + maxFeatList = ( + rasterHandler.createFeatureListWithPixelValuesFromPixelCoordinatesArray( + maxCoordinatesArray, + fieldName="cota", + fields=fields, + npRaster=npRaster, + transform=transform, + defaultAtributeMap=dict(self.defaultAttrMap), + ) + ) + cotaMax -= 1 + if multiStepFeedback is not None and multiStepFeedback.isCanceled(): + break if multiStepFeedback is not None: multiStepFeedback.setCurrentStep(2) multiStepFeedback.pushInfo(self.tr("Getting min coordinates from numpy array...")) - minCoordinatesArray = rasterHandler.getMinCoordinatesFromNpArray(npRaster) + minCoordinatesArray = rasterHandler.getMinCoordinatesFromNpArray(npRasterCopy) if minCoordinatesArray == []: return list(featSet) if multiStepFeedback is not None: multiStepFeedback.setCurrentStep(3) multiStepFeedback.pushInfo(self.tr("Creating min feature list from pixel coordinates array...")) - npRasterCopy = np.array(npRaster) minFeatList = ( rasterHandler.createFeatureListWithPixelValuesFromPixelCoordinatesArray( minCoordinatesArray, diff --git a/DsgTools/core/GeometricTools/rasterHandler.py b/DsgTools/core/GeometricTools/rasterHandler.py index b110167eb..1a070071c 100644 --- a/DsgTools/core/GeometricTools/rasterHandler.py +++ b/DsgTools/core/GeometricTools/rasterHandler.py @@ -79,7 +79,10 @@ def createFeatureWithPixelValueFromPixelCoordinates( newFeat = QgsFeature(fields) terrainCoordinates = transform * pixelCoordinates newFeat.setGeometry(QgsGeometry(QgsPoint(*terrainCoordinates))) - value = npRaster[pixelCoordinates] + try: + value = npRaster[pixelCoordinates] + except: + return None if np.isnan(value): return None newFeat[fieldName] = int(value) From 0d3bb7bcc289b1fb041ffcf8d147afb1e32aaf86 Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 11 Oct 2023 10:20:42 -0300 Subject: [PATCH 28/53] fix --- .../Algs/GeometricAlgs/extractElevationPoints.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py index 1485110b2..b63507023 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/extractElevationPoints.py @@ -151,10 +151,10 @@ def initAlgorithm(self, config=None): 3: 40000, } self.contourBufferLengths = { - 0: 3.2e-4 * 25_000, - 1: 3.2e-4 * 50_000, - 2: 3.2e-4 * 100_000, - 3: 3.2e-4 * 250_000, + 0: 3.2e-3 * 25_000, + 1: 3.2e-3 * 50_000, + 2: 3.2e-3 * 100_000, + 3: 3.2e-3 * 250_000, } self.planeGridSpacingDict = { From dc6f4fd1e88348e83e7cc6a9f164af0c8045ba15 Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 11 Oct 2023 16:41:26 -0300 Subject: [PATCH 29/53] =?UTF-8?q?Vers=C3=A3o=204.11.26:=20Corrige=20crash?= =?UTF-8?q?=20no=20AddUnsharedVertexOnIntersectionsAlgorithm?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 ++- .../addUnsharedVertexOnIntersectionsAlgorithm.py | 2 +- DsgTools/core/GeometricTools/layerHandler.py | 2 +- DsgTools/metadata.txt | 2 +- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ec3411606..52049dbd9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.25 - dev +## 4.11.26 - dev Novas Funcionalidades: @@ -39,6 +39,7 @@ Correção de bug: - Corrige bug na rotina de extrair automaticamente pontos cotados (Extract Spot Elevation); - Corrige bug da interface de carregamento não listar camadas do tipo GEOMETRY (genéricas normalmente criadas pelo FME). A camada que tiver esse tipo vai ser carregada em um nó chamado Geometry; - Corrige bug dos parâmetros do clean não permitirem casas decimais o suficiente; +- Corrige bug de crash no qgis no algoritmo AddUnsharedVertexOnIntersectionsAlgorithm; ## 4.10.1 - 2023-10-02 diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/addUnsharedVertexOnIntersectionsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/addUnsharedVertexOnIntersectionsAlgorithm.py index 945a203c2..677477682 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/addUnsharedVertexOnIntersectionsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/addUnsharedVertexOnIntersectionsAlgorithm.py @@ -179,7 +179,7 @@ def processAlgorithm(self, parameters, context, feedback): return {} multiStepFeedback.setCurrentStep(currentStep) - algRunner.runCreateSpatialIndex(newFlagsLyr, context, multiStepFeedback) + algRunner.runCreateSpatialIndex(newFlagsLyr, context, multiStepFeedback, is_child_algorithm=True) currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) LayerHandler().addVertexesToLayers( diff --git a/DsgTools/core/GeometricTools/layerHandler.py b/DsgTools/core/GeometricTools/layerHandler.py index ea909d82d..5195f9da1 100644 --- a/DsgTools/core/GeometricTools/layerHandler.py +++ b/DsgTools/core/GeometricTools/layerHandler.py @@ -1871,7 +1871,7 @@ def getUnsharedPointsSetFromPointsLyr( return set() multiStepFeedback = QgsProcessingMultiStepFeedback(2, feedback) multiStepFeedback.setCurrentStep(0) - algRunner.runCreateSpatialIndex(linesLyr, context, feedback=multiStepFeedback) + algRunner.runCreateSpatialIndex(linesLyr, context, feedback=multiStepFeedback, is_child_algorithm=True) multiStepFeedback.setCurrentStep(1) def compute(feat): diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index c33adfd9b..5a36f48c6 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.25 +version=4.11.26 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From 2b00a1ea2ef1a383c0d6bda184ebe5abeca471bc Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 11 Oct 2023 17:35:25 -0300 Subject: [PATCH 30/53] bug fix --- DsgTools/core/GeometricTools/spatialRelationsHandler.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/DsgTools/core/GeometricTools/spatialRelationsHandler.py b/DsgTools/core/GeometricTools/spatialRelationsHandler.py index 91415deac..d3ba92797 100644 --- a/DsgTools/core/GeometricTools/spatialRelationsHandler.py +++ b/DsgTools/core/GeometricTools/spatialRelationsHandler.py @@ -647,8 +647,12 @@ def findElevationPointsOutOfThreshold(self, elevationPoints, polygonLyr, contour continue areaId = areaFeat.id() countourList = contourAreaDict['areaContourRelations'][areaId].keys() - h_min = min(countourList) - h_max = max(countourList) + if countourList == [] or countourList is None or len(countourList) == 0: + continue + h_min = min(countourList, default=None) + h_max = max(countourList, default=None) + if h_min is None or h_max is None: + continue if pointHeight == h_min or pointHeight == h_max: continue if (h_min == h_max): From 356d839c86c96b22fc346ec6dad8d44e127530fa Mon Sep 17 00:00:00 2001 From: jossanCosta Date: Thu, 19 Oct 2023 11:45:17 -0300 Subject: [PATCH 31/53] fix --- .../FreeHandTool/controllers/acquisitionFreeController.py | 1 + 1 file changed, 1 insertion(+) diff --git a/DsgTools/gui/ProductionTools/MapTools/FreeHandTool/controllers/acquisitionFreeController.py b/DsgTools/gui/ProductionTools/MapTools/FreeHandTool/controllers/acquisitionFreeController.py index a990887bf..f994bd2a9 100644 --- a/DsgTools/gui/ProductionTools/MapTools/FreeHandTool/controllers/acquisitionFreeController.py +++ b/DsgTools/gui/ProductionTools/MapTools/FreeHandTool/controllers/acquisitionFreeController.py @@ -353,6 +353,7 @@ def addFeatureWithoutForm(self, layer, feature): # Método para adicionar a feição sem formulário # Parâmetro de entrada: layer (Camada ativa), feature (Feição adquirida) layer.beginEditCommand("dsgtools freehand feature added") + self.loadDefaultFields(layer, feature) layer.addFeatures([feature]) layer.removeSelection() layer.endEditCommand() From 406a4605cc57ec68dbe5d503f92186b25cad8b45 Mon Sep 17 00:00:00 2001 From: jossanCosta Date: Fri, 20 Oct 2023 11:16:54 -0300 Subject: [PATCH 32/53] fix --- .../controllers/acquisitionMenuCtrl.py | 6 +++-- .../acquisitionMenu/widgets/menuDock.py | 22 ++++++++++++++++--- 2 files changed, 23 insertions(+), 5 deletions(-) diff --git a/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py b/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py index 51bb41524..8f946d4fb 100644 --- a/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py +++ b/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py @@ -237,7 +237,7 @@ def validLayersToReclassification(self, buttonConfig): layerName, layer.geometryType() ) if not layersToReclassification: - return + raise Exception("Não há camadas para reclassificação!") noActive = False for l in layersToReclassification: noActive = l.id() != iface.activeLayer().id() @@ -258,13 +258,15 @@ def reclassify(self, buttonConfig, reclassifyData): self.qgis.cutAndPasteSelectedFeatures( layer, destinatonLayer, attributes ) + destinatonLayer.triggerRepaint() + def getLayersForReclassification(self, layerName, geometryType): layers = self.qgis.getLoadedVectorLayers() geometryFilterDict = { QgsWkbTypes.PointGeometry: (QgsWkbTypes.PointGeometry, QgsWkbTypes.PolygonGeometry), QgsWkbTypes.LineGeometry: (QgsWkbTypes.LineGeometry, ), - QgsWkbTypes.PolygonGeometry: (QgsWkbTypes.PointGeometry, ), + QgsWkbTypes.PolygonGeometry: (QgsWkbTypes.PolygonGeometry, ), } return [ l diff --git a/DsgTools/Modules/acquisitionMenu/widgets/menuDock.py b/DsgTools/Modules/acquisitionMenu/widgets/menuDock.py index 7807bcbcf..a22cd66bf 100644 --- a/DsgTools/Modules/acquisitionMenu/widgets/menuDock.py +++ b/DsgTools/Modules/acquisitionMenu/widgets/menuDock.py @@ -52,7 +52,7 @@ def getMenuWidget(self): def setCurrentButton(self, buttonConfig): try: - currentActiveLayer = iface.activeLayer() + self.setLastLayer(iface.activeLayer()) if self.reclassifyCkb.isChecked(): self.getController().validLayersToReclassification(buttonConfig) @@ -63,11 +63,27 @@ def setCurrentButton(self, buttonConfig): self.getController().activeMenuButton(buttonConfig) if not self.reclassifyCkb.isChecked(): return - self.getController().openReclassifyDialog(buttonConfig, self.reclassify) - iface.setActiveLayer(currentActiveLayer) + self.getController().openReclassifyDialog( + buttonConfig, + self.callbackReclassify + ) except Exception as e: self.showError("Erro", str(e)) + def setLastLayer(self, layer): + self.lastLayer = layer + + def getLastLayer(self): + return self.lastLayer + + def callbackReclassify(self, data): + self.reclassify(data) + iface.setActiveLayer(self.getLastLayer()) + currentButton = self.getCurrentButtonConfig() + if currentButton: + self.getController().deactiveMenuButton(currentButton) + self.setCurrentButtonConfig(None) + def getCurrentButtonConfig(self): return self.currentButton From d4a752eae6b4d891d382a23662d5f01f98d4641b Mon Sep 17 00:00:00 2001 From: jossanCosta Date: Fri, 20 Oct 2023 11:31:10 -0300 Subject: [PATCH 33/53] update --- CHANGELOG.md | 8 ++++++++ DsgTools/metadata.txt | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 52049dbd9..3db42614e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,13 @@ # CHANGELOG +## 4.11.27 - dev + +Correção de Bug: + +- Corrige bug de quando o usuário tenta reclassificar primitivas não compatíveis utilizando o menu de classificação; +- Corrige bug de quando o usuário tenta classificar com o formulário suprimido; +- Corrige bug de quando o usuário tenta classificar e o camada do botão não estava mudando; + ## 4.11.26 - dev Novas Funcionalidades: diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 5a36f48c6..ebbcecf5b 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.26 +version=4.11.27 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From be0a6fcc67ea61f841b3c9694f77753490b9380c Mon Sep 17 00:00:00 2001 From: jossanCosta Date: Thu, 26 Oct 2023 09:23:38 -0300 Subject: [PATCH 34/53] update menu --- CHANGELOG.md | 6 ++++++ DsgTools/Modules/qgis/controllers/qgisCtrl.py | 4 ++++ DsgTools/metadata.txt | 2 +- 3 files changed, 11 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3db42614e..25ae122e2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # CHANGELOG +## 4.12.0 - dev + +Nova Funcionalidade: + +- Uso da tag "NULL" no atributo do botão do menu para preencher o campo com o valor nulo na atributação e reclassificação. + ## 4.11.27 - dev Correção de Bug: diff --git a/DsgTools/Modules/qgis/controllers/qgisCtrl.py b/DsgTools/Modules/qgis/controllers/qgisCtrl.py index cdb23b222..698962404 100644 --- a/DsgTools/Modules/qgis/controllers/qgisCtrl.py +++ b/DsgTools/Modules/qgis/controllers/qgisCtrl.py @@ -153,6 +153,8 @@ def setDefaultFields(self, layer, attributes, reset=False): elif reset: configField.setExpression("") else: + if attributeValue == "NULL": + configField.setExpression("") if attributeValue != "": configField.setExpression("'{0}'".format(attributeValue)) elif reset: @@ -209,6 +211,8 @@ def attributeFeature(self, feature, layer, attributes): valueMap = self.formatMapValues(config["map"]) if attributeValue in valueMap: feature.setAttribute(indx, valueMap[attributeValue]) + elif attributeValue and attributeValue in ["NULL"]: + feature.setAttribute(indx, None) elif attributeValue and not (attributeValue in ["NULL", "IGNORAR"]): """if re.match('^\@value\(".+"\)$', value): variable = value.split('"')[-2] diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index ebbcecf5b..1e5612c40 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.27 +version=4.12.0 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From 1d08f32bac2d633fbacfdc72590e0da41386c964 Mon Sep 17 00:00:00 2001 From: phborba Date: Thu, 26 Oct 2023 10:27:41 -0300 Subject: [PATCH 35/53] =?UTF-8?q?corrige=20numera=C3=A7=C3=A3o=20do=20vers?= =?UTF-8?q?ionamento?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 19 +++++-------------- DsgTools/metadata.txt | 2 +- 2 files changed, 6 insertions(+), 15 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 25ae122e2..22f314d2b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,20 +1,7 @@ # CHANGELOG -## 4.12.0 - dev -Nova Funcionalidade: - -- Uso da tag "NULL" no atributo do botão do menu para preencher o campo com o valor nulo na atributação e reclassificação. - -## 4.11.27 - dev - -Correção de Bug: - -- Corrige bug de quando o usuário tenta reclassificar primitivas não compatíveis utilizando o menu de classificação; -- Corrige bug de quando o usuário tenta classificar com o formulário suprimido; -- Corrige bug de quando o usuário tenta classificar e o camada do botão não estava mudando; - -## 4.11.26 - dev +## 4.11.28 - dev Novas Funcionalidades: @@ -36,6 +23,7 @@ Melhorias: - A interface de carregamento agora filtra também na coluna de categoria da camada; - O menu de aquisição agora mantém a camada ativa quando reclassifica uma feição no modo de reclassificação; - Adicionado botão de selecionar a camada ativa na barra de ferramentas de revisão; +- Uso da tag "NULL" no atributo do botão do menu para preencher o campo com o valor nulo na atributação e reclassificação. Correção de bug: @@ -54,6 +42,9 @@ Correção de bug: - Corrige bug da interface de carregamento não listar camadas do tipo GEOMETRY (genéricas normalmente criadas pelo FME). A camada que tiver esse tipo vai ser carregada em um nó chamado Geometry; - Corrige bug dos parâmetros do clean não permitirem casas decimais o suficiente; - Corrige bug de crash no qgis no algoritmo AddUnsharedVertexOnIntersectionsAlgorithm; +- Corrige bug de quando o usuário tenta reclassificar primitivas não compatíveis utilizando o menu de classificação; +- Corrige bug de quando o usuário tenta classificar com o formulário suprimido; +- Corrige bug de quando o usuário tenta classificar e o camada do botão não estava mudando; ## 4.10.1 - 2023-10-02 diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 1e5612c40..b5a7738a7 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.12.0 +version=4.11.28 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From bff9073d79a7276ab145ce70795626045f64843f Mon Sep 17 00:00:00 2001 From: phborba Date: Thu, 26 Oct 2023 10:29:07 -0300 Subject: [PATCH 36/53] fix --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 22f314d2b..36ff00a42 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -23,7 +23,7 @@ Melhorias: - A interface de carregamento agora filtra também na coluna de categoria da camada; - O menu de aquisição agora mantém a camada ativa quando reclassifica uma feição no modo de reclassificação; - Adicionado botão de selecionar a camada ativa na barra de ferramentas de revisão; -- Uso da tag "NULL" no atributo do botão do menu para preencher o campo com o valor nulo na atributação e reclassificação. +- Adicionada a opção de uso da tag "NULL" no atributo do botão do menu para preencher o campo com o valor nulo na atributação e reclassificação do menu de aquisição. Correção de bug: From ed65e6a103578944524b25415135f4843274662b Mon Sep 17 00:00:00 2001 From: phborba Date: Thu, 26 Oct 2023 14:03:12 -0300 Subject: [PATCH 37/53] =?UTF-8?q?Vers=C3=A3o=204.11.29:=20nova=20funcional?= =?UTF-8?q?idade=20de=20criar=20grid?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 +- .../createGridFromCoordinatesAlgorithm.py | 211 ++++++++++++++++++ .../dsgtoolsProcessingAlgorithmProvider.py | 2 + DsgTools/metadata.txt | 2 +- 4 files changed, 216 insertions(+), 2 deletions(-) create mode 100644 DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createGridFromCoordinatesAlgorithm.py diff --git a/CHANGELOG.md b/CHANGELOG.md index 36ff00a42..32dbd04b5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,7 @@ # CHANGELOG -## 4.11.28 - dev +## 4.11.29 - dev Novas Funcionalidades: @@ -9,6 +9,7 @@ Novas Funcionalidades: - Novo processo para validar a estrutura do banco de dados em relação ao masterfile; - Novo processo de detectar as mudanças entre dois banco de dados, realizados em dias distintos; - Novo processo de identificar erros de intersecção entre curvas de nível e massas d'água; +- Novo processo de criar grid por meio de informar as coordenadas dos extremos; Melhorias: diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createGridFromCoordinatesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createGridFromCoordinatesAlgorithm.py new file mode 100644 index 000000000..34f6b34e7 --- /dev/null +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createGridFromCoordinatesAlgorithm.py @@ -0,0 +1,211 @@ +# -*- coding: utf-8 -*- +""" +/*************************************************************************** + DsgTools + A QGIS plugin + Brazilian Army Cartographic Production Tools + ------------------- + begin : 2023-10-26 + git sha : $Format:%H$ + copyright : (C) 2023 by Philipe Borba - Cartographic Engineer @ Brazilian Army + email : borba.philipe@eb.mil.br + ***************************************************************************/ + +/*************************************************************************** + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + ***************************************************************************/ +""" +from PyQt5.QtCore import QCoreApplication +from qgis.core import ( + QgsFeature, + QgsFeatureSink, + QgsField, + QgsFields, + QgsProcessing, + QgsProcessingAlgorithm, + QgsProcessingException, + QgsProcessingMultiStepFeedback, + QgsProcessingParameterFeatureSink, + QgsProcessingParameterFeatureSource, + QgsProcessingParameterNumber, + QgsWkbTypes, + QgsProcessingParameterCrs, + QgsRectangle, +) +from qgis.PyQt.Qt import QVariant + +from ...algRunner import AlgRunner + + +class CreateGridFromCoordinatesAlgorithm(QgsProcessingAlgorithm): + X_MIN = "X_MIN" + Y_MIN = "Y_MIN" + X_MAX = "X_MAX" + Y_MAX = "Y_MAX" + CRS = "CRS" + X_GRID_SIZE = "X_GRID_SIZE" + Y_GRID_SIZE = "Y_GRID_SIZE" + OUTPUT = "OUTPUT" + + def initAlgorithm(self, config): + """ + Parameter setting. + """ + + self.addParameter( + QgsProcessingParameterNumber( + self.X_MIN, + self.tr("Min x coordinates"), + defaultValue=0.005, + minValue=0, + type=QgsProcessingParameterNumber.Double, + ) + ) + + self.addParameter( + QgsProcessingParameterNumber( + self.Y_MIN, + self.tr("Min y coordinates"), + defaultValue=0.005, + minValue=0, + type=QgsProcessingParameterNumber.Double, + ) + ) + + self.addParameter( + QgsProcessingParameterNumber( + self.X_MAX, + self.tr("Max x coordinates"), + defaultValue=0.005, + minValue=0, + type=QgsProcessingParameterNumber.Double, + ) + ) + + self.addParameter( + QgsProcessingParameterNumber( + self.Y_MAX, + self.tr("Max y coordinates"), + defaultValue=0.005, + minValue=0, + type=QgsProcessingParameterNumber.Double, + ) + ) + + self.addParameter( + QgsProcessingParameterNumber( + self.X_GRID_SIZE, + self.tr("Grid size on x-axis"), + defaultValue=0.005, + minValue=0, + type=QgsProcessingParameterNumber.Double, + ) + ) + + self.addParameter( + QgsProcessingParameterNumber( + self.Y_GRID_SIZE, + self.tr("Grid size on y-axis"), + defaultValue=0.005, + minValue=0, + type=QgsProcessingParameterNumber.Double, + ) + ) + + self.addParameter(QgsProcessingParameterCrs(self.CRS, self.tr("CRS"))) + + self.addParameter( + QgsProcessingParameterFeatureSink( + self.OUTPUT, self.tr("Grid") + ) + ) + + def processAlgorithm(self, parameters, context, feedback): + """ + Here is where the processing itself takes place. + """ + algRunner = AlgRunner() + + xMin = self.parameterAsDouble(parameters, self.X_MIN, context) + yMin = self.parameterAsDouble(parameters, self.Y_MIN, context) + xMax = self.parameterAsDouble(parameters, self.X_MAX, context) + yMax = self.parameterAsDouble(parameters, self.Y_MAX, context) + + xGridSize = self.parameterAsDouble(parameters, self.X_GRID_SIZE, context) + yGridSize = self.parameterAsDouble(parameters, self.Y_GRID_SIZE, context) + + crs = self.parameterAsCrs(parameters, self.CRS, context) + if crs is None or not crs.isValid(): + raise QgsProcessingException(self.tr("Invalid CRS.")) + + (output_sink, output_sink_id) = self.parameterAsSink( + parameters, + self.OUTPUT, + context, + QgsFields(), + QgsWkbTypes.Polygon, + crs, + ) + multiStepFeedback = QgsProcessingMultiStepFeedback(5, feedback) + multiStepFeedback.setCurrentStep(0) + grid = algRunner.runCreateGrid( + extent=QgsRectangle(xMin, yMin, xMax, yMax, normalize=False), + crs=crs, + hSpacing=xGridSize, + vSpacing=yGridSize, + feedback=multiStepFeedback, + context=context, + ) + list( + map( + lambda x: output_sink.addFeature(x, QgsFeatureSink.FastInsert), + grid.getFeatures(), + ) + ) + + return {"OUTPUT": output_sink_id} + + def name(self): + """ + Returns the algorithm name, used for identifying the algorithm. This + string should be fixed for the algorithm, and must not be localised. + The name should be unique within each provider. Names should contain + lowercase alphanumeric characters only and no spaces or other + formatting characters. + """ + return "creategridfromcoordinatesalgorithm" + + def displayName(self): + """ + Returns the translated algorithm name, which should be used for any + user-visible display of the algorithm name. + """ + return self.tr("Create Grid From Coordinates") + + def group(self): + """ + Returns the name of the group this algorithm belongs to. This string + should be localised. + """ + return self.tr("Grid Algorithms") + + def groupId(self): + """ + Returns the unique ID of the group this algorithm belongs to. This + string should be fixed for the algorithm, and must not be localised. + The group id should be unique within each provider. Group id should + contain lowercase alphanumeric characters only and no spaces or other + formatting characters. + """ + return "DSGTools - Grid Algorithms" + + def tr(self, string): + return QCoreApplication.translate("CreateGridFromCoordinatesAlgorithm", string) + + def createInstance(self): + return CreateGridFromCoordinatesAlgorithm() diff --git a/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py b/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py index 52ce6798d..3fd23be56 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py @@ -33,6 +33,7 @@ from DsgTools.core.DSGToolsProcessingAlgs.Algs.DataManagementAlgs.appendFeaturesToLayerAlgorithm import ( AppendFeaturesToLayerAlgorithm, ) +from DsgTools.core.DSGToolsProcessingAlgs.Algs.OtherAlgs.createGridFromCoordinatesAlgorithm import CreateGridFromCoordinatesAlgorithm from DsgTools.core.DSGToolsProcessingAlgs.Algs.ValidationAlgs.fixSegmentErrorsBetweenLinesAlgorithm import ( FixSegmentErrorsBetweenLinesAlgorithm, ) @@ -620,6 +621,7 @@ def getAlgList(self): AzimuthCalculationAlgorithm(), DetectChangesBetweenGroups(), IdentifyWaterBodyAndContourInconsistencies(), + CreateGridFromCoordinatesAlgorithm(), ] return algList diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index b5a7738a7..e7c6af975 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.28 +version=4.11.29 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From 83960f9a279d9c18e81c2e9fcb3f0902bb4f989a Mon Sep 17 00:00:00 2001 From: jossanCosta Date: Fri, 27 Oct 2023 13:19:13 -0300 Subject: [PATCH 38/53] update --- CHANGELOG.md | 5 +++++ .../controllers/acquisitionMenuCtrl.py | 3 +++ DsgTools/Modules/acquisitionMenu/widgets/menuDock.py | 4 ++++ .../ProductionTools/Toolboxes/toolBoxesGuiManager.py | 11 ++++++++++- DsgTools/metadata.txt | 2 +- 5 files changed, 23 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 32dbd04b5..d1910f00c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # CHANGELOG +## 4.11.30 - dev + +Novas Funcionalidades: + +- Adicionado atalho para ativar/desativar modo reclassificação; ## 4.11.29 - dev diff --git a/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py b/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py index 8f946d4fb..439694837 100644 --- a/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py +++ b/DsgTools/Modules/acquisitionMenu/controllers/acquisitionMenuCtrl.py @@ -184,6 +184,9 @@ def getLoadedVectorLayerNames(self): def getAttributesConfigByLayerName(self, layerName): return self.qgis.getAttributesConfigByLayerName(layerName) + + def clickReclassfyMode(self): + self.menuDock.handleReclassifyMode() if self.menuDock else '' def createMenuDock(self, menuConfigs): self.removeMenuDock() diff --git a/DsgTools/Modules/acquisitionMenu/widgets/menuDock.py b/DsgTools/Modules/acquisitionMenu/widgets/menuDock.py index a22cd66bf..ff8d88d1b 100644 --- a/DsgTools/Modules/acquisitionMenu/widgets/menuDock.py +++ b/DsgTools/Modules/acquisitionMenu/widgets/menuDock.py @@ -3,6 +3,7 @@ import json from DsgTools.Modules.utils.factories.utilsFactory import UtilsFactory from qgis.utils import iface +from qgis import gui class MenuDock(QtWidgets.QDockWidget): @@ -17,6 +18,9 @@ def __init__( self.currentButton = None self.messageFactory = messageFactory if messageFactory is not None else UtilsFactory().createMessageFactory() self.menusCb.currentIndexChanged.connect(self.setCurrentMenu) + + def handleReclassifyMode(self): + self.reclassifyCkb.setChecked( not self.reclassifyCkb.isChecked() ) def showError(self, title, message): errorMessageBox = self.messageFactory.createMessage("ErrorMessageBox") diff --git a/DsgTools/gui/ProductionTools/Toolboxes/toolBoxesGuiManager.py b/DsgTools/gui/ProductionTools/Toolboxes/toolBoxesGuiManager.py index 5ff184db1..fbd76131e 100644 --- a/DsgTools/gui/ProductionTools/Toolboxes/toolBoxesGuiManager.py +++ b/DsgTools/gui/ProductionTools/Toolboxes/toolBoxesGuiManager.py @@ -76,6 +76,14 @@ def initGui(self): parentButton=self.stackButton, ) + self.addTool( + self.acquisitionMenuCtrl.clickReclassfyMode, + "customFeatureToolBox.png", + self.tr("Reclassify Mode"), + parentButton=self.stackButton, + withShortcut=True + ) + self.calcContour = None self.addTool( self.showCalcContourToolbox, @@ -94,7 +102,7 @@ def initGui(self): ) def addTool( - self, callback, iconBaseName, text, setDefaultAction=False, parentButton=None + self, callback, iconBaseName, text, setDefaultAction=False, parentButton=None, withShortcut=False ): action = self.manager.add_action( os.path.join(self.iconBasePath, iconBaseName), @@ -102,6 +110,7 @@ def addTool( callback=callback, add_to_menu=False, add_to_toolbar=False, + withShortcut=withShortcut, parentMenu=self.parentMenu, parentButton=parentButton, ) diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index e7c6af975..17d6118ee 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.29 +version=4.11.30 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From b95c2c91816283e9b93abc6ef53b001a8c55b7fa Mon Sep 17 00:00:00 2001 From: phborba Date: Tue, 31 Oct 2023 14:07:08 -0300 Subject: [PATCH 39/53] =?UTF-8?q?Vers=C3=A3o=204.11.31:=20Corrige=20bug=20?= =?UTF-8?q?na=20interface=20de=20carregamento?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 10 +++------- .../LoadLayersFromServer/loadLayersFromServer.py | 2 +- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d1910f00c..28593997a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,12 +1,6 @@ # CHANGELOG -## 4.11.30 - dev - -Novas Funcionalidades: - -- Adicionado atalho para ativar/desativar modo reclassificação; - -## 4.11.29 - dev +## 4.11.31 - dev Novas Funcionalidades: @@ -15,6 +9,7 @@ Novas Funcionalidades: - Novo processo de detectar as mudanças entre dois banco de dados, realizados em dias distintos; - Novo processo de identificar erros de intersecção entre curvas de nível e massas d'água; - Novo processo de criar grid por meio de informar as coordenadas dos extremos; +- Adicionado atalho para ativar/desativar modo reclassificação; Melhorias: @@ -51,6 +46,7 @@ Correção de bug: - Corrige bug de quando o usuário tenta reclassificar primitivas não compatíveis utilizando o menu de classificação; - Corrige bug de quando o usuário tenta classificar com o formulário suprimido; - Corrige bug de quando o usuário tenta classificar e o camada do botão não estava mudando; +- Corrige bug na interface do carregamento de feições, em bancos não EDGV; ## 4.10.1 - 2023-10-02 diff --git a/DsgTools/gui/LayerTools/LoadLayersFromServer/loadLayersFromServer.py b/DsgTools/gui/LayerTools/LoadLayersFromServer/loadLayersFromServer.py index 94313c38a..62cfdd730 100644 --- a/DsgTools/gui/LayerTools/LoadLayersFromServer/loadLayersFromServer.py +++ b/DsgTools/gui/LayerTools/LoadLayersFromServer/loadLayersFromServer.py @@ -118,7 +118,7 @@ def updateLayersFromDbs(self, type, dbList, showViews=False): dbName ].getGeomColumnTupleList(showViews=showViews) for tableSchema, tableName, geom, geomType, tableType in geomList: - if "EDGV" not in dbName: + if all(k not in dbName for k in ["EDGV", "MUVD", "MGCP", "UTRD", "TRD"]): lyrName = tableName cat = tableSchema else: From 463a221602f5b7c47a87744e08312027a8c9c99a Mon Sep 17 00:00:00 2001 From: phborba Date: Tue, 31 Oct 2023 16:25:56 -0300 Subject: [PATCH 40/53] fix --- .../gui/LayerTools/LoadLayersFromServer/loadLayersFromServer.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DsgTools/gui/LayerTools/LoadLayersFromServer/loadLayersFromServer.py b/DsgTools/gui/LayerTools/LoadLayersFromServer/loadLayersFromServer.py index 62cfdd730..5f65829c3 100644 --- a/DsgTools/gui/LayerTools/LoadLayersFromServer/loadLayersFromServer.py +++ b/DsgTools/gui/LayerTools/LoadLayersFromServer/loadLayersFromServer.py @@ -123,7 +123,7 @@ def updateLayersFromDbs(self, type, dbList, showViews=False): cat = tableSchema else: lyrName = "_".join(tableName.split("_")[1::]) - if lyrName == "": + if lyrName == "" or (lyrName in ["a", "p", "l"] and "EDGV" not in dbName): lyrName = tableName cat = "layers" else: From 9d871b427097b387141a779825ae78c09e5ccf10 Mon Sep 17 00:00:00 2001 From: phborba Date: Tue, 31 Oct 2023 16:53:15 -0300 Subject: [PATCH 41/53] =?UTF-8?q?bug=20fix=20na=20gera=C3=A7=C3=A3o=20de?= =?UTF-8?q?=20grid=20por=20coordenadas?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../createGridFromCoordinatesAlgorithm.py | 32 +++++++++---------- 1 file changed, 15 insertions(+), 17 deletions(-) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createGridFromCoordinatesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createGridFromCoordinatesAlgorithm.py index 34f6b34e7..cd408caf3 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createGridFromCoordinatesAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/OtherAlgs/createGridFromCoordinatesAlgorithm.py @@ -48,8 +48,8 @@ class CreateGridFromCoordinatesAlgorithm(QgsProcessingAlgorithm): X_MAX = "X_MAX" Y_MAX = "Y_MAX" CRS = "CRS" - X_GRID_SIZE = "X_GRID_SIZE" - Y_GRID_SIZE = "Y_GRID_SIZE" + N_TILES_X = "N_TILES_X" + N_TILES_Y = "N_TILES_Y" OUTPUT = "OUTPUT" def initAlgorithm(self, config): @@ -62,7 +62,6 @@ def initAlgorithm(self, config): self.X_MIN, self.tr("Min x coordinates"), defaultValue=0.005, - minValue=0, type=QgsProcessingParameterNumber.Double, ) ) @@ -72,7 +71,6 @@ def initAlgorithm(self, config): self.Y_MIN, self.tr("Min y coordinates"), defaultValue=0.005, - minValue=0, type=QgsProcessingParameterNumber.Double, ) ) @@ -82,7 +80,6 @@ def initAlgorithm(self, config): self.X_MAX, self.tr("Max x coordinates"), defaultValue=0.005, - minValue=0, type=QgsProcessingParameterNumber.Double, ) ) @@ -92,28 +89,27 @@ def initAlgorithm(self, config): self.Y_MAX, self.tr("Max y coordinates"), defaultValue=0.005, - minValue=0, type=QgsProcessingParameterNumber.Double, ) ) self.addParameter( QgsProcessingParameterNumber( - self.X_GRID_SIZE, - self.tr("Grid size on x-axis"), - defaultValue=0.005, + self.N_TILES_X, + self.tr("Number of subdivisions on x"), + defaultValue=2, minValue=0, - type=QgsProcessingParameterNumber.Double, + type=QgsProcessingParameterNumber.Integer, ) ) self.addParameter( QgsProcessingParameterNumber( - self.Y_GRID_SIZE, - self.tr("Grid size on y-axis"), - defaultValue=0.005, - minValue=0, - type=QgsProcessingParameterNumber.Double, + self.N_TILES_Y, + self.tr("Number of subdivisions on y"), + defaultValue=2, + minValue=1, + type=QgsProcessingParameterNumber.Integer, ) ) @@ -136,8 +132,8 @@ def processAlgorithm(self, parameters, context, feedback): xMax = self.parameterAsDouble(parameters, self.X_MAX, context) yMax = self.parameterAsDouble(parameters, self.Y_MAX, context) - xGridSize = self.parameterAsDouble(parameters, self.X_GRID_SIZE, context) - yGridSize = self.parameterAsDouble(parameters, self.Y_GRID_SIZE, context) + nTilesX = self.parameterAsDouble(parameters, self.N_TILES_X, context) + nTilesY = self.parameterAsDouble(parameters, self.N_TILES_Y, context) crs = self.parameterAsCrs(parameters, self.CRS, context) if crs is None or not crs.isValid(): @@ -153,6 +149,8 @@ def processAlgorithm(self, parameters, context, feedback): ) multiStepFeedback = QgsProcessingMultiStepFeedback(5, feedback) multiStepFeedback.setCurrentStep(0) + xGridSize = abs(xMax-xMin)/nTilesX + yGridSize = abs(yMax-yMin)/nTilesY grid = algRunner.runCreateGrid( extent=QgsRectangle(xMin, yMin, xMax, yMax, normalize=False), crs=crs, From f70f12e2de226aad28805443bd462c2e73c77af1 Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 1 Nov 2023 13:05:24 -0300 Subject: [PATCH 42/53] =?UTF-8?q?Vers=C3=A3o=204.11.32:=20Corrige=20bug=20?= =?UTF-8?q?no=20processo=20de=20identifica=C3=A7=C3=A3o=20de=20geometria?= =?UTF-8?q?=20inv=C3=A1lida?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 ++- DsgTools/core/GeometricTools/layerHandler.py | 4 +--- DsgTools/metadata.txt | 2 +- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 28593997a..118ca23cb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.31 - dev +## 4.11.32 - dev Novas Funcionalidades: @@ -47,6 +47,7 @@ Correção de bug: - Corrige bug de quando o usuário tenta classificar com o formulário suprimido; - Corrige bug de quando o usuário tenta classificar e o camada do botão não estava mudando; - Corrige bug na interface do carregamento de feições, em bancos não EDGV; +- Corrige bug no processo de geometria inválida quando há geometria nula ou vazia; ## 4.10.1 - 2023-10-02 diff --git a/DsgTools/core/GeometricTools/layerHandler.py b/DsgTools/core/GeometricTools/layerHandler.py index 5195f9da1..882ef81dd 100644 --- a/DsgTools/core/GeometricTools/layerHandler.py +++ b/DsgTools/core/GeometricTools/layerHandler.py @@ -1420,9 +1420,7 @@ def evaluate(feat): def checkGeomIsValid(self, geom, ignoreClosed, feedback=None): flagDict = dict() if geom is None or geom.isNull() or geom.isEmpty(): - return { - "" - } + return {} for validate_type, method_parameter in { "GEOS": Qgis.GeometryValidationEngine.Geos, "QGIS": Qgis.GeometryValidationEngine.QgisInternal, diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 17d6118ee..168c1cb0c 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.30 +version=4.11.32 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From 8b07d57e85e965268df83bab1ba184324bca3ea0 Mon Sep 17 00:00:00 2001 From: Pedro Martins Date: Mon, 6 Nov 2023 10:09:02 -0300 Subject: [PATCH 43/53] =?UTF-8?q?Vers=C3=A3o=204.11.33:=20Fix=20bug=20iden?= =?UTF-8?q?tify=20attr=20unicode?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 ++- .../Algs/ValidationAlgs/unicodeFilterAlgorithm.py | 2 +- DsgTools/metadata.txt | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 118ca23cb..bdad7a0c6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.32 - dev +## 4.11.33 - dev Novas Funcionalidades: @@ -48,6 +48,7 @@ Correção de bug: - Corrige bug de quando o usuário tenta classificar e o camada do botão não estava mudando; - Corrige bug na interface do carregamento de feições, em bancos não EDGV; - Corrige bug no processo de geometria inválida quando há geometria nula ou vazia; +- Corrige bug no processo de verificar atributo unicode (não estava gerando flag por erro de definição de geometria da camada); ## 4.10.1 - 2023-10-02 diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/unicodeFilterAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/unicodeFilterAlgorithm.py index 673473fbc..ec3d95c6b 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/unicodeFilterAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/unicodeFilterAlgorithm.py @@ -144,7 +144,7 @@ def getOutputDict(self, parameters, context, fields): parameters, context, self.OUTPUT3, QgsWkbTypes.MultiPolygon, fields ) returnDict[self.OUTPUT3] = polygon_sink_id - sinkDict[QgsWkbTypes.MultiPolygon] = polygon_sink + sinkDict[QgsWkbTypes.PolygonGeometry] = polygon_sink return returnDict, sinkDict diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 168c1cb0c..37c0f711b 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.32 +version=4.11.33 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From 7aa8cc70b32f3d02f921b40021eda032edae8bef Mon Sep 17 00:00:00 2001 From: phborba Date: Tue, 7 Nov 2023 12:26:26 -0300 Subject: [PATCH 44/53] =?UTF-8?q?Version=204.11.34:=20Bug=20fix=20no=20par?= =?UTF-8?q?=C3=A2metro=20do=20IdentifyTerrainModelErrorsAlgorithm?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 ++- .../identifyTerrainModelErrorsAlgorithm.py | 12 +++++++----- DsgTools/metadata.txt | 2 +- 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bdad7a0c6..dc32e0e6d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.33 - dev +## 4.11.34 - dev Novas Funcionalidades: @@ -49,6 +49,7 @@ Correção de bug: - Corrige bug na interface do carregamento de feições, em bancos não EDGV; - Corrige bug no processo de geometria inválida quando há geometria nula ou vazia; - Corrige bug no processo de verificar atributo unicode (não estava gerando flag por erro de definição de geometria da camada); +- Corrige bug em parâmetro do algoritmo de verificação de regras de construção do terreno; ## 4.10.1 - 2023-10-02 diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyTerrainModelErrorsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyTerrainModelErrorsAlgorithm.py index 4890be9a7..4b6575aab 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyTerrainModelErrorsAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/identifyTerrainModelErrorsAlgorithm.py @@ -67,6 +67,7 @@ def initAlgorithm(self, config): self.INPUT, self.tr("Input contour layer"), [QgsProcessing.TypeVectorLine], + defaultValue="elemnat_curva_nivel_l", ) ) self.addParameter( @@ -78,7 +79,7 @@ def initAlgorithm(self, config): QgsProcessingParameterField( self.CONTOUR_ATTR, self.tr("Contour value field"), - None, + "cota", "INPUT", QgsProcessingParameterField.Any, ) @@ -95,9 +96,9 @@ def initAlgorithm(self, config): QgsProcessingParameterField( self.ELEVATION_POINT_ATTR, self.tr("Spot elevation height value field"), - None, - "INPUT_SPOT_ELEVATION", - QgsProcessingParameterField.Any, + "cota", + self.INPUT_SPOT_ELEVATION, + QgsProcessingParameterField.Numeric, optional=True, ) ) @@ -112,12 +113,13 @@ def initAlgorithm(self, config): self.tr("Geographic bounds layer"), [QgsProcessing.TypeVectorPolygon], optional=False, + defaultValue="aux_moldura_a", ) ) self.addParameter( QgsProcessingParameterBoolean( self.GROUP_BY_SPATIAL_PARTITION, - self.tr("Run algothimn grouping by spatial partition"), + self.tr("Run algorithmn grouping by spatial partition"), ) ) self.addParameter( diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 37c0f711b..5903abbe1 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.33 +version=4.11.34 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From ddff29f907bd5277688025ad54892c1ebcfae2f6 Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 8 Nov 2023 10:22:11 -0300 Subject: [PATCH 45/53] =?UTF-8?q?Vers=C3=A3o=204.11.35:=20Melhoria=20no=20?= =?UTF-8?q?processing=20de=20carregar=20shapefile?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 5 ++- .../loadShapefileAlgorithm.py | 40 +++++++++++++------ DsgTools/metadata.txt | 2 +- 3 files changed, 31 insertions(+), 16 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index dc32e0e6d..47b905de0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.34 - dev +## 4.11.35 - dev Novas Funcionalidades: @@ -24,7 +24,8 @@ Melhorias: - A interface de carregamento agora filtra também na coluna de categoria da camada; - O menu de aquisição agora mantém a camada ativa quando reclassifica uma feição no modo de reclassificação; - Adicionado botão de selecionar a camada ativa na barra de ferramentas de revisão; -- Adicionada a opção de uso da tag "NULL" no atributo do botão do menu para preencher o campo com o valor nulo na atributação e reclassificação do menu de aquisição. +- Adicionada a opção de uso da tag "NULL" no atributo do botão do menu para preencher o campo com o valor nulo na atributação e reclassificação do menu de aquisição; +- O processo de carregar shapefiles agora agrupa por pasta, caso seja dado como entrada uma pasta que possui pastas com shapefiles; Correção de bug: diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadShapefileAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadShapefileAlgorithm.py index 7dabfb131..f27cb3fa8 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadShapefileAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/loadShapefileAlgorithm.py @@ -22,6 +22,8 @@ """ import os +from pathlib import Path + from PyQt5.QtCore import QCoreApplication from qgis.core import ( QgsProcessingAlgorithm, @@ -57,33 +59,42 @@ def initAlgorithm(self, config): def processAlgorithm(self, parameters, context, feedback): folderPath = self.parameterAsString(parameters, self.FOLDER_SHAPEFILES, context) + folder_pathlib_obj = Path(folderPath) output = [] + file_iter = folder_pathlib_obj.glob('*/*.shp') \ + if len(list(folder_pathlib_obj.glob('*/*.shp'))) > 0 \ + else folder_pathlib_obj.glob('*.shp') shapefileData = [ - {"name": fileName.split(".")[0], "path": os.path.join(folderPath, fileName)} - for fileName in os.listdir(folderPath) - if fileName.split(".")[1] == "shp" + {"name": p.stem, "path": p, "parent_folder": p.parent.stem} + for p in file_iter ] - shapefileData = sorted(shapefileData, key=lambda k: k["name"]) + shapefileData = sorted(shapefileData, key=lambda k: (k["parent_folder"], k["name"])) + groupDict = dict() + rootNodeList = [] + parentFolderSet = set(i["parent_folder"] for i in shapefileData) listSize = len(shapefileData) progressStep = 100 / listSize if listSize else 0 - rootNode = QgsProject.instance().layerTreeRoot().addGroup("shapefiles") - groups = { - QgsWkbTypes.PointGeometry: self.createGroup("Ponto", rootNode), - QgsWkbTypes.LineGeometry: self.createGroup("Linha", rootNode), - QgsWkbTypes.PolygonGeometry: self.createGroup("Area", rootNode), - } + for rootNodeName in sorted(parentFolderSet): + rootNode = QgsProject.instance().layerTreeRoot().addGroup(rootNodeName) + rootNodeList.append(rootNode) + groupDict[rootNodeName] = { + QgsWkbTypes.PointGeometry: self.createGroup("Ponto", rootNode), + QgsWkbTypes.LineGeometry: self.createGroup("Linha", rootNode), + QgsWkbTypes.PolygonGeometry: self.createGroup("Area", rootNode), + } for step, data in enumerate(shapefileData): if feedback.isCanceled(): break iface.mapCanvas().freeze(True) ml = QgsProject.instance().addMapLayer( - QgsVectorLayer(data["path"], data["name"], "ogr"), addToLegend=False + QgsVectorLayer(str(data["path"]), data["name"], "ogr"), addToLegend=False ) - groups[QgsWkbTypes.geometryType(ml.wkbType())].addLayer(ml) + groupDict[data["parent_folder"]][QgsWkbTypes.geometryType(ml.wkbType())].addLayer(ml) output.append(ml.id()) iface.mapCanvas().freeze(False) feedback.setProgress(step * progressStep) - self.removeEmptyGroups(list(groups.values()), rootNode) + for rootNode in rootNodeList: + self.removeEmptyGroups(list(groupDict[rootNode.name()].values()), rootNode) return {self.OUTPUT: output} def createGroup(self, groupName, rootNode): @@ -147,3 +158,6 @@ def flags(self): method from QgsLayerTreeGroup is not thread safe. """ return super().flags() | QgsProcessingAlgorithm.FlagNoThreading + + def shortHelpString(self): + return self.tr("This algorithm loads shapefiles from folders. If a folder with subfolders is selected, one extra node is created for each subfolder") diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 5903abbe1..298c6fd5d 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.34 +version=4.11.35 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From e16782c14a1700304a5f750572cd2d50040f9067 Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 8 Nov 2023 10:58:38 -0300 Subject: [PATCH 46/53] =?UTF-8?q?Vers=C3=A3o=204.11.36:=20novo=20processo?= =?UTF-8?q?=20de=20criar=20pacote=20de=20carga=20no=20bdgex?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 +- .../buildZipPackagesAlgorithm.py | 153 ++++++++++++++++++ .../dsgtoolsProcessingAlgorithmProvider.py | 2 + DsgTools/metadata.txt | 2 +- 4 files changed, 158 insertions(+), 2 deletions(-) create mode 100644 DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/buildZipPackagesAlgorithm.py diff --git a/CHANGELOG.md b/CHANGELOG.md index 47b905de0..0638b8e60 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.35 - dev +## 4.11.36 - dev Novas Funcionalidades: @@ -10,6 +10,7 @@ Novas Funcionalidades: - Novo processo de identificar erros de intersecção entre curvas de nível e massas d'água; - Novo processo de criar grid por meio de informar as coordenadas dos extremos; - Adicionado atalho para ativar/desativar modo reclassificação; +- Novo processo de criar pacote de shapefile (utilizado normalmente para preparar a carga no BDGEx); Melhorias: diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/buildZipPackagesAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/buildZipPackagesAlgorithm.py new file mode 100644 index 000000000..573fc9074 --- /dev/null +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/LayerManagementAlgs/buildZipPackagesAlgorithm.py @@ -0,0 +1,153 @@ +# -*- coding: utf-8 -*- +""" +/*************************************************************************** + DsgTools + A QGIS plugin + Brazilian Army Cartographic Production Tools + ------------------- + begin : 2023-11-08 + git sha : $Format:%H$ + copyright : (C) 2023 by Philipe Borba - Cartographic Engineer @ Brazilian Army + email : borba.philipe@eb.mil.br + ***************************************************************************/ + +/*************************************************************************** + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + ***************************************************************************/ +""" +import os + +from pathlib import Path +import zipfile + +from PyQt5.QtCore import QCoreApplication +from qgis.core import ( + QgsProcessingAlgorithm, + QgsProcessingParameterString, + QgsProcessingParameterFile, +) + + +class BuildZipPackageAlgorithm(QgsProcessingAlgorithm): + + INPUT_SHAPEFILE_FOLDER = "INPUT_SHAPEFILE_FOLDER" + OUTPUT_PREFIX = "OUTPUT_PREFIX" + OUTPUT_ZIP_FOLDER = "OUTPUT_ZIP_FOLDER" + + def __init__(self): + super().__init__() + + def initAlgorithm(self, config): + self.addParameter( + QgsProcessingParameterFile( + self.INPUT_SHAPEFILE_FOLDER, + self.tr("Pasta com Shapefiles"), + behavior=QgsProcessingParameterFile.Folder, + ) + ) + + self.addParameter( + QgsProcessingParameterString( + self.OUTPUT_PREFIX, + description=self.tr("Output files prefix"), + multiLine=False, + defaultValue="Carta_Topografica_", + optional=True, + ) + ) + + self.addParameter( + QgsProcessingParameterFile( + self.OUTPUT_ZIP_FOLDER, + self.tr("Pasta de destino"), + behavior=QgsProcessingParameterFile.Folder, + ) + ) + + + + def processAlgorithm(self, parameters, context, feedback): + folderPath = self.parameterAsString(parameters, self.INPUT_SHAPEFILE_FOLDER, context) + outputPrefix = self.parameterAsString(parameters, self.OUTPUT_PREFIX, context) + outputFolderPath = self.parameterAsString(parameters, self.OUTPUT_ZIP_FOLDER, context) + p = Path(folderPath) + folderList = [f.stem for f in p.iterdir() if f.is_dir()] + if len(folderList) == 0: + return {} + stepSize = 100/len(folderList) + for current, folderName in enumerate(folderList): + if feedback.isCanceled(): + break + outputZipName = f"{outputPrefix}{folderName}" + with zipfile.ZipFile( + Path(outputFolderPath, f'{outputZipName}.zip'), 'w', zipfile.ZIP_DEFLATED + ) as zf: + for item in Path(p / folderName).glob("*"): + if '.DS_Store' in str(item) or '__MACOSX/' in str(item): + continue + zf.write(item, Path(folderName / item.relative_to(os.path.dirname(item)))) + + feedback.setProgress(current * stepSize) + return {} + + + def name(self): + """ + Returns the algorithm name, used for identifying the algorithm. This + string should be fixed for the algorithm, and must not be localised. + The name should be unique within each provider. Names should contain + lowercase alphanumeric characters only and no spaces or other + formatting characters. + """ + return "buildzippackagealgorithm" + + def displayName(self): + """ + Returns the translated algorithm name, which should be used for any + user-visible display of the algorithm name. + """ + return self.tr("Builds shapefile package") + + def group(self): + """ + Returns the name of the group this algorithm belongs to. This string + should be localised. + """ + return self.tr("Layer Management Algorithms") + + def groupId(self): + """ + Returns the unique ID of the group this algorithm belongs to. This + string should be fixed for the algorithm, and must not be localised. + The group id should be unique within each provider. Group id should + contain lowercase alphanumeric characters only and no spaces or other + formatting characters. + """ + return "DSGTools - Layer Management Algorithms" + + def tr(self, string): + """ + Translates input string. + """ + return QCoreApplication.translate("BuildZipPackageAlgorithm", string) + + def createInstance(self): + """ + Creates an instance of this class + """ + return BuildZipPackageAlgorithm() + + def flags(self): + """ + This process is not thread safe due to the fact that removeChildNode + method from QgsLayerTreeGroup is not thread safe. + """ + return super().flags() | QgsProcessingAlgorithm.FlagNoThreading + + def shortHelpString(self): + return self.tr("This algorithm loads shapefiles from folders. If a folder with subfolders is selected, one extra node is created for each subfolder") diff --git a/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py b/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py index 3fd23be56..153c9199d 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py @@ -33,6 +33,7 @@ from DsgTools.core.DSGToolsProcessingAlgs.Algs.DataManagementAlgs.appendFeaturesToLayerAlgorithm import ( AppendFeaturesToLayerAlgorithm, ) +from DsgTools.core.DSGToolsProcessingAlgs.Algs.LayerManagementAlgs.buildZipPackagesAlgorithm import BuildZipPackageAlgorithm from DsgTools.core.DSGToolsProcessingAlgs.Algs.OtherAlgs.createGridFromCoordinatesAlgorithm import CreateGridFromCoordinatesAlgorithm from DsgTools.core.DSGToolsProcessingAlgs.Algs.ValidationAlgs.fixSegmentErrorsBetweenLinesAlgorithm import ( FixSegmentErrorsBetweenLinesAlgorithm, @@ -622,6 +623,7 @@ def getAlgList(self): DetectChangesBetweenGroups(), IdentifyWaterBodyAndContourInconsistencies(), CreateGridFromCoordinatesAlgorithm(), + BuildZipPackageAlgorithm(), ] return algList diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 298c6fd5d..b280c4bb1 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.35 +version=4.11.36 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From d6cb222453b0fea2854417f32b80f5d47796afe2 Mon Sep 17 00:00:00 2001 From: phborba Date: Mon, 27 Nov 2023 22:02:26 -0300 Subject: [PATCH 47/53] primeiro commit --- ...neralizeNetworkEdgesFromLengthAlgorithm.py | 220 ++++++++++++++++++ DsgTools/core/GeometricTools/graphHandler.py | 70 ++++++ 2 files changed, 290 insertions(+) create mode 100644 DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py new file mode 100644 index 000000000..96a5f542f --- /dev/null +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py @@ -0,0 +1,220 @@ +# -*- coding: utf-8 -*- +""" +/*************************************************************************** + DsgTools + A QGIS plugin + Brazilian Army Cartographic Production Tools + ------------------- + begin : 2023-11-27 + git sha : $Format:%H$ + copyright : (C) 2023 by Philipe Borba - Cartographic Engineer @ Brazilian Army + email : borba.philipe@eb.mil.br + ***************************************************************************/ + +/*************************************************************************** + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + ***************************************************************************/ +""" + +from collections import defaultdict +from typing import Dict, Set, Tuple +from PyQt5.QtCore import QCoreApplication +from DsgTools.core.GeometricTools import graphHandler +from qgis.PyQt.QtCore import QByteArray +from qgis.core import ( + Qgis, + QgsProcessing, + QgsProcessingException, + QgsProcessingMultiStepFeedback, + QgsProcessingParameterEnum, + QgsProcessingParameterVectorLayer, + QgsWkbTypes, + QgsFeedback, + QgsProcessingContext, + QgsGeometry, + QgsFeature, + QgsVectorLayer, + QgsProcessingParameterNumber, + QgsProcessingParameterBoolean, +) + +from ...algRunner import AlgRunner +from ..ValidationAlgs.validationAlgorithm import ValidationAlgorithm + + +class GeneralizeNetworkEdgesWithLengthAlgorithm(ValidationAlgorithm): + NETWORK_LAYER = "NETWORK_LAYER" + MIN_LENGTH = "MIN_LENGTH" + GEOGRAPHIC_BOUNDS_LAYER = "GEOGRAPHIC_BOUNDS_LAYER" + WATER_BODIES_LAYER = "WATER_BODIES_LAYER" + METHOD = "METHOD" + + def initAlgorithm(self, config): + """ + Parameter setting. + """ + self.addParameter( + QgsProcessingParameterVectorLayer( + self.NETWORK_LAYER, + self.tr("Network layer"), + [QgsProcessing.TypeVectorLine], + ) + ) + self.addParameter( + QgsProcessingParameterNumber( + self.MIN_LENGTH, + self.tr("Minimum size"), + minValue=0, + type=QgsProcessingParameterNumber.Double, + defaultValue=0.001, + ) + ) + self.addParameter( + QgsProcessingParameterVectorLayer( + self.WATER_BODIES_LAYER, + self.tr("Water bodies layer"), + [QgsProcessing.TypeVectorPolygon], + optional=True, + ) + ) + self.addParameter( + QgsProcessingParameterVectorLayer( + self.GEOGRAPHIC_BOUNDS_LAYER, + self.tr("Reference layer"), + [QgsProcessing.TypeVectorPolygon], + optional=True, + ) + ) + self.selectionIdDict = { + 1: Qgis.SelectBehavior.SetSelection, + 2: Qgis.SelectBehavior.AddToSelection, + 3: Qgis.SelectBehavior.IntersectSelection, + 4: Qgis.SelectBehavior.RemoveFromSelection, + } + self.method = [ + self.tr("Remove features from input layer"), + self.tr("Modify current selection by creating new selection"), + self.tr("Modify current selection by adding to current selection"), + self.tr("Modify current selection by selecting within current selection"), + self.tr("Modify current selection by removing from current selection"), + ] + + self.addParameter( + QgsProcessingParameterEnum( + self.METHOD, self.tr("Method"), options=self.method, defaultValue=0 + ) + ) + + def processAlgorithm(self, parameters, context, feedback): + """ + Here is where the processing itself takes place. + """ + try: + import networkx as nx + except ImportError: + raise QgsProcessingException( + self.tr( + "This algorithm requires the Python networkx library. Please install this library and try again." + ) + ) + # get the network handler + self.algRunner = AlgRunner() + networkLayer = self.parameterAsLayer(parameters, self.NETWORK_LAYER, context) + filterExpression = self.parameterAsExpression( + parameters, self.FILTER_EXPRESSION, context + ) + if filterExpression == "": + filterExpression = None + oceanLayer = self.parameterAsLayer(parameters, self.WATER_BODIES_LAYER, context) + waterBodyWithFlowLayer = self.parameterAsLayer( + parameters, self.WATER_BODY_WITH_FLOW_LAYER, context + ) + waterSinkLayer = self.parameterAsLayer(parameters, self.SINK_LAYER, context) + geographicBoundsLayer = self.parameterAsLayer( + parameters, self.GEOGRAPHIC_BOUNDS_LAYER, context + ) + nSteps = ( + 15 + + (runFlowCheck is True) + + (runLoopCheck is True) + + (waterBodyWithFlowLayer is not None) + ) + multiStepFeedback = QgsProcessingMultiStepFeedback(nSteps, feedback) + currentStep = 0 + multiStepFeedback.setCurrentStep(currentStep) + multiStepFeedback.setProgressText(self.tr("Building aux structures")) + localCache, nodesLayer = graphHandler.buildAuxLayersPriorGraphBuilding( + networkLayer=networkLayer, + context=context, + geographicBoundsLayer=geographicBoundsLayer, + feedback=multiStepFeedback, + ) + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + multiStepFeedback.setProgressText(self.tr("Building graph aux structures")) + ( + nodeDict, + nodeIdDict, + edgeDict, + hashDict, + networkBidirectionalGraph, + nodeLayerIdDict, + ) = graphHandler.buildAuxStructures( + nx, + nodesLayer=nodesLayer, + edgesLayer=localCache, + feedback=multiStepFeedback, + useWkt=False, + computeNodeLayerIdDict=True, + addEdgeLength=True, + ) + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + return {} + + def name(self): + """ + Returns the algorithm name, used for identifying the algorithm. This + string should be fixed for the algorithm, and must not be localised. + The name should be unique within each provider. Names should contain + lowercase alphanumeric characters only and no spaces or other + formatting characters. + """ + return "generalizenetworkedgeswithlengthalgorithm" + + def displayName(self): + """ + Returns the translated algorithm name, which should be used for any + user-visible display of the algorithm name. + """ + return self.tr("Generalize Network Edges With Length Algorithm") + + def group(self): + """ + Returns the name of the group this algorithm belongs to. This string + should be localised. + """ + return self.tr("Generalization Algorithms") + + def groupId(self): + """ + Returns the unique ID of the group this algorithm belongs to. This + string should be fixed for the algorithm, and must not be localised. + The group id should be unique within each provider. Group id should + contain lowercase alphanumeric characters only and no spaces or other + formatting characters. + """ + return "DSGTools - Generalization Algorithms" + + def tr(self, string): + return QCoreApplication.translate( + "GeneralizeNetworkEdgesWithLengthAlgorithm", string + ) + + def createInstance(self): + return GeneralizeNetworkEdgesWithLengthAlgorithm() diff --git a/DsgTools/core/GeometricTools/graphHandler.py b/DsgTools/core/GeometricTools/graphHandler.py index 7698630cd..1498c3bfc 100644 --- a/DsgTools/core/GeometricTools/graphHandler.py +++ b/DsgTools/core/GeometricTools/graphHandler.py @@ -39,8 +39,11 @@ QgsProcessingMultiStepFeedback, QgsVectorLayer, QgsFeedback, + QgsProcessingContext, ) +from DsgTools.core.DSGToolsProcessingAlgs.algRunner import AlgRunner + def fetch_connected_nodes( G, node: int, max_degree: int, feedback: Optional[QgsFeedback] = None @@ -893,3 +896,70 @@ def identify_unmerged_edges_on_graph( continue outputIdSet.add(nodeId) return outputIdSet + + +def buildAuxLayersPriorGraphBuilding( + networkLayer, context=None, geographicBoundsLayer=None, feedback=None +): + algRunner = AlgRunner() + nSteps = 6 if geographicBoundsLayer is not None else 4 + multiStepFeedback = ( + QgsProcessingMultiStepFeedback(nSteps, feedback) + if feedback is not None + else None + ) + context = QgsProcessingContext() if context is None else context + currentStep = 0 + if multiStepFeedback is not None: + multiStepFeedback.setCurrentStep(currentStep) + localCache = algRunner.runCreateFieldWithExpression( + inputLyr=networkLayer, + expression="$id", + fieldName="featid", + fieldType=1, + context=context, + feedback=multiStepFeedback, + ) + currentStep += 1 + if geographicBoundsLayer is not None: + if multiStepFeedback is not None: + multiStepFeedback.setCurrentStep(currentStep) + algRunner.runCreateSpatialIndex( + inputLyr=localCache, context=context, feedback=multiStepFeedback + ) + currentStep += 1 + if multiStepFeedback is not None: + multiStepFeedback.setCurrentStep(currentStep) + localCache = algRunner.runExtractByLocation( + inputLyr=localCache, + intersectLyr=geographicBoundsLayer, + context=context, + feedback=multiStepFeedback, + ) + currentStep += 1 + if multiStepFeedback is not None: + multiStepFeedback.setCurrentStep(currentStep) + algRunner.runCreateSpatialIndex( + inputLyr=localCache, context=context, feedback=multiStepFeedback + ) + currentStep += 1 + if multiStepFeedback is not None: + multiStepFeedback.setCurrentStep(currentStep) + nodesLayer = algRunner.runExtractSpecificVertices( + inputLyr=localCache, + vertices="0,-1", + context=context, + feedback=multiStepFeedback, + ) + currentStep += 1 + if multiStepFeedback is not None: + multiStepFeedback.setCurrentStep(currentStep) + nodesLayer = algRunner.runCreateFieldWithExpression( + inputLyr=nodesLayer, + expression="$id", + fieldName="nfeatid", + fieldType=1, + context=context, + feedback=multiStepFeedback, + ) + return localCache, nodesLayer From 1089a1634f48f7bb9551b0416e2a0be3e033221d Mon Sep 17 00:00:00 2001 From: phborba Date: Tue, 28 Nov 2023 14:10:19 -0300 Subject: [PATCH 48/53] =?UTF-8?q?Vers=C3=A3o=204.11.37:=20Novo=20algoritmo?= =?UTF-8?q?=20de=20generaliza=C3=A7=C3=A3o=20de=20linhas?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 +- .../Algs/GeneralizationAlgs/__init__.py | 0 ...neralizeNetworkEdgesFromLengthAlgorithm.py | 136 +++++++++++--- .../reclassifyAdjecentPolygonsAlgorithm.py | 0 .../splitPolygonsAlgorithm.py | 0 .../splitPolygonsByGrid.py | 0 .../ValidationAlgs/fixNetworkAlgorithm.py | 13 -- .../dsgtoolsProcessingAlgorithmProvider.py | 8 +- DsgTools/core/GeometricTools/graphHandler.py | 169 +++++++++++++++++- DsgTools/metadata.txt | 2 +- 10 files changed, 279 insertions(+), 52 deletions(-) create mode 100644 DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/__init__.py rename DsgTools/core/DSGToolsProcessingAlgs/Algs/{GeometricAlgs => GeneralizationAlgs}/generalizeNetworkEdgesFromLengthAlgorithm.py (60%) rename DsgTools/core/DSGToolsProcessingAlgs/Algs/{GeometricAlgs => GeneralizationAlgs}/reclassifyAdjecentPolygonsAlgorithm.py (100%) rename DsgTools/core/DSGToolsProcessingAlgs/Algs/{GeometricAlgs => GeneralizationAlgs}/splitPolygonsAlgorithm.py (100%) rename DsgTools/core/DSGToolsProcessingAlgs/Algs/{GeometricAlgs => GeneralizationAlgs}/splitPolygonsByGrid.py (100%) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0638b8e60..9734bf115 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.36 - dev +## 4.11.37 - dev Novas Funcionalidades: @@ -11,6 +11,7 @@ Novas Funcionalidades: - Novo processo de criar grid por meio de informar as coordenadas dos extremos; - Adicionado atalho para ativar/desativar modo reclassificação; - Novo processo de criar pacote de shapefile (utilizado normalmente para preparar a carga no BDGEx); +- Novo processo de generalizar trechos de drenagem de acordo com o comprimento; Melhorias: diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/__init__.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py similarity index 60% rename from DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py rename to DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py index 96a5f542f..1e862633a 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py @@ -21,8 +21,8 @@ ***************************************************************************/ """ -from collections import defaultdict -from typing import Dict, Set, Tuple +from itertools import chain +from typing import Dict, List, Optional, Set from PyQt5.QtCore import QCoreApplication from DsgTools.core.GeometricTools import graphHandler from qgis.PyQt.QtCore import QByteArray @@ -33,14 +33,11 @@ QgsProcessingMultiStepFeedback, QgsProcessingParameterEnum, QgsProcessingParameterVectorLayer, - QgsWkbTypes, QgsFeedback, QgsProcessingContext, - QgsGeometry, - QgsFeature, QgsVectorLayer, QgsProcessingParameterNumber, - QgsProcessingParameterBoolean, + QgsProcessingParameterMultipleLayers, ) from ...algRunner import AlgRunner @@ -51,7 +48,9 @@ class GeneralizeNetworkEdgesWithLengthAlgorithm(ValidationAlgorithm): NETWORK_LAYER = "NETWORK_LAYER" MIN_LENGTH = "MIN_LENGTH" GEOGRAPHIC_BOUNDS_LAYER = "GEOGRAPHIC_BOUNDS_LAYER" - WATER_BODIES_LAYER = "WATER_BODIES_LAYER" + POINT_CONSTRAINT_LAYER_LIST = "POINT_CONSTRAINT_LAYER_LIST" + LINE_CONSTRAINT_LAYER_LIST = "LINE_CONSTRAINT_LAYER_LIST" + POLYGON_CONSTRAINT_LAYER_LIST = "POLYGON_CONSTRAINT_LAYER_LIST" METHOD = "METHOD" def initAlgorithm(self, config): @@ -75,10 +74,26 @@ def initAlgorithm(self, config): ) ) self.addParameter( - QgsProcessingParameterVectorLayer( - self.WATER_BODIES_LAYER, - self.tr("Water bodies layer"), - [QgsProcessing.TypeVectorPolygon], + QgsProcessingParameterMultipleLayers( + self.POINT_CONSTRAINT_LAYER_LIST, + self.tr("Point constraint Layers"), + QgsProcessing.TypeVectorPoint, + optional=True, + ) + ) + self.addParameter( + QgsProcessingParameterMultipleLayers( + self.LINE_CONSTRAINT_LAYER_LIST, + self.tr("Line constraint Layers"), + QgsProcessing.TypeVectorLine, + optional=True, + ) + ) + self.addParameter( + QgsProcessingParameterMultipleLayers( + self.POLYGON_CONSTRAINT_LAYER_LIST, + self.tr("Polygon constraint Layers"), + QgsProcessing.TypeVectorPolygon, optional=True, ) ) @@ -125,25 +140,22 @@ def processAlgorithm(self, parameters, context, feedback): # get the network handler self.algRunner = AlgRunner() networkLayer = self.parameterAsLayer(parameters, self.NETWORK_LAYER, context) - filterExpression = self.parameterAsExpression( - parameters, self.FILTER_EXPRESSION, context - ) - if filterExpression == "": - filterExpression = None - oceanLayer = self.parameterAsLayer(parameters, self.WATER_BODIES_LAYER, context) - waterBodyWithFlowLayer = self.parameterAsLayer( - parameters, self.WATER_BODY_WITH_FLOW_LAYER, context - ) - waterSinkLayer = self.parameterAsLayer(parameters, self.SINK_LAYER, context) + threshold = self.parameterAsDouble(parameters, self.MIN_LENGTH, context) geographicBoundsLayer = self.parameterAsLayer( parameters, self.GEOGRAPHIC_BOUNDS_LAYER, context ) - nSteps = ( - 15 - + (runFlowCheck is True) - + (runLoopCheck is True) - + (waterBodyWithFlowLayer is not None) + pointLayerList = self.parameterAsLayerList( + parameters, self.POINT_CONSTRAINT_LAYER_LIST, context + ) + lineLayerList = self.parameterAsLayerList( + parameters, self.LINE_CONSTRAINT_LAYER_LIST, context ) + polygonLayerList = self.parameterAsLayerList( + parameters, self.POLYGON_CONSTRAINT_LAYER_LIST, context + ) + method = self.parameterAsEnum(parameters, self.METHOD, context) + + nSteps = 5 multiStepFeedback = QgsProcessingMultiStepFeedback(nSteps, feedback) currentStep = 0 multiStepFeedback.setCurrentStep(currentStep) @@ -175,7 +187,79 @@ def processAlgorithm(self, parameters, context, feedback): ) currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) + multiStepFeedback.setProgressText(self.tr("Getting constraint points")) + constraintSet = self.getConstraintSet( + nodeDict=nodeDict, + nodesLayer=nodesLayer, + nodeLayerIdDict=nodeLayerIdDict, + geographicBoundsLayer=geographicBoundsLayer, + pointLayerList=pointLayerList, + lineLayerList=lineLayerList, + polygonLayerList=polygonLayerList, + context=context, + feedback=multiStepFeedback, + ) + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + multiStepFeedback.setProgressText(self.tr("Applying algorithm heurisic")) + G_out = graphHandler.generalize_edges_according_to_degrees( + G=networkBidirectionalGraph, + constraintSet=constraintSet, + threshold=threshold, + feedback=multiStepFeedback + ) + idsToRemove = set(networkBidirectionalGraph[a][b]["featid"] for a, b in networkBidirectionalGraph.edges) - set(G_out[a][b]["featid"] for a, b in G_out.edges) + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + if method != 0: + networkLayer.selectByIds(list(idsToRemove), self.selectionIdDict[method]) + return {} + networkLayer.startEditing() + networkLayer.beginEditCommand(self.tr("Deleting features")) + networkLayer.deleteFeatures(list(idsToRemove)) + networkLayer.endEditCommand() return {} + + def getConstraintSet( + self, + nodeDict: Dict[QByteArray, int], + nodesLayer: QgsVectorLayer, + nodeLayerIdDict: Dict[int, Dict[int, QByteArray]], + geographicBoundsLayer: QgsVectorLayer, + pointLayerList = List[QgsVectorLayer], + lineLayerList = List[QgsVectorLayer], + polygonLayerList = List[QgsVectorLayer], + context: Optional[QgsProcessingContext] = None, + feedback: Optional[QgsFeedback] = None, + ) -> Set[int]: + multiStepFeedback = QgsProcessingMultiStepFeedback(4, feedback) + currentStep = 0 + multiStepFeedback.setCurrentStep(currentStep) + (fixedInNodeSet, fixedOutNodeSet) = graphHandler.getInAndOutNodesOnGeographicBounds( + nodeDict=nodeDict, + nodesLayer=nodesLayer, + geographicBoundsLayer=geographicBoundsLayer, + context=context, + feedback=feedback, + ) if geographicBoundsLayer is not None else (set(), set()) + currentStep += 1 + + constraintPointSet = fixedInNodeSet | fixedOutNodeSet + + computeLambda = lambda x: graphHandler.find_constraint_points( + nodesLayer=nodesLayer, + constraintLayer=x, + nodeDict=nodeDict, + nodeLayerIdDict=nodeLayerIdDict, + useBuffer=False, + context=context, + feedback=multiStepFeedback, + ) + + multiStepFeedback.setCurrentStep(currentStep) + constraintPointSetFromLambda = set(i for i in chain.from_iterable(map(computeLambda, pointLayerList + lineLayerList + polygonLayerList))) + constraintPointSet |= constraintPointSetFromLambda + return constraintPointSet def name(self): """ diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/reclassifyAdjecentPolygonsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/reclassifyAdjecentPolygonsAlgorithm.py similarity index 100% rename from DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/reclassifyAdjecentPolygonsAlgorithm.py rename to DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/reclassifyAdjecentPolygonsAlgorithm.py diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/splitPolygonsAlgorithm.py similarity index 100% rename from DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsAlgorithm.py rename to DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/splitPolygonsAlgorithm.py diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/splitPolygonsByGrid.py similarity index 100% rename from DsgTools/core/DSGToolsProcessingAlgs/Algs/GeometricAlgs/splitPolygonsByGrid.py rename to DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/splitPolygonsByGrid.py diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixNetworkAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixNetworkAlgorithm.py index a2e440774..aa678a00e 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixNetworkAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/ValidationAlgs/fixNetworkAlgorithm.py @@ -22,28 +22,15 @@ """ from PyQt5.QtCore import QCoreApplication -import processing from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.core import ( - QgsDataSourceUri, - QgsFeature, - QgsFeatureSink, - QgsGeometry, QgsProcessing, - QgsProcessingAlgorithm, QgsProcessingMultiStepFeedback, QgsProcessingOutputVectorLayer, QgsProcessingParameterBoolean, QgsProcessingParameterDistance, - QgsProcessingParameterEnum, - QgsProcessingParameterFeatureSink, - QgsProcessingParameterFeatureSource, QgsProcessingParameterField, - QgsProcessingParameterMultipleLayers, - QgsProcessingParameterNumber, QgsProcessingParameterVectorLayer, - QgsProcessingUtils, - QgsSpatialIndex, QgsWkbTypes, ) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py b/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py index 153c9199d..12965fe74 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/dsgtoolsProcessingAlgorithmProvider.py @@ -33,6 +33,7 @@ from DsgTools.core.DSGToolsProcessingAlgs.Algs.DataManagementAlgs.appendFeaturesToLayerAlgorithm import ( AppendFeaturesToLayerAlgorithm, ) +from DsgTools.core.DSGToolsProcessingAlgs.Algs.GeneralizationAlgs.generalizeNetworkEdgesFromLengthAlgorithm import GeneralizeNetworkEdgesWithLengthAlgorithm from DsgTools.core.DSGToolsProcessingAlgs.Algs.LayerManagementAlgs.buildZipPackagesAlgorithm import BuildZipPackageAlgorithm from DsgTools.core.DSGToolsProcessingAlgs.Algs.OtherAlgs.createGridFromCoordinatesAlgorithm import CreateGridFromCoordinatesAlgorithm from DsgTools.core.DSGToolsProcessingAlgs.Algs.ValidationAlgs.fixSegmentErrorsBetweenLinesAlgorithm import ( @@ -67,7 +68,7 @@ from DsgTools.core.DSGToolsProcessingAlgs.Algs.GeometricAlgs.line2Multiline import ( Line2Multiline, ) -from DsgTools.core.DSGToolsProcessingAlgs.Algs.GeometricAlgs.reclassifyAdjecentPolygonsAlgorithm import ( +from DsgTools.core.DSGToolsProcessingAlgs.Algs.GeneralizationAlgs.reclassifyAdjecentPolygonsAlgorithm import ( ReclassifyAdjacentPolygonsAlgorithm, ) from DsgTools.core.DSGToolsProcessingAlgs.Algs.GeometricAlgs.selectByDE9IM import ( @@ -76,10 +77,10 @@ from DsgTools.core.DSGToolsProcessingAlgs.Algs.GeometricAlgs.smallHoleRemoverAlgorithm import ( SmallHoleRemoverAlgorithm, ) -from DsgTools.core.DSGToolsProcessingAlgs.Algs.GeometricAlgs.splitPolygonsAlgorithm import ( +from DsgTools.core.DSGToolsProcessingAlgs.Algs.GeneralizationAlgs.splitPolygonsAlgorithm import ( SplitPolygons, ) -from DsgTools.core.DSGToolsProcessingAlgs.Algs.GeometricAlgs.splitPolygonsByGrid import ( +from DsgTools.core.DSGToolsProcessingAlgs.Algs.GeneralizationAlgs.splitPolygonsByGrid import ( SplitPolygonsByGrid, ) from DsgTools.core.DSGToolsProcessingAlgs.Algs.LayerManagementAlgs.applyStylesFromDatabaseToLayersAlgorithm import ( @@ -624,6 +625,7 @@ def getAlgList(self): IdentifyWaterBodyAndContourInconsistencies(), CreateGridFromCoordinatesAlgorithm(), BuildZipPackageAlgorithm(), + GeneralizeNetworkEdgesWithLengthAlgorithm(), ] return algList diff --git a/DsgTools/core/GeometricTools/graphHandler.py b/DsgTools/core/GeometricTools/graphHandler.py index 1498c3bfc..05c4ee0f7 100644 --- a/DsgTools/core/GeometricTools/graphHandler.py +++ b/DsgTools/core/GeometricTools/graphHandler.py @@ -19,19 +19,12 @@ * * ***************************************************************************/ """ -import itertools -import operator -import concurrent.futures -from functools import reduce -from collections import defaultdict, Counter +from collections import defaultdict from itertools import tee -import os from typing import Any, Dict, Iterable, List, Optional, Set, Tuple from qgis.PyQt.QtCore import QByteArray from itertools import chain from itertools import product -from itertools import starmap -from functools import partial from qgis.core import ( QgsGeometry, @@ -40,6 +33,7 @@ QgsVectorLayer, QgsFeedback, QgsProcessingContext, + QgsWkbTypes, ) from DsgTools.core.DSGToolsProcessingAlgs.algRunner import AlgRunner @@ -963,3 +957,162 @@ def buildAuxLayersPriorGraphBuilding( feedback=multiStepFeedback, ) return localCache, nodesLayer + +def getInAndOutNodesOnGeographicBounds( + nodeDict: Dict[QByteArray, int], + nodesLayer: QgsVectorLayer, + geographicBoundsLayer: QgsVectorLayer, + context: Optional[QgsProcessingContext] = None, + feedback: Optional[QgsFeedback] = None, + ) -> Tuple[Set[int], Set[int]]: + """ + Get the in-nodes and out-nodes that fall within the geographic bounds. + + Args: + self: The instance of the class. + nodeDict: A dictionary mapping node geometry to an auxiliary ID. + nodesLayer: A QgsVectorLayer representing nodes in the network. + geographicBoundsLayer: The geographic bounds layer. + context: The context object for the processing. + feedback: The QgsFeedback object for providing feedback during processing. + + Returns: + A tuple containing two sets: fixedInNodeSet and fixedOutNodeSet. + - fixedInNodeSet: A set of in-nodes that fall within the geographic bounds. + - fixedOutNodeSet: A set of out-nodes that fall within the geographic bounds. + + Notes: + This function performs the following steps: + 1. Creates a spatial index for the nodesLayer. + 2. Extracts the nodes that are outside the geographic bounds. + 3. Iterates over the nodes outside the geographic bounds and adds them to the appropriate set. + 4. Returns the sets of in-nodes and out-nodes within the geographic bounds. + + The feedback object is used to monitor the progress of the function. + """ + multiStepFeedback = QgsProcessingMultiStepFeedback(3, feedback) if feedback is not None else None + context = context if context is not None else QgsProcessingContext() + algRunner = AlgRunner() + currentStep = 0 + if multiStepFeedback is not None: + multiStepFeedback.setCurrentStep(currentStep) + algRunner.runCreateSpatialIndex( + inputLyr=nodesLayer, + context=context, + feedback=multiStepFeedback, + is_child_algorithm=True, + ) + currentStep += 1 + if multiStepFeedback is not None: + multiStepFeedback.setCurrentStep(currentStep) + nodesOutsideGeographicBounds = algRunner.runExtractByLocation( + inputLyr=nodesLayer, + intersectLyr=geographicBoundsLayer, + predicate=[AlgRunner.Disjoint], + context=context, + feedback=multiStepFeedback, + ) + currentStep += 1 + if multiStepFeedback is not None: + multiStepFeedback.setCurrentStep(currentStep) + fixedInNodeSet, fixedOutNodeSet = set(), set() + nFeats = nodesOutsideGeographicBounds.featureCount() + if nFeats == 0: + return fixedInNodeSet, fixedOutNodeSet + stepSize = 100 / nFeats + for current, nodeFeat in enumerate(nodesOutsideGeographicBounds.getFeatures()): + if multiStepFeedback is not None and multiStepFeedback.isCanceled(): + break + selectedSet = ( + fixedInNodeSet if nodeFeat["vertex_pos"] == 0 else fixedOutNodeSet + ) + geom = nodeFeat.geometry() + selectedSet.add(nodeDict[geom.asWkb()]) + if multiStepFeedback is not None: + multiStepFeedback.setProgress(current * stepSize) + return fixedInNodeSet, fixedOutNodeSet + +def find_constraint_points( + nodesLayer: QgsVectorLayer, + constraintLayer: QgsVectorLayer, + nodeDict: Dict[QByteArray, int], + nodeLayerIdDict: Dict[int, Dict[int, QByteArray]], + useBuffer: bool =True, + context: Optional[QgsProcessingContext] = None, + feedback: Optional[QgsFeedback] = None, +) -> Set[int]: + multiStepFeedback = QgsProcessingMultiStepFeedback(3, feedback) if feedback is not None else None + context = context if context is not None else QgsProcessingContext() + algRunner = AlgRunner() + constraintSet = set() + layerToRelate = algRunner.runBuffer( + inputLayer=constraintLayer, + distance=1e-6, + context=context, + is_child_algorithm=True, + ) if constraintLayer.geometryType() != QgsWkbTypes.PointGeometry and useBuffer else constraintLayer + predicate = AlgRunner.Intersect if constraintLayer.geometryType() != QgsWkbTypes.PointGeometry else AlgRunner.Equal + selectedNodesFromOcean = algRunner.runExtractByLocation( + inputLyr=nodesLayer, + intersectLyr=layerToRelate, + context=context, + predicate=[predicate], + feedback=multiStepFeedback, + ) + for feat in selectedNodesFromOcean.getFeatures(): + if multiStepFeedback.isCanceled(): + break + constraintSet.add(nodeDict[nodeLayerIdDict[feat["nfeatid"]]]) + return constraintSet + +def generalize_edges_according_to_degrees( + G, + constraintSet: Set[int], + threshold: float, + feedback: Optional[QgsFeedback] = None, +): + G_copy = G.copy() + pairsToRemove = find_smaller_first_order_path_with_length_smaller_than_threshold( + G=G_copy, + constraintSet=constraintSet, + threshold=threshold, + feedback=feedback + ) + while pairsToRemove is not None: + if feedback is not None and feedback.isCanceled(): + break + for n0, n1 in pairsToRemove: + G_copy.remove_edge(n0, n1) + pairsToRemove = find_smaller_first_order_path_with_length_smaller_than_threshold( + G=G_copy, + constraintSet=constraintSet, + threshold=threshold, + feedback=feedback + ) + return G_copy + + +def find_smaller_first_order_path_with_length_smaller_than_threshold( + G, + constraintSet: Set[int], + threshold: float, + feedback: Optional[QgsFeedback] = None +) -> frozenset[frozenset]: + total_length_dict = dict() + edges_to_remove_dict = dict() + for node in set(node for node in G.nodes if G.degree(node) == 1 and node not in constraintSet): + if feedback is not None and feedback.isCanceled(): + return None + connectedNodes = fetch_connected_nodes(G, node, 2) + if set(connectedNodes).intersection(constraintSet): + continue + pairs = frozenset([frozenset([a, b]) for i in connectedNodes for a, b in G.edges(i)]) + total_length = sum(G[a][b]["length"] for a, b in pairs) + if total_length >= threshold: + continue + edges_to_remove_dict[node] = pairs + total_length_dict[node] = total_length + if len(total_length_dict) == 0: + return None + smaller_path_node = min(total_length_dict.keys(), key=lambda x: total_length_dict[x]) + return edges_to_remove_dict[smaller_path_node] diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index b280c4bb1..bc3e64121 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.36 +version=4.11.37 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From b0e0f019212c29bfa4704ebb23091d8df487c7b9 Mon Sep 17 00:00:00 2001 From: phborba Date: Fri, 1 Dec 2023 11:18:50 -0300 Subject: [PATCH 49/53] fix --- .../Algs/Help/html/identifyDangles.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/Help/html/identifyDangles.html b/DsgTools/core/DSGToolsProcessingAlgs/Algs/Help/html/identifyDangles.html index bdd72528a..c61db3b30 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/Help/html/identifyDangles.html +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/Help/html/identifyDangles.html @@ -32,7 +32,7 @@

Parâmetros:

- • Raio de busca → Distância mínima de uma feição a outra (de uma camada que devesse ser atraí-la) para que não seja considerada desconectada (ponta solta). + • Raio de busca → Distância mínima de uma feição a outra (de uma camada que deveria ser atraída) para que não seja considerada desconectada (ponta solta). @@ -64,8 +64,8 @@

Modelagem EDGV3.0 na escala de 1:25.000 (EPSG):4674

• Camada de entrada → hid_trecho_drenagem_l • input is a boundary layer → false • Raio de busca → 0,000100 - • Camada de filtro do tipo linha → opicional - • Camada de filtro do tipo polígono → opicional + • Camada de filtro do tipo linha → opcional + • Camada de filtro do tipo polígono → opcional • Ignorar pontas soltas em linhas não segmentadas → false From 03862c5d00d69d654eed31558b30ef5914fd981c Mon Sep 17 00:00:00 2001 From: phborba Date: Tue, 5 Dec 2023 12:33:20 -0300 Subject: [PATCH 50/53] =?UTF-8?q?Vers=C3=A3o=204.11.38:=20melhoria=20de=20?= =?UTF-8?q?desempenho?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 +- ...neralizeNetworkEdgesFromLengthAlgorithm.py | 166 +++++++++++++++--- DsgTools/core/GeometricTools/graphHandler.py | 6 +- DsgTools/metadata.txt | 2 +- 4 files changed, 152 insertions(+), 25 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9734bf115..9657f30ca 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.37 - dev +## 4.11.38 - dev Novas Funcionalidades: @@ -28,6 +28,7 @@ Melhorias: - Adicionado botão de selecionar a camada ativa na barra de ferramentas de revisão; - Adicionada a opção de uso da tag "NULL" no atributo do botão do menu para preencher o campo com o valor nulo na atributação e reclassificação do menu de aquisição; - O processo de carregar shapefiles agora agrupa por pasta, caso seja dado como entrada uma pasta que possui pastas com shapefiles; +- Melhoria de desempenho no processo de generalizar trechos de drenagem; Correção de bug: diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py index 1e862633a..09310545f 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/GeneralizationAlgs/generalizeNetworkEdgesFromLengthAlgorithm.py @@ -21,10 +21,14 @@ ***************************************************************************/ """ +import concurrent.futures + from itertools import chain +import os from typing import Dict, List, Optional, Set from PyQt5.QtCore import QCoreApplication from DsgTools.core.GeometricTools import graphHandler +from DsgTools.core.GeometricTools.layerHandler import LayerHandler from qgis.PyQt.QtCore import QByteArray from qgis.core import ( Qgis, @@ -38,6 +42,7 @@ QgsVectorLayer, QgsProcessingParameterNumber, QgsProcessingParameterMultipleLayers, + QgsProcessingParameterBoolean, ) from ...algRunner import AlgRunner @@ -48,6 +53,7 @@ class GeneralizeNetworkEdgesWithLengthAlgorithm(ValidationAlgorithm): NETWORK_LAYER = "NETWORK_LAYER" MIN_LENGTH = "MIN_LENGTH" GEOGRAPHIC_BOUNDS_LAYER = "GEOGRAPHIC_BOUNDS_LAYER" + GROUP_BY_SPATIAL_PARTITION = "GROUP_BY_SPATIAL_PARTITION" POINT_CONSTRAINT_LAYER_LIST = "POINT_CONSTRAINT_LAYER_LIST" LINE_CONSTRAINT_LAYER_LIST = "LINE_CONSTRAINT_LAYER_LIST" POLYGON_CONSTRAINT_LAYER_LIST = "POLYGON_CONSTRAINT_LAYER_LIST" @@ -105,6 +111,12 @@ def initAlgorithm(self, config): optional=True, ) ) + self.addParameter( + QgsProcessingParameterBoolean( + self.GROUP_BY_SPATIAL_PARTITION, + self.tr("Run algothimn grouping by spatial partition"), + ) + ) self.selectionIdDict = { 1: Qgis.SelectBehavior.SetSelection, 2: Qgis.SelectBehavior.AddToSelection, @@ -139,6 +151,7 @@ def processAlgorithm(self, parameters, context, feedback): ) # get the network handler self.algRunner = AlgRunner() + self.layerHandler = LayerHandler() networkLayer = self.parameterAsLayer(parameters, self.NETWORK_LAYER, context) threshold = self.parameterAsDouble(parameters, self.MIN_LENGTH, context) geographicBoundsLayer = self.parameterAsLayer( @@ -153,9 +166,12 @@ def processAlgorithm(self, parameters, context, feedback): polygonLayerList = self.parameterAsLayerList( parameters, self.POLYGON_CONSTRAINT_LAYER_LIST, context ) + groupBySpatialPartition = self.parameterAsBool( + parameters, self.GROUP_BY_SPATIAL_PARTITION, context + ) method = self.parameterAsEnum(parameters, self.METHOD, context) - nSteps = 5 + nSteps = 5 if groupBySpatialPartition else 2 multiStepFeedback = QgsProcessingMultiStepFeedback(nSteps, feedback) currentStep = 0 multiStepFeedback.setCurrentStep(currentStep) @@ -166,9 +182,97 @@ def processAlgorithm(self, parameters, context, feedback): geographicBoundsLayer=geographicBoundsLayer, feedback=multiStepFeedback, ) + if not groupBySpatialPartition or (geographicBoundsLayer is not None and geographicBoundsLayer.featureCount() <= 1): + idsToRemove = self.findIdsToRemove(nx, localCache, nodesLayer, threshold, geographicBoundsLayer, pointLayerList, lineLayerList, polygonLayerList, context, multiStepFeedback) + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + self.manageSelectedIdsUsingInputMethod(networkLayer, method, idsToRemove) + return {} + def compute(localGeographicBoundsLayer): + localContext = QgsProcessingContext() + if multiStepFeedback.isCanceled(): + return set() + localNetworkCacheLyr = self.extractFeaturesRelatedToLayer(localCache, localGeographicBoundsLayer) + if multiStepFeedback.isCanceled(): + return set() + localNodesLyr = self.extractFeaturesRelatedToLayer(nodesLayer, localNetworkCacheLyr) + if multiStepFeedback.isCanceled(): + return set() + localPointFeatList = list(map(lambda x: self.extractFeaturesRelatedToLayer(x, localGeographicBoundsLayer), pointLayerList)) if len(pointLayerList) > 0 else [] + if multiStepFeedback.isCanceled(): + return set() + localLineFeatList = list(map(lambda x: self.extractFeaturesRelatedToLayer(x, localGeographicBoundsLayer), lineLayerList)) if len(lineLayerList) > 0 else [] + if multiStepFeedback.isCanceled(): + return set() + localPolygonFeatList = list(map(lambda x: self.extractFeaturesRelatedToLayer(x, localGeographicBoundsLayer), polygonLayerList)) if len(polygonLayerList) > 0 else [] + return self.findIdsToRemove( + nx, + localNetworkCacheLyr, + localNodesLyr, + threshold, + localGeographicBoundsLayer, + localPointFeatList, + localLineFeatList, + localPolygonFeatList, + localContext, + None + ) + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + multiStepFeedback.setProgressText(self.tr("Splitting geographic bounds")) + geographicBoundaryLayerList = self.layerHandler.createMemoryLayerForEachFeature( + layer=geographicBoundsLayer, context=context, feedback=multiStepFeedback + ) + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + nRegions = len(geographicBoundaryLayerList) + if nRegions == 0: + return {} + stepSize = 100 / nRegions + futures = set() + idsToRemove = set() + pool = concurrent.futures.ThreadPoolExecutor(max_workers=os.cpu_count() - 1) + multiStepFeedback.setProgressText( + self.tr("Submitting tasks to thread...") + ) + for current, localGeographicBoundsLayer in enumerate( + geographicBoundaryLayerList, start=0 + ): + if multiStepFeedback.isCanceled(): + pool.shutdown(cancel_futures=True) + break + futures.add(pool.submit(compute, localGeographicBoundsLayer)) + multiStepFeedback.setProgress(current * stepSize) + + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + multiStepFeedback.setProgressText(self.tr("Evaluating results...")) + for current, future in enumerate(concurrent.futures.as_completed(futures)): + if multiStepFeedback.isCanceled(): + pool.shutdown(cancel_futures=True) + break + idsToRemove |= future.result() currentStep += 1 multiStepFeedback.setCurrentStep(currentStep) - multiStepFeedback.setProgressText(self.tr("Building graph aux structures")) + self.manageSelectedIdsUsingInputMethod(networkLayer, method, idsToRemove) + return {} + + def manageSelectedIdsUsingInputMethod(self, networkLayer, method, idsToRemove): + if method != 0: + networkLayer.selectByIds(list(idsToRemove), self.selectionIdDict[method]) + return {} + networkLayer.startEditing() + networkLayer.beginEditCommand(self.tr("Deleting features")) + networkLayer.deleteFeatures(list(idsToRemove)) + networkLayer.endEditCommand() + return {} + + def findIdsToRemove(self, nx, localCache, nodesLayer, threshold, geographicBoundsLayer, pointLayerList, lineLayerList, polygonLayerList, context, feedback=None): + multiStepFeedback = QgsProcessingMultiStepFeedback(4, feedback) if feedback is not None else None + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + multiStepFeedback.setProgressText(self.tr("Building graph aux structures")) ( nodeDict, nodeIdDict, @@ -185,9 +289,10 @@ def processAlgorithm(self, parameters, context, feedback): computeNodeLayerIdDict=True, addEdgeLength=True, ) - currentStep += 1 - multiStepFeedback.setCurrentStep(currentStep) - multiStepFeedback.setProgressText(self.tr("Getting constraint points")) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + multiStepFeedback.setProgressText(self.tr("Getting constraint points")) constraintSet = self.getConstraintSet( nodeDict=nodeDict, nodesLayer=nodesLayer, @@ -199,9 +304,10 @@ def processAlgorithm(self, parameters, context, feedback): context=context, feedback=multiStepFeedback, ) - currentStep += 1 - multiStepFeedback.setCurrentStep(currentStep) - multiStepFeedback.setProgressText(self.tr("Applying algorithm heurisic")) + if multiStepFeedback is not None: + currentStep += 1 + multiStepFeedback.setCurrentStep(currentStep) + multiStepFeedback.setProgressText(self.tr("Applying algorithm heurisic")) G_out = graphHandler.generalize_edges_according_to_degrees( G=networkBidirectionalGraph, constraintSet=constraintSet, @@ -209,16 +315,7 @@ def processAlgorithm(self, parameters, context, feedback): feedback=multiStepFeedback ) idsToRemove = set(networkBidirectionalGraph[a][b]["featid"] for a, b in networkBidirectionalGraph.edges) - set(G_out[a][b]["featid"] for a, b in G_out.edges) - currentStep += 1 - multiStepFeedback.setCurrentStep(currentStep) - if method != 0: - networkLayer.selectByIds(list(idsToRemove), self.selectionIdDict[method]) - return {} - networkLayer.startEditing() - networkLayer.beginEditCommand(self.tr("Deleting features")) - networkLayer.deleteFeatures(list(idsToRemove)) - networkLayer.endEditCommand() - return {} + return idsToRemove def getConstraintSet( self, @@ -232,9 +329,10 @@ def getConstraintSet( context: Optional[QgsProcessingContext] = None, feedback: Optional[QgsFeedback] = None, ) -> Set[int]: - multiStepFeedback = QgsProcessingMultiStepFeedback(4, feedback) + multiStepFeedback = QgsProcessingMultiStepFeedback(4, feedback) if feedback is not None else None currentStep = 0 - multiStepFeedback.setCurrentStep(currentStep) + if multiStepFeedback is not None: + multiStepFeedback.setCurrentStep(currentStep) (fixedInNodeSet, fixedOutNodeSet) = graphHandler.getInAndOutNodesOnGeographicBounds( nodeDict=nodeDict, nodesLayer=nodesLayer, @@ -255,11 +353,35 @@ def getConstraintSet( context=context, feedback=multiStepFeedback, ) - - multiStepFeedback.setCurrentStep(currentStep) + if multiStepFeedback is not None: + multiStepFeedback.setCurrentStep(currentStep) constraintPointSetFromLambda = set(i for i in chain.from_iterable(map(computeLambda, pointLayerList + lineLayerList + polygonLayerList))) constraintPointSet |= constraintPointSetFromLambda return constraintPointSet + + def extractFeaturesRelatedToLayer( + self, inputLyr, referenceLyr, context=None, feedback=None + ): + context = QgsProcessingContext() if context is None else context + multiStepFeedback = ( + QgsProcessingMultiStepFeedback(2, feedback) + if feedback is not None + else None + ) + if multiStepFeedback is not None: + multiStepFeedback.setCurrentStep(0) + extractedLyr = self.algRunner.runExtractByLocation( + inputLyr=inputLyr, + intersectLyr=referenceLyr, + context=context, + feedback=multiStepFeedback, + ) + if multiStepFeedback is not None: + multiStepFeedback.setCurrentStep(1) + self.algRunner.runCreateSpatialIndex( + inputLyr=extractedLyr, context=context, feedback=multiStepFeedback, is_child_algorithm=True + ) + return extractedLyr def name(self): """ diff --git a/DsgTools/core/GeometricTools/graphHandler.py b/DsgTools/core/GeometricTools/graphHandler.py index 05c4ee0f7..48111e26d 100644 --- a/DsgTools/core/GeometricTools/graphHandler.py +++ b/DsgTools/core/GeometricTools/graphHandler.py @@ -146,6 +146,8 @@ def buildGraph( for current, (edgeId, (wkb_1, wkb_2)) in enumerate(hashDict.items()): if feedback is not None and feedback.isCanceled(): break + if wkb_1 == [] or wkb_2 == []: + continue G.add_edge(nodeDict[wkb_1], nodeDict[wkb_2]) G[nodeDict[wkb_1]][nodeDict[wkb_2]]["featid"] = edgeId if add_inside_river_attribute: @@ -246,6 +248,8 @@ def buildAuxStructures( if multiStepFeedback is not None and multiStepFeedback.isCanceled(): break featid = networkBidirectionalGraph[a][b]["featid"] + if featid not in edgeDict: + continue geom = edgeDict[featid].geometry() networkBidirectionalGraph[a][b]["length"] = geom.length() @@ -1060,7 +1064,7 @@ def find_constraint_points( feedback=multiStepFeedback, ) for feat in selectedNodesFromOcean.getFeatures(): - if multiStepFeedback.isCanceled(): + if multiStepFeedback is not None and multiStepFeedback.isCanceled(): break constraintSet.add(nodeDict[nodeLayerIdDict[feat["nfeatid"]]]) return constraintSet diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index bc3e64121..0a44f7098 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.37 +version=4.11.38 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From 97dd96cd52248925396b99fd9127e80002e3dea2 Mon Sep 17 00:00:00 2001 From: Pedro Martins Date: Wed, 6 Dec 2023 12:45:36 -0300 Subject: [PATCH 51/53] fix seguimento->segmento --- .../identifyNetworkConstructionIssues.html | 24 ++++++++-------- .../html/identifysmallfirstorderdangles.html | 28 +++++++++---------- 2 files changed, 26 insertions(+), 26 deletions(-) diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/Help/html/identifyNetworkConstructionIssues.html b/DsgTools/core/DSGToolsProcessingAlgs/Algs/Help/html/identifyNetworkConstructionIssues.html index b5ab8d2b8..6665143e4 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/Help/html/identifyNetworkConstructionIssues.html +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/Help/html/identifyNetworkConstructionIssues.html @@ -8,19 +8,19 @@ - +

Help versão 1.0


Descrição:

- Identifica seguimentos de linhas em uma rede que possuem pontas soltas, linhas nao segmentadas e linhas desconectadas da rede. + Identifica segmentos de linhas em uma rede que possuem pontas soltas, linhas nao segmentadas e linhas desconectadas da rede.


- +

Parâmetros:

@@ -33,8 +33,8 @@

Parâmetros:

• Search radius → Parâmetro onde se define a distância que os seguimentos de linhas estão de onde deveriam estar conectados. Se a camada estiver no sistema de coordenada geográfica a unidade de medida será em graus decimais onde 0.00001 graus decimais ≅ 1 metro. - • Linestring Filter Layer → Camada opcional do tipo linha onde será filtrado em comparação com input layer. - + • Linestring Filter Layer → Camada opcional do tipo linha onde será filtrado em comparação com input layer. + • Polygon Filter Layer → Camada opcional do tipo poligono onde será filtrado em comparação com input layer. @@ -46,13 +46,13 @@

Parâmetros:

• Geographic Boundary → Fronteira geográfica da região (moldura), que servirão como limitantes.
Atenção: A unidade de medida do raio é baseada no sistema de coordenadas da camada vetorial de entrada. - -

+ +


- +

Exemplo de uso:

Modelagem EDGV3.0 na escala de 1:25.000 (EPSG):4674

@@ -64,17 +64,17 @@

Modelagem EDGV3.0 na escala de 1:25.000 (EPSG):4674

• Polygon Filter Layer → false • Ignore dangle on unsegmented lines → true • Geographic Boundary → aux_moldura_a - +
- +

Exemplo de Flag:

Segmento hid_trecho_drenagem_l não conectado.


-
+ - \ No newline at end of file + diff --git a/DsgTools/core/DSGToolsProcessingAlgs/Algs/Help/html/identifysmallfirstorderdangles.html b/DsgTools/core/DSGToolsProcessingAlgs/Algs/Help/html/identifysmallfirstorderdangles.html index e97eceb69..56fc47b4d 100644 --- a/DsgTools/core/DSGToolsProcessingAlgs/Algs/Help/html/identifysmallfirstorderdangles.html +++ b/DsgTools/core/DSGToolsProcessingAlgs/Algs/Help/html/identifysmallfirstorderdangles.html @@ -8,29 +8,29 @@ - +

Help versão 1.0


Descrição:

- Identifica seguimentos de linhas em uma rede, onde o seguimento é um trecho de linha que não está conectado a nenhum outro trecho. + Identifica segmentos de linhas em uma rede, onde o segmento é um trecho de linha que não está conectado a nenhum outro trecho.


- +

Parâmetros:

- • Input Layer → Camadas do tipo linha a ser processada em busca de identificar seguimentos de linhas que não estão conectadas a nenhum outro trecho. + • Input Layer → Camadas do tipo linha a ser processada em busca de identificar segmentos de linhas que não estão conectadas a nenhum outro trecho. - • Minimum size → Parâmetro onde se define tamanho mínimo para os seguimentos de linhas que serão identificados. + • Minimum size → Parâmetro onde se define tamanho mínimo para os segmentos de linhas que serão identificados. - • Search radius → Parâmetro onde se define a distância que os seguimentos de linhas estão de onde deveriam estar conectados. Onde 0.00001 graus decimais ≅ 1 metro. + • Search radius → Parâmetro onde se define a distância que os segmentos de linhas estão de onde deveriam estar conectados. Onde 0.00001 graus decimais ≅ 1 metro. • Linestring Filter Layers → Camada opcional do tipo linha onde será filtrado em comparação com input layer. @@ -42,13 +42,13 @@

Parâmetros:

• Geographic Boundary → Fronteira geográfica da região (moldura), que servirão como limitantes. Atenção: Independentemente do sistema de coordenadas da camada de entrada, o parâmetro do raio de busca é fornecido em ângulos decimais. - -

+ +


- +

Exemplo de uso:

Modelagem EDGV3.0 na escala de 1:25.000 (EPSG):4674

@@ -59,18 +59,18 @@

Modelagem EDGV3.0 na escala de 1:25.000 (EPSG):4674

• Linestring Filter Layers → hid_trecho_drenagem_l • Polygon Filter Layers → false • Geographic Boundary → aux_moldura_a - - + +
- +

Exemplo de Flag:

hid_trecho_drenagem_l que não está conectado.


-
+ - \ No newline at end of file + From e6cd0893667fd2853c2ea594b9d5589d01bcd609 Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 13 Dec 2023 16:47:47 -0300 Subject: [PATCH 52/53] atualiza modelagens --- CHANGELOG.md | 5 +- DsgTools/core/DbModels/PostGIS/3/edgv3.sql | 12860 ++++++++-------- .../DbModels/PostGIS/3_Orto/edgv3_orto.sql | 2992 ++++ .../core/DbModels/PostGIS/3_Pro/edgv3_pro.sql | 3608 ++--- .../core/Factories/DbFactory/abstractDb.py | 2 + .../core/Factories/DbFactory/postgisDb.py | 21 +- .../SqlFactory/postgisSqlGenerator.py | 2 +- .../ThreadFactory/postgisDbThread.py | 4 + .../connectionComboBox.py | 1 + .../databaseFileLineEdit.py | 1 + .../newConnectionLineEdit.py | 1 + .../newDatabaseLineEdit.py | 1 + .../databaseParameterWidget.ui | 5 + DsgTools/metadata.txt | 2 +- 14 files changed, 11503 insertions(+), 8002 deletions(-) create mode 100644 DsgTools/core/DbModels/PostGIS/3_Orto/edgv3_orto.sql diff --git a/CHANGELOG.md b/CHANGELOG.md index 9657f30ca..7af38da95 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.38 - dev +## 4.11.39 - dev Novas Funcionalidades: @@ -12,6 +12,7 @@ Novas Funcionalidades: - Adicionado atalho para ativar/desativar modo reclassificação; - Novo processo de criar pacote de shapefile (utilizado normalmente para preparar a carga no BDGEx); - Novo processo de generalizar trechos de drenagem de acordo com o comprimento; +- Adicionado o modelo EDGV 3.0 Orto; Melhorias: @@ -54,6 +55,8 @@ Correção de bug: - Corrige bug no processo de geometria inválida quando há geometria nula ou vazia; - Corrige bug no processo de verificar atributo unicode (não estava gerando flag por erro de definição de geometria da camada); - Corrige bug em parâmetro do algoritmo de verificação de regras de construção do terreno; +- Correção de bug no modelo EDGV 3.0 Pro; +- Correção de bug no modelo EDGV 3.0; ## 4.10.1 - 2023-10-02 diff --git a/DsgTools/core/DbModels/PostGIS/3/edgv3.sql b/DsgTools/core/DbModels/PostGIS/3/edgv3.sql index a1aeb3477..4a1dfd1d2 100644 --- a/DsgTools/core/DbModels/PostGIS/3/edgv3.sql +++ b/DsgTools/core/DbModels/PostGIS/3/edgv3.sql @@ -1,2717 +1,2706 @@ -CREATE SCHEMA edgv; -CREATE SCHEMA dominios; +CREATE SCHEMA edgv# +CREATE SCHEMA dominios# -CREATE EXTENSION postgis; -SET search_path TO pg_catalog,public,edgv,dominios; +CREATE EXTENSION postgis# +CREATE EXTENSION IF NOT EXISTS "uuid-ossp"# +SET search_path TO pg_catalog,public,edgv,dominios# CREATE TABLE public.db_metadata( edgvversion varchar(50) NOT NULL DEFAULT 'EDGV 3.0', - dbimplversion varchar(50) NOT NULL DEFAULT '1.1', + dbimplversion varchar(50) NOT NULL DEFAULT '1.1.3', CONSTRAINT edgvversioncheck CHECK (edgvversion = 'EDGV 3.0') -); -INSERT INTO public.db_metadata (edgvversion, dbimplversion) VALUES ('EDGV 3.0','1.1'); +)# +INSERT INTO public.db_metadata (edgvversion, dbimplversion) VALUES ('EDGV 3.0','1.1.3')# CREATE TABLE dominios.aptidao_operacional_atracadouro ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT aptidao_operacional_atracadouro_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.aptidao_operacional_atracadouro (code,code_name) VALUES (2,'Transporte de cabotagem (2)'); -INSERT INTO dominios.aptidao_operacional_atracadouro (code,code_name) VALUES (3,'Transporte oceânico (3)'); -INSERT INTO dominios.aptidao_operacional_atracadouro (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.aptidao_operacional_atracadouro (code,code_name) VALUES (2,'Transporte de cabotagem (2)')# +INSERT INTO dominios.aptidao_operacional_atracadouro (code,code_name) VALUES (3,'Transporte oceânico (3)')# +INSERT INTO dominios.aptidao_operacional_atracadouro (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.aptidao_operacional_atracadouro OWNER TO postgres; +ALTER TABLE dominios.aptidao_operacional_atracadouro OWNER TO postgres# CREATE TABLE dominios.tipo_sinal ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_sinal_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (1,'Boia luminosa (1)'); -INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (2,'Boia cega (2)'); -INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (3,'Boia de amarração (3)'); -INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (4,'Farol ou farolete (4)'); -INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (5,'Barca farol (5)'); -INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (6,'Sinalização de margem (6)'); -INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (1,'Boia luminosa (1)')# +INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (2,'Boia cega (2)')# +INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (3,'Boia de amarração (3)')# +INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (4,'Farol ou farolete (4)')# +INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (5,'Barca farol (5)')# +INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (6,'Sinalização de margem (6)')# +INSERT INTO dominios.tipo_sinal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_sinal OWNER TO postgres; +ALTER TABLE dominios.tipo_sinal OWNER TO postgres# CREATE TABLE dominios.finalidade_cultura ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT finalidade_cultura_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (1,'Exploração econômica (1)'); -INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (2,'Subsistência (2)'); -INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (3,'Conservação ambiental (3)'); -INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (4,'Ornamental (4)'); -INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (1,'Exploração econômica (1)')# +INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (2,'Subsistência (2)')# +INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (3,'Conservação ambiental (3)')# +INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (4,'Ornamental (4)')# +INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.finalidade_cultura (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.finalidade_cultura OWNER TO postgres; +ALTER TABLE dominios.finalidade_cultura OWNER TO postgres# CREATE TABLE dominios.tipo_travessia_ped ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_travessia_ped_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_travessia_ped (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_travessia_ped (code,code_name) VALUES (7,'Passagem subterrânea (7)'); -INSERT INTO dominios.tipo_travessia_ped (code,code_name) VALUES (8,'Passarela (8)'); -INSERT INTO dominios.tipo_travessia_ped (code,code_name) VALUES (9,'Pinguela (9)'); -INSERT INTO dominios.tipo_travessia_ped (code,code_name) VALUES (10,'Passarela em área úmida (10)'); -INSERT INTO dominios.tipo_travessia_ped (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_travessia_ped (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_travessia_ped (code,code_name) VALUES (7,'Passagem subterrânea (7)')# +INSERT INTO dominios.tipo_travessia_ped (code,code_name) VALUES (8,'Passarela (8)')# +INSERT INTO dominios.tipo_travessia_ped (code,code_name) VALUES (9,'Pinguela (9)')# +INSERT INTO dominios.tipo_travessia_ped (code,code_name) VALUES (10,'Passarela em área úmida (10)')# +INSERT INTO dominios.tipo_travessia_ped (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_travessia_ped OWNER TO postgres; +ALTER TABLE dominios.tipo_travessia_ped OWNER TO postgres# CREATE TABLE dominios.tipo_quebra_molhe ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_quebra_molhe_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_quebra_molhe (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_quebra_molhe (code,code_name) VALUES (1,'Quebramar (1)'); -INSERT INTO dominios.tipo_quebra_molhe (code,code_name) VALUES (2,'Molhe (2)'); -INSERT INTO dominios.tipo_quebra_molhe (code,code_name) VALUES (4,'Espigão (4)'); -INSERT INTO dominios.tipo_quebra_molhe (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_quebra_molhe (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_quebra_molhe (code,code_name) VALUES (1,'Quebramar (1)')# +INSERT INTO dominios.tipo_quebra_molhe (code,code_name) VALUES (2,'Molhe (2)')# +INSERT INTO dominios.tipo_quebra_molhe (code,code_name) VALUES (4,'Espigão (4)')# +INSERT INTO dominios.tipo_quebra_molhe (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_quebra_molhe OWNER TO postgres; +ALTER TABLE dominios.tipo_quebra_molhe OWNER TO postgres# CREATE TABLE dominios.bitola ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT bitola_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.bitola (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.bitola (code,code_name) VALUES (1,'Métrica (1)'); -INSERT INTO dominios.bitola (code,code_name) VALUES (2,'Internacional (2)'); -INSERT INTO dominios.bitola (code,code_name) VALUES (3,'Larga (3)'); -INSERT INTO dominios.bitola (code,code_name) VALUES (4,'Mista métrica internacional (4)'); -INSERT INTO dominios.bitola (code,code_name) VALUES (5,'Mista métrica larga (5)'); -INSERT INTO dominios.bitola (code,code_name) VALUES (6,'Mista internacional larga (6)'); -INSERT INTO dominios.bitola (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.bitola (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (1,'Métrica (1)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (2,'Internacional (2)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (3,'Larga (3)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (4,'Mista métrica internacional (4)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (5,'Mista métrica larga (5)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (6,'Mista internacional larga (6)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.bitola OWNER TO postgres; +ALTER TABLE dominios.bitola OWNER TO postgres# CREATE TABLE dominios.forma_extracao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT forma_extracao_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.forma_extracao (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.forma_extracao (code,code_name) VALUES (5,'A céu aberto (5)'); -INSERT INTO dominios.forma_extracao (code,code_name) VALUES (6,'Subterrânea (6)'); -INSERT INTO dominios.forma_extracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.forma_extracao (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.forma_extracao (code,code_name) VALUES (5,'A céu aberto (5)')# +INSERT INTO dominios.forma_extracao (code,code_name) VALUES (6,'Subterrânea (6)')# +INSERT INTO dominios.forma_extracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.forma_extracao OWNER TO postgres; +ALTER TABLE dominios.forma_extracao OWNER TO postgres# CREATE TABLE dominios.tipo_edif_turist ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_edif_turist_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (9,'Cruzeiro (9)'); -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (10,'Estátua (10)'); -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (11,'Mirante (11)'); -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (12,'Monumento (12)'); -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (13,'Panteão (13)'); -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (14,'Chafariz (14)'); -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (15,'Chaminé (15)'); -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (16,'Escultura (16)'); -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (17,'Obelisco (17)'); -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (18,'Torre (18)'); -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (19,'Administração (19)'); -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_edif_turist OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (9,'Cruzeiro (9)')# +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (10,'Estátua (10)')# +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (11,'Mirante (11)')# +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (12,'Monumento (12)')# +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (13,'Panteão (13)')# +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (14,'Chafariz (14)')# +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (15,'Chaminé (15)')# +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (16,'Escultura (16)')# +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (17,'Obelisco (17)')# +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (18,'Torre (18)')# +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (19,'Administração (19)')# +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_edif_turist (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_edif_turist OWNER TO postgres# CREATE TABLE dominios.tipo_trecho_duto ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_trecho_duto_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (1,'Duto (1)'); -INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (2,'Calha (2)'); -INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (3,'Correia transportadora (3)'); -INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (4,'Bueiro (4)'); -INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (5,'Galeria (5)'); -INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (1,'Duto (1)')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (2,'Calha (2)')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (3,'Correia transportadora (3)')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (4,'Bueiro (4)')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (5,'Galeria (5)')# +INSERT INTO dominios.tipo_trecho_duto (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_trecho_duto OWNER TO postgres; +ALTER TABLE dominios.tipo_trecho_duto OWNER TO postgres# CREATE TABLE dominios.tipo_unid_prot_integ ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_unid_prot_integ_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_unid_prot_integ (code,code_name) VALUES (1,'Estação ecológica - ESEC (1)'); -INSERT INTO dominios.tipo_unid_prot_integ (code,code_name) VALUES (2,'Parque - PAR (2)'); -INSERT INTO dominios.tipo_unid_prot_integ (code,code_name) VALUES (3,'Monumento natural – MONA (3)'); -INSERT INTO dominios.tipo_unid_prot_integ (code,code_name) VALUES (4,'Reserva biológica – REBIO (4)'); -INSERT INTO dominios.tipo_unid_prot_integ (code,code_name) VALUES (5,'Refúgio da vida silvestre – RVS (5)'); -INSERT INTO dominios.tipo_unid_prot_integ (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_unid_prot_integ (code,code_name) VALUES (1,'Estação ecológica - ESEC (1)')# +INSERT INTO dominios.tipo_unid_prot_integ (code,code_name) VALUES (2,'Parque - PAR (2)')# +INSERT INTO dominios.tipo_unid_prot_integ (code,code_name) VALUES (3,'Monumento natural – MONA (3)')# +INSERT INTO dominios.tipo_unid_prot_integ (code,code_name) VALUES (4,'Reserva biológica – REBIO (4)')# +INSERT INTO dominios.tipo_unid_prot_integ (code,code_name) VALUES (5,'Refúgio da vida silvestre – RVS (5)')# +INSERT INTO dominios.tipo_unid_prot_integ (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_unid_prot_integ OWNER TO postgres; +ALTER TABLE dominios.tipo_unid_prot_integ OWNER TO postgres# CREATE TABLE dominios.tipo_uso_edif ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_uso_edif_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (1,'Próprio nacional (1)'); -INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (2,'Uso da União (2)'); -INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (5,'Uso do município (5)'); -INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (6,'Uso da UF (6)'); -INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (1,'Próprio nacional (1)')# +INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (2,'Uso da União (2)')# +INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (5,'Uso do município (5)')# +INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (6,'Uso da UF (6)')# +INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_uso_edif (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_uso_edif OWNER TO postgres; +ALTER TABLE dominios.tipo_uso_edif OWNER TO postgres# CREATE TABLE dominios.tipo_dep_geral ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_dep_geral_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (1,'Tanque (1)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (2,'Caixa d''água (2)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (3,'Cisterna (3)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (4,'Depósito de lixo (4)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (5,'Aterro sanitário (5)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (6,'Aterro controlado (6)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (8,'Galpão (8)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (9,'Silo (9)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (10,'Composteira (10)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (11,'Depósito frigorífico (11)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (19,'Reservatório (19)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (26,'Barracão industrial (26)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (32,'Armazém (32)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_dep_geral OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (1,'Tanque (1)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (2,'Caixa d''água (2)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (3,'Cisterna (3)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (4,'Depósito de lixo (4)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (5,'Aterro sanitário (5)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (6,'Aterro controlado (6)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (8,'Galpão (8)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (9,'Silo (9)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (10,'Composteira (10)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (11,'Depósito frigorífico (11)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (19,'Reservatório (19)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (26,'Barracão industrial (26)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (32,'Armazém (32)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_dep_geral (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_dep_geral OWNER TO postgres# CREATE TABLE dominios.secao_ativ_econ ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT secao_ativ_econ_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.secao_ativ_econ (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.secao_ativ_econ (code,code_name) VALUES (1,'Indústrias extrativas (1)'); -INSERT INTO dominios.secao_ativ_econ (code,code_name) VALUES (2,'Indústrias de transformação (2)'); -INSERT INTO dominios.secao_ativ_econ (code,code_name) VALUES (3,'Construção (3)'); -INSERT INTO dominios.secao_ativ_econ (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.secao_ativ_econ (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.secao_ativ_econ (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.secao_ativ_econ (code,code_name) VALUES (1,'Indústrias extrativas (1)')# +INSERT INTO dominios.secao_ativ_econ (code,code_name) VALUES (2,'Indústrias de transformação (2)')# +INSERT INTO dominios.secao_ativ_econ (code,code_name) VALUES (3,'Construção (3)')# +INSERT INTO dominios.secao_ativ_econ (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.secao_ativ_econ (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.secao_ativ_econ OWNER TO postgres; +ALTER TABLE dominios.secao_ativ_econ OWNER TO postgres# CREATE TABLE dominios.sistema_geodesico ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT sistema_geodesico_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (1,'SAD-69 (1)'); -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (2,'SIRGAS2000 (2)'); -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (3,'WGS-84 (3)'); -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (4,'Córrego Alegre (4)'); -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (5,'Astro Chuá (5)'); -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (6,'Outra referência (6)'); -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (7,'SAD-69 (96) (7)'); -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (1,'SAD-69 (1)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (2,'SIRGAS2000 (2)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (3,'WGS-84 (3)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (4,'Córrego Alegre (4)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (5,'Astro Chuá (5)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (6,'Outra referência (6)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (7,'SAD-69 (96) (7)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.sistema_geodesico OWNER TO postgres; +ALTER TABLE dominios.sistema_geodesico OWNER TO postgres# CREATE TABLE dominios.tipo_trecho_comunic ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_trecho_comunic_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_trecho_comunic (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_trecho_comunic (code,code_name) VALUES (3,'Sinal de TV (3)'); -INSERT INTO dominios.tipo_trecho_comunic (code,code_name) VALUES (4,'Dados (4)'); -INSERT INTO dominios.tipo_trecho_comunic (code,code_name) VALUES (7,'Telefônica (7)'); -INSERT INTO dominios.tipo_trecho_comunic (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_trecho_comunic (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_trecho_comunic (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_trecho_comunic (code,code_name) VALUES (3,'Sinal de TV (3)')# +INSERT INTO dominios.tipo_trecho_comunic (code,code_name) VALUES (4,'Dados (4)')# +INSERT INTO dominios.tipo_trecho_comunic (code,code_name) VALUES (7,'Telefônica (7)')# +INSERT INTO dominios.tipo_trecho_comunic (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_trecho_comunic (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_trecho_comunic OWNER TO postgres; +ALTER TABLE dominios.tipo_trecho_comunic OWNER TO postgres# CREATE TABLE dominios.administracao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT administracao_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.administracao (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.administracao (code,code_name) VALUES (1,'Federal (1)'); -INSERT INTO dominios.administracao (code,code_name) VALUES (2,'Estadual/Distrital (2)'); -INSERT INTO dominios.administracao (code,code_name) VALUES (3,'Municipal (3)'); -INSERT INTO dominios.administracao (code,code_name) VALUES (7,'Concessionada (7)'); -INSERT INTO dominios.administracao (code,code_name) VALUES (15,'Privada (15)'); -INSERT INTO dominios.administracao (code,code_name) VALUES (97,'Não aplicável (97)'); -INSERT INTO dominios.administracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.administracao (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (1,'Federal (1)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (2,'Estadual/Distrital (2)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (3,'Municipal (3)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (7,'Concessionada (7)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (15,'Privada (15)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.administracao OWNER TO postgres; +ALTER TABLE dominios.administracao OWNER TO postgres# CREATE TABLE dominios.divisao_ativ_econ ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT divisao_ativ_econ_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (1,'Agricultura, pecuário e serviços relacionados (1)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (2,'Silvicultura, exploração florestal e serviços relacionados (2)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (5,'Pesca, aquicultura e serviços relacionados (5)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (10,'Extração de carvão mineral (10)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (11,'Extração de petróleo e serviços relacionados (11)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (13,'Extração de minerais metálicos (13)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (14,'Extração de produtos de minerais não metálicos (14)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (15,'Fabricação alimentícia e bebidas (15)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (16,'Fabricação de produtos do fumo (16)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (17,'Fabricação de produtos têxteis (17)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (18,'Confecção de artigos do vestuário e acessórios (18)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (19,'Preparação de couros e fabricação de artefatos de couro, artigos de viagens e calçados (19)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (20,'Fabricação de produtos de madeira e celulose (20)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (21,'Fabricação de celulose, papel e produtos de papel (21)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (22,'Edição, impressão e reprodução de gravações (22)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (23,'Fabricação de coque, refino de petróleo, elaboração de combustíveis nucleares e produção de álcool (23)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (24,'Fabricação de produtos químicos (24)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (25,'Fabricação de artigos de borracha e material plástico (25)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (26,'Fabricação de produtos de minerais não metálicos (26)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (27,'Metalurgia básica (27)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (28,'Fabricação de produtos de metal, exclusive máquinas e equipamentos (28)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (29,'Fabricação de máquinas e equipamentos (29)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (30,'Fabricação de máquinas de escritório e equipamentos de informática (30)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (31,'Fabricação de máquinas, aparelhos e materiais elétricos (31)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (32,'Fabricação de material eletrônico, e equipamentos de comunicações (32)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (33,'Fabricação de equipamentos de instrumentação médico-hospitalares, instrumentos de precisão e ópticos, equipamentos para automação industrial, cronômetros e relógios (33)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (34,'Fabricação e montagem de veículos automotores, reboques e carrocerias (34)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (35,'Fabricação de outros equipamentos de transporte (35)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (36,'Fabricação de móveis e indústrias diversas (36)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (37,'Reciclagem (37)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (45,'Construção (45)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (50,'Comércio e reparação de veículos automotores e motocicletas e comércio a varejo de combustíveis (50)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (51,'Comércio por atacado e representantes comerciais e agentes do comércio (51)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (52,'Comércio varejista e reparação de objetos pessoais e domésticos (52)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (55,'Alojamento e alimentação (55)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (74,'Serviços prestados principalmente a empresas (organizações) (74)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (92,'Atividades recreativas, culturais e desportivas (92)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.divisao_ativ_econ OWNER TO postgres; +)# + +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (1,'Agricultura, pecuário e serviços relacionados (1)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (2,'Silvicultura, exploração florestal e serviços relacionados (2)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (5,'Pesca, aquicultura e serviços relacionados (5)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (10,'Extração de carvão mineral (10)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (11,'Extração de petróleo e serviços relacionados (11)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (13,'Extração de minerais metálicos (13)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (14,'Extração de produtos de minerais não metálicos (14)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (15,'Fabricação alimentícia e bebidas (15)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (16,'Fabricação de produtos do fumo (16)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (17,'Fabricação de produtos têxteis (17)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (18,'Confecção de artigos do vestuário e acessórios (18)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (19,'Preparação de couros e fabricação de artefatos de couro, artigos de viagens e calçados (19)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (20,'Fabricação de produtos de madeira e celulose (20)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (21,'Fabricação de celulose, papel e produtos de papel (21)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (22,'Edição, impressão e reprodução de gravações (22)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (23,'Fabricação de coque, refino de petróleo, elaboração de combustíveis nucleares e produção de álcool (23)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (24,'Fabricação de produtos químicos (24)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (25,'Fabricação de artigos de borracha e material plástico (25)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (26,'Fabricação de produtos de minerais não metálicos (26)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (27,'Metalurgia básica (27)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (28,'Fabricação de produtos de metal, exclusive máquinas e equipamentos (28)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (29,'Fabricação de máquinas e equipamentos (29)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (30,'Fabricação de máquinas de escritório e equipamentos de informática (30)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (31,'Fabricação de máquinas, aparelhos e materiais elétricos (31)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (32,'Fabricação de material eletrônico, e equipamentos de comunicações (32)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (33,'Fabricação de equipamentos de instrumentação médico-hospitalares, instrumentos de precisão e ópticos, equipamentos para automação industrial, cronômetros e relógios (33)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (34,'Fabricação e montagem de veículos automotores, reboques e carrocerias (34)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (35,'Fabricação de outros equipamentos de transporte (35)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (36,'Fabricação de móveis e indústrias diversas (36)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (37,'Reciclagem (37)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (45,'Construção (45)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (50,'Comércio e reparação de veículos automotores e motocicletas e comércio a varejo de combustíveis (50)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (51,'Comércio por atacado e representantes comerciais e agentes do comércio (51)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (52,'Comércio varejista e reparação de objetos pessoais e domésticos (52)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (55,'Alojamento e alimentação (55)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (74,'Serviços prestados principalmente a empresas (organizações) (74)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (92,'Atividades recreativas, culturais e desportivas (92)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.divisao_ativ_econ (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.divisao_ativ_econ OWNER TO postgres# CREATE TABLE dominios.grupo_ativ_econ ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT grupo_ativ_econ_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (6,'Administração do Estado e da política econômica e social (6)'); -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (8,'Serviços coletivos prestados pela administração (8)'); -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (15,'Seguridade social (15)'); -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (16,'Educação infantil e ensino fundamental (16)'); -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (19,'Ensino médio (19)'); -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (20,'Ensino superior (20)'); -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (23,'Educação profissional e outras atividades de ensino (23)'); -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (30,'Atividades de atenção à saúde (30)'); -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (31,'Serviços veterinários (31)'); -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (32,'Serviço social (32)'); -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (98,'Misto (98)'); -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.grupo_ativ_econ OWNER TO postgres; +)# + +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (6,'Administração do Estado e da política econômica e social (6)')# +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (8,'Serviços coletivos prestados pela administração (8)')# +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (15,'Seguridade social (15)')# +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (16,'Educação infantil e ensino fundamental (16)')# +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (19,'Ensino médio (19)')# +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (20,'Ensino superior (20)')# +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (23,'Educação profissional e outras atividades de ensino (23)')# +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (30,'Atividades de atenção à saúde (30)')# +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (31,'Serviços veterinários (31)')# +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (32,'Serviço social (32)')# +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (98,'Misto (98)')# +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.grupo_ativ_econ (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.grupo_ativ_econ OWNER TO postgres# CREATE TABLE dominios.tipo_via ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_via_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_via (code,code_name) VALUES (1,'Logradouro (1)'); -INSERT INTO dominios.tipo_via (code,code_name) VALUES (2,'Rodovia (2)'); -INSERT INTO dominios.tipo_via (code,code_name) VALUES (3,'Beco (3)'); -INSERT INTO dominios.tipo_via (code,code_name) VALUES (4,'Autoestrada (4)'); -INSERT INTO dominios.tipo_via (code,code_name) VALUES (5,'Ligação entre pistas (5)'); -INSERT INTO dominios.tipo_via (code,code_name) VALUES (6,'Trecho de entroncamento (6)'); -INSERT INTO dominios.tipo_via (code,code_name) VALUES (7,'Servidão (7)'); -INSERT INTO dominios.tipo_via (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_via (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_via (code,code_name) VALUES (1,'Logradouro (1)')# +INSERT INTO dominios.tipo_via (code,code_name) VALUES (2,'Rodovia (2)')# +INSERT INTO dominios.tipo_via (code,code_name) VALUES (3,'Beco (3)')# +INSERT INTO dominios.tipo_via (code,code_name) VALUES (4,'Autoestrada (4)')# +INSERT INTO dominios.tipo_via (code,code_name) VALUES (5,'Ligação entre pistas (5)')# +INSERT INTO dominios.tipo_via (code,code_name) VALUES (6,'Trecho de entroncamento (6)')# +INSERT INTO dominios.tipo_via (code,code_name) VALUES (7,'Servidão (7)')# +INSERT INTO dominios.tipo_via (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_via (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_via OWNER TO postgres; +ALTER TABLE dominios.tipo_via OWNER TO postgres# CREATE TABLE dominios.cultivo_predominante ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT cultivo_predominante_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (1,'Milho (1)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (2,'Banana (2)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (3,'Laranja (3)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (4,'Trigo (4)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (6,'Algodão herbáceo (6)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (7,'Cana-de-açúcar (7)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (8,'Fumo (8)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (9,'Soja (9)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (10,'Batata inglesa (10)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (11,'Mandioca, aipim ou macaxeira (11)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (12,'Feijão (12)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (13,'Arroz (13)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (14,'Café (14)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (15,'Cacau (15)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (16,'Erva-mate (16)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (17,'Palmeira (17)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (18,'Açaí (18)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (19,'Seringueira (19)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (20,'Eucalipto (20)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (21,'Acácia (21)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (22,'Algaroba (22)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (23,'Pinus (23)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (24,'Pastagem cultivada (24)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (25,'Hortaliças (25)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (26,'Bracatinga (26)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (27,'Araucária (27)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (28,'Carnaúba (28)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (29,'Pera (29)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (30,'Maçã (30)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (31,'Pêssego (31)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (32,'Juta (32)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (33,'Cebola (33)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (42,'Videira (42)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (43,'Abacate (43)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (44,'Abacaxi ou ananás (44)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (45,'Abóbora (45)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (46,'Acerola (46)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (47,'Alcachofra (47)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (48,'Alfafa (48)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (49,'Algodão arbóreo (49)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (50,'Alho (50)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (51,'Ameixa (51)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (52,'Amendoim (52)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (53,'Amora (53)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (54,'Aveia (54)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (55,'Azeitona (55)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (56,'Azevem (56)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (57,'Batata-doce (57)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (58,'Caju (58)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (59,'Caqui (59)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (60,'Carambola (60)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (61,'Centeio (61)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (62,'Cevada (62)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (63,'Chá-da-índia (63)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (64,'Cidra (64)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (65,'Coco-da-baía (65)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (66,'Cravo-da-índia (66)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (67,'Cupuaçu (67)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (68,'Dendê (68)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (69,'Ervilha (69)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (70,'Fava (70)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (71,'Figo (71)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (72,'Flores (72)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (73,'Girassol (73)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (74,'Goiaba (74)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (75,'Grão-de-Bico (75)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (76,'Guaraná (76)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (77,'Inhame (77)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (78,'Kiwi (78)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (79,'Lentilha (79)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (80,'Limão (80)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (81,'Linho (81)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (82,'Malva (82)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (83,'Mamão (83)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (84,'Mamona (84)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (85,'Manga (85)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (86,'Maracujá (86)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (87,'Marmelo (87)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (88,'Melancia (88)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (89,'Melão (89)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (90,'Milheto (90)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (96,'Não identificado (96)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (98,'Misto (98)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (100,'Nabo forrageiro (100)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (101,'Noz (101)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (102,'Palmito (102)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (103,'Pepino (103)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (104,'Piaçava (104)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (105,'Pimenta-do-reino (105)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (106,'Plantas ornamentais (106)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (108,'Rami (108)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (110,'Sisal ou agave (110)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (111,'Sorgo (111)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (112,'Tangerina (112)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (113,'Tomate (113)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (114,'Triticale (114)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (115,'Tungue (115)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (116,'Urucum (116)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (117,'Gergelim (117)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (118,'Pupunha (118)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (119,'Lima (119)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (120,'Araçá (120)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (121,'Cultura rotativa (121)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (122,'Mandacaru (122)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (123,'Milho pipoca (123)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (124,'Morango (124)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (125,'Graviola (125)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (126,'Uva (126)'); -INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.cultivo_predominante OWNER TO postgres; +)# + +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (1,'Milho (1)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (2,'Banana (2)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (3,'Laranja (3)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (4,'Trigo (4)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (6,'Algodão herbáceo (6)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (7,'Cana-de-açúcar (7)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (8,'Fumo (8)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (9,'Soja (9)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (10,'Batata inglesa (10)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (11,'Mandioca, aipim ou macaxeira (11)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (12,'Feijão (12)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (13,'Arroz (13)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (14,'Café (14)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (15,'Cacau (15)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (16,'Erva-mate (16)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (17,'Palmeira (17)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (18,'Açaí (18)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (19,'Seringueira (19)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (20,'Eucalipto (20)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (21,'Acácia (21)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (22,'Algaroba (22)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (23,'Pinus (23)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (24,'Pastagem cultivada (24)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (25,'Hortaliças (25)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (26,'Bracatinga (26)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (27,'Araucária (27)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (28,'Carnaúba (28)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (29,'Pera (29)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (30,'Maçã (30)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (31,'Pêssego (31)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (32,'Juta (32)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (33,'Cebola (33)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (42,'Videira (42)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (43,'Abacate (43)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (44,'Abacaxi ou ananás (44)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (45,'Abóbora (45)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (46,'Acerola (46)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (47,'Alcachofra (47)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (48,'Alfafa (48)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (49,'Algodão arbóreo (49)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (50,'Alho (50)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (51,'Ameixa (51)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (52,'Amendoim (52)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (53,'Amora (53)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (54,'Aveia (54)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (55,'Azeitona (55)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (56,'Azevem (56)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (57,'Batata-doce (57)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (58,'Caju (58)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (59,'Caqui (59)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (60,'Carambola (60)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (61,'Centeio (61)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (62,'Cevada (62)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (63,'Chá-da-índia (63)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (64,'Cidra (64)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (65,'Coco-da-baía (65)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (66,'Cravo-da-índia (66)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (67,'Cupuaçu (67)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (68,'Dendê (68)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (69,'Ervilha (69)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (70,'Fava (70)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (71,'Figo (71)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (72,'Flores (72)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (73,'Girassol (73)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (74,'Goiaba (74)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (75,'Grão-de-Bico (75)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (76,'Guaraná (76)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (77,'Inhame (77)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (78,'Kiwi (78)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (79,'Lentilha (79)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (80,'Limão (80)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (81,'Linho (81)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (82,'Malva (82)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (83,'Mamão (83)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (84,'Mamona (84)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (85,'Manga (85)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (86,'Maracujá (86)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (87,'Marmelo (87)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (88,'Melancia (88)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (89,'Melão (89)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (90,'Milheto (90)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (96,'Não identificado (96)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (98,'Misto (98)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (100,'Nabo forrageiro (100)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (101,'Noz (101)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (102,'Palmito (102)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (103,'Pepino (103)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (104,'Piaçava (104)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (105,'Pimenta-do-reino (105)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (106,'Plantas ornamentais (106)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (108,'Rami (108)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (110,'Sisal ou agave (110)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (111,'Sorgo (111)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (112,'Tangerina (112)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (113,'Tomate (113)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (114,'Triticale (114)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (115,'Tungue (115)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (116,'Urucum (116)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (117,'Gergelim (117)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (118,'Pupunha (118)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (119,'Lima (119)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (120,'Araçá (120)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (121,'Cultura rotativa (121)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (122,'Mandacaru (122)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (123,'Milho pipoca (123)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (124,'Morango (124)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (125,'Graviola (125)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (126,'Uva (126)')# +INSERT INTO dominios.cultivo_predominante (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.cultivo_predominante OWNER TO postgres# CREATE TABLE dominios.forma_rocha ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT forma_rocha_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.forma_rocha (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.forma_rocha (code,code_name) VALUES (21,'Matacão - pedra (21)'); -INSERT INTO dominios.forma_rocha (code,code_name) VALUES (22,'Penedo isolado (22)'); -INSERT INTO dominios.forma_rocha (code,code_name) VALUES (23,'Área rochosa - lajedo (23)'); -INSERT INTO dominios.forma_rocha (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.forma_rocha (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.forma_rocha (code,code_name) VALUES (21,'Matacão - pedra (21)')# +INSERT INTO dominios.forma_rocha (code,code_name) VALUES (22,'Penedo isolado (22)')# +INSERT INTO dominios.forma_rocha (code,code_name) VALUES (23,'Área rochosa - lajedo (23)')# +INSERT INTO dominios.forma_rocha (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.forma_rocha OWNER TO postgres; +ALTER TABLE dominios.forma_rocha OWNER TO postgres# CREATE TABLE dominios.tipo_hierarquia ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_hierarquia_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (3,'Municipal (3)'); -INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (23,'Estadual (23)'); -INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (24,'Internacional secundário (24)'); -INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (25,'Internacional de referência (25)'); -INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (26,'Internacional principal (26)'); -INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (3,'Municipal (3)')# +INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (23,'Estadual (23)')# +INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (24,'Internacional secundário (24)')# +INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (25,'Internacional de referência (25)')# +INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (26,'Internacional principal (26)')# +INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_hierarquia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_hierarquia OWNER TO postgres; +ALTER TABLE dominios.tipo_hierarquia OWNER TO postgres# CREATE TABLE dominios.tipo_transporte ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_transporte_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_transporte (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_transporte (code,code_name) VALUES (21,'Passageiro (21)'); -INSERT INTO dominios.tipo_transporte (code,code_name) VALUES (22,'Carga (22)'); -INSERT INTO dominios.tipo_transporte (code,code_name) VALUES (98,'Misto (98)'); -INSERT INTO dominios.tipo_transporte (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_transporte (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_transporte (code,code_name) VALUES (21,'Passageiro (21)')# +INSERT INTO dominios.tipo_transporte (code,code_name) VALUES (22,'Carga (22)')# +INSERT INTO dominios.tipo_transporte (code,code_name) VALUES (98,'Misto (98)')# +INSERT INTO dominios.tipo_transporte (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_transporte OWNER TO postgres; +ALTER TABLE dominios.tipo_transporte OWNER TO postgres# CREATE TABLE dominios.sigla_uf ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT sigla_uf_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (1,'AC (1)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (2,'AL (2)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (3,'AM (3)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (4,'AP (4)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (5,'BA (5)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (6,'CE (6)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (7,'DF (7)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (8,'ES (8)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (9,'GO (9)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (10,'MA (10)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (11,'MG (11)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (12,'MS (12)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (13,'MT (13)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (14,'PA (14)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (15,'PB (15)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (16,'PE (16)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (17,'PI (17)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (18,'PR (18)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (19,'RJ (19)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (20,'RN (20)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (21,'RO (21)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (22,'RR (22)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (23,'RS (23)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (24,'SC (24)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (25,'SE (25)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (26,'SP (26)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (27,'TO (27)'); -INSERT INTO dominios.sigla_uf (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.sigla_uf OWNER TO postgres; +)# + +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (1,'AC (1)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (2,'AL (2)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (3,'AM (3)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (4,'AP (4)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (5,'BA (5)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (6,'CE (6)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (7,'DF (7)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (8,'ES (8)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (9,'GO (9)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (10,'MA (10)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (11,'MG (11)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (12,'MS (12)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (13,'MT (13)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (14,'PA (14)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (15,'PB (15)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (16,'PE (16)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (17,'PI (17)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (18,'PR (18)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (19,'RJ (19)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (20,'RN (20)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (21,'RO (21)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (22,'RR (22)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (23,'RS (23)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (24,'SC (24)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (25,'SE (25)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (26,'SP (26)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (27,'TO (27)')# +INSERT INTO dominios.sigla_uf (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.sigla_uf OWNER TO postgres# CREATE TABLE dominios.referencial_grav ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT referencial_grav_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (1,'Potsdam 1930 (1)'); -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (2,'IGSN71 (2)'); -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (3,'Absoluto (3)'); -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (4,'Local (4)'); -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (5,'RGFB (5)'); -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (97,'Não aplicável (97)'); -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (1,'Potsdam 1930 (1)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (2,'IGSN71 (2)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (3,'Absoluto (3)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (4,'Local (4)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (5,'RGFB (5)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.referencial_grav OWNER TO postgres; +ALTER TABLE dominios.referencial_grav OWNER TO postgres# CREATE TABLE dominios.tipo_pista_comp ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_pista_comp_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (1,'Atletismo (1)'); -INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (2,'Ciclismo (2)'); -INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (3,'Motociclismo (3)'); -INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (4,'Automobilismo (4)'); -INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (5,'Corrida de cavalos (5)'); -INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (6,'Bicicross (6)'); -INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (7,'Motocross (7)'); -INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (98,'Misto (98)'); -INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_pista_comp OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (1,'Atletismo (1)')# +INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (2,'Ciclismo (2)')# +INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (3,'Motociclismo (3)')# +INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (4,'Automobilismo (4)')# +INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (5,'Corrida de cavalos (5)')# +INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (6,'Bicicross (6)')# +INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (7,'Motocross (7)')# +INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (98,'Misto (98)')# +INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_pista_comp (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_pista_comp OWNER TO postgres# CREATE TABLE dominios.estado_fisico ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT estado_fisico_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.estado_fisico (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.estado_fisico (code,code_name) VALUES (1,'Líquido (1)'); -INSERT INTO dominios.estado_fisico (code,code_name) VALUES (2,'Sólido (2)'); -INSERT INTO dominios.estado_fisico (code,code_name) VALUES (3,'Gasoso (3)'); -INSERT INTO dominios.estado_fisico (code,code_name) VALUES (98,'Misto (98)'); -INSERT INTO dominios.estado_fisico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.estado_fisico (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.estado_fisico (code,code_name) VALUES (1,'Líquido (1)')# +INSERT INTO dominios.estado_fisico (code,code_name) VALUES (2,'Sólido (2)')# +INSERT INTO dominios.estado_fisico (code,code_name) VALUES (3,'Gasoso (3)')# +INSERT INTO dominios.estado_fisico (code,code_name) VALUES (98,'Misto (98)')# +INSERT INTO dominios.estado_fisico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.estado_fisico OWNER TO postgres; +ALTER TABLE dominios.estado_fisico OWNER TO postgres# CREATE TABLE dominios.tipo_travessia ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_travessia_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (1,'Vau natural (1)'); -INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (2,'Vau construída (2)'); -INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (3,'Bote transportador (3)'); -INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (4,'Balsa (4)'); -INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (1,'Vau natural (1)')# +INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (2,'Vau construída (2)')# +INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (3,'Bote transportador (3)')# +INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (4,'Balsa (4)')# +INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_travessia OWNER TO postgres; +ALTER TABLE dominios.tipo_travessia OWNER TO postgres# CREATE TABLE dominios.tipo_atracad ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_atracad_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (38,'Cais (38)'); -INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (39,'Cais flutuante (39)'); -INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (40,'Trapiche (40)'); -INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (41,'Molhe de atracação (41)'); -INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (42,'Píer (42)'); -INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (43,'Dolfim (43)'); -INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (44,'Desembarcadouro (44)'); -INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (38,'Cais (38)')# +INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (39,'Cais flutuante (39)')# +INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (40,'Trapiche (40)')# +INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (41,'Molhe de atracação (41)')# +INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (42,'Píer (42)')# +INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (43,'Dolfim (43)')# +INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (44,'Desembarcadouro (44)')# +INSERT INTO dominios.tipo_atracad (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_atracad OWNER TO postgres; +ALTER TABLE dominios.tipo_atracad OWNER TO postgres# CREATE TABLE dominios.uso_principal ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT uso_principal_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.uso_principal (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.uso_principal (code,code_name) VALUES (1,'Irrigação (1)'); -INSERT INTO dominios.uso_principal (code,code_name) VALUES (2,'Abastecimento (2)'); -INSERT INTO dominios.uso_principal (code,code_name) VALUES (3,'Energia (3)'); -INSERT INTO dominios.uso_principal (code,code_name) VALUES (4,'Lazer (4)'); -INSERT INTO dominios.uso_principal (code,code_name) VALUES (5,'Dessedentação animal (5)'); -INSERT INTO dominios.uso_principal (code,code_name) VALUES (6,'Drenagem (6)'); -INSERT INTO dominios.uso_principal (code,code_name) VALUES (97,'Não aplicável (97)'); -INSERT INTO dominios.uso_principal (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.uso_principal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.uso_principal (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.uso_principal (code,code_name) VALUES (1,'Irrigação (1)')# +INSERT INTO dominios.uso_principal (code,code_name) VALUES (2,'Abastecimento (2)')# +INSERT INTO dominios.uso_principal (code,code_name) VALUES (3,'Energia (3)')# +INSERT INTO dominios.uso_principal (code,code_name) VALUES (4,'Lazer (4)')# +INSERT INTO dominios.uso_principal (code,code_name) VALUES (5,'Dessedentação animal (5)')# +INSERT INTO dominios.uso_principal (code,code_name) VALUES (6,'Drenagem (6)')# +INSERT INTO dominios.uso_principal (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.uso_principal (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.uso_principal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.uso_principal OWNER TO postgres; +ALTER TABLE dominios.uso_principal OWNER TO postgres# CREATE TABLE dominios.densidade ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT densidade_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.densidade (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.densidade (code,code_name) VALUES (1,'Alta (1)'); -INSERT INTO dominios.densidade (code,code_name) VALUES (2,'Baixa (2)'); -INSERT INTO dominios.densidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.densidade (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.densidade (code,code_name) VALUES (1,'Alta (1)')# +INSERT INTO dominios.densidade (code,code_name) VALUES (2,'Baixa (2)')# +INSERT INTO dominios.densidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.densidade OWNER TO postgres; +ALTER TABLE dominios.densidade OWNER TO postgres# CREATE TABLE dominios.atividade ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT atividade_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.atividade (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.atividade (code,code_name) VALUES (9,'Prospecção (9)'); -INSERT INTO dominios.atividade (code,code_name) VALUES (10,'Produção (10)'); -INSERT INTO dominios.atividade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.atividade (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.atividade (code,code_name) VALUES (9,'Prospecção (9)')# +INSERT INTO dominios.atividade (code,code_name) VALUES (10,'Produção (10)')# +INSERT INTO dominios.atividade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.atividade OWNER TO postgres; +ALTER TABLE dominios.atividade OWNER TO postgres# CREATE TABLE dominios.tipo_ahe ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_ahe_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_ahe (code,code_name) VALUES (1,'UHE (1)'); -INSERT INTO dominios.tipo_ahe (code,code_name) VALUES (2,'PCH (2)'); -INSERT INTO dominios.tipo_ahe (code,code_name) VALUES (3,'CGH (3)'); -INSERT INTO dominios.tipo_ahe (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_ahe (code,code_name) VALUES (1,'UHE (1)')# +INSERT INTO dominios.tipo_ahe (code,code_name) VALUES (2,'PCH (2)')# +INSERT INTO dominios.tipo_ahe (code,code_name) VALUES (3,'CGH (3)')# +INSERT INTO dominios.tipo_ahe (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_ahe OWNER TO postgres; +ALTER TABLE dominios.tipo_ahe OWNER TO postgres# CREATE TABLE dominios.tipo_vegetacao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_vegetacao_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (2,'Vegetação cultivada (2)'); -INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (3,'Floresta (3)'); -INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (4,'Vegetação de mangue (4)'); -INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (5,'Refúgio ecológico (5)'); -INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (6,'Campinarana (6)'); -INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (7,'Cerrado (7)'); -INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (8,'Vegetação de restinga (8)'); -INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (9,'Estepe (9)'); -INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (10,'Vegetação de brejo ou pântano (10)'); -INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (11,'Caatinga (11)'); -INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_vegetacao OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (2,'Vegetação cultivada (2)')# +INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (3,'Floresta (3)')# +INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (4,'Vegetação de mangue (4)')# +INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (5,'Refúgio ecológico (5)')# +INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (6,'Campinarana (6)')# +INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (7,'Cerrado (7)')# +INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (8,'Vegetação de restinga (8)')# +INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (9,'Estepe (9)')# +INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (10,'Vegetação de brejo ou pântano (10)')# +INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (11,'Caatinga (11)')# +INSERT INTO dominios.tipo_vegetacao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_vegetacao OWNER TO postgres# CREATE TABLE dominios.tipo_curva_nivel ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_curva_nivel_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_curva_nivel (code,code_name) VALUES (1,'Mestra (1)'); -INSERT INTO dominios.tipo_curva_nivel (code,code_name) VALUES (2,'Normal (2)'); -INSERT INTO dominios.tipo_curva_nivel (code,code_name) VALUES (3,'Auxiliar (3)'); -INSERT INTO dominios.tipo_curva_nivel (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_curva_nivel (code,code_name) VALUES (1,'Mestra (1)')# +INSERT INTO dominios.tipo_curva_nivel (code,code_name) VALUES (2,'Normal (2)')# +INSERT INTO dominios.tipo_curva_nivel (code,code_name) VALUES (3,'Auxiliar (3)')# +INSERT INTO dominios.tipo_curva_nivel (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_curva_nivel OWNER TO postgres; +ALTER TABLE dominios.tipo_curva_nivel OWNER TO postgres# CREATE TABLE dominios.modalidade ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT modalidade_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.modalidade (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.modalidade (code,code_name) VALUES (1,'Radiocomunicação (1)'); -INSERT INTO dominios.modalidade (code,code_name) VALUES (2,'Imagem (2)'); -INSERT INTO dominios.modalidade (code,code_name) VALUES (3,'Telefonia (3)'); -INSERT INTO dominios.modalidade (code,code_name) VALUES (4,'Dados (4)'); -INSERT INTO dominios.modalidade (code,code_name) VALUES (5,'Som (5)'); -INSERT INTO dominios.modalidade (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.modalidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.modalidade (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.modalidade (code,code_name) VALUES (1,'Radiocomunicação (1)')# +INSERT INTO dominios.modalidade (code,code_name) VALUES (2,'Imagem (2)')# +INSERT INTO dominios.modalidade (code,code_name) VALUES (3,'Telefonia (3)')# +INSERT INTO dominios.modalidade (code,code_name) VALUES (4,'Dados (4)')# +INSERT INTO dominios.modalidade (code,code_name) VALUES (5,'Som (5)')# +INSERT INTO dominios.modalidade (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.modalidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.modalidade OWNER TO postgres; +ALTER TABLE dominios.modalidade OWNER TO postgres# CREATE TABLE dominios.tipo_instal_militar ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_instal_militar_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (12,'Aquartelamento (12)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (13,'Campo de instrução (13)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (14,'Campo de tiro (14)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (15,'Base aérea (15)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (16,'Distrito naval (16)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (17,'Hotel de trânsito (17)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (18,'Delegacia de serviço militar (18)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (20,'Quartel general (20)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (21,'Posto de vigilância (21)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (22,'Posto de policiamento urbano (22)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (23,'Posto de policiamento rodoviário (23)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (24,'Capitania dos portos (24)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (25,'Base naval (25)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_instal_militar OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (12,'Aquartelamento (12)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (13,'Campo de instrução (13)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (14,'Campo de tiro (14)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (15,'Base aérea (15)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (16,'Distrito naval (16)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (17,'Hotel de trânsito (17)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (18,'Delegacia de serviço militar (18)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (20,'Quartel general (20)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (21,'Posto de vigilância (21)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (22,'Posto de policiamento urbano (22)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (23,'Posto de policiamento rodoviário (23)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (24,'Capitania dos portos (24)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (25,'Base naval (25)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_instal_militar (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_instal_militar OWNER TO postgres# CREATE TABLE dominios.uso_pista ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT uso_pista_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.uso_pista (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.uso_pista (code,code_name) VALUES (6,'Particular (6)'); -INSERT INTO dominios.uso_pista (code,code_name) VALUES (11,'Público (11)'); -INSERT INTO dominios.uso_pista (code,code_name) VALUES (12,'Militar (12)'); -INSERT INTO dominios.uso_pista (code,code_name) VALUES (13,'Público compartilhado com uso militar (13)'); -INSERT INTO dominios.uso_pista (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.uso_pista (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (6,'Particular (6)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (11,'Público (11)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (12,'Militar (12)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (13,'Público compartilhado com uso militar (13)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.uso_pista OWNER TO postgres; +ALTER TABLE dominios.uso_pista OWNER TO postgres# CREATE TABLE dominios.tipo_combustivel ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_combustivel_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (1,'Nuclear (1)'); -INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (3,'Diesel (3)'); -INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (5,'Gás (5)'); -INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (7,'Biomassa (7)'); -INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (33,'Carvão (33)'); -INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (98,'Misto (98)'); -INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (1,'Nuclear (1)')# +INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (3,'Diesel (3)')# +INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (5,'Gás (5)')# +INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (7,'Biomassa (7)')# +INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (33,'Carvão (33)')# +INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (98,'Misto (98)')# +INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_combustivel (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_combustivel OWNER TO postgres; +ALTER TABLE dominios.tipo_combustivel OWNER TO postgres# CREATE TABLE dominios.tipo_equip_agropec ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_equip_agropec_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (1,'Pivô central (1)'); -INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (2,'Moinho (2)'); -INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (3,'Elevador de grãos (3)'); -INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (4,'Moega (4)'); -INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (5,'Secador (5)'); -INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (6,'Tombador (6)'); -INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (1,'Pivô central (1)')# +INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (2,'Moinho (2)')# +INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (3,'Elevador de grãos (3)')# +INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (4,'Moega (4)')# +INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (5,'Secador (5)')# +INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (6,'Tombador (6)')# +INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_equip_agropec (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_equip_agropec OWNER TO postgres; +ALTER TABLE dominios.tipo_equip_agropec OWNER TO postgres# CREATE TABLE dominios.tipo_org_civil ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_org_civil_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (1,'Policial (1)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (2,'Prisional (2)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (3,'Cartorial (3)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (4,'Gestão (4)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (5,'Eleitoral (5)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (6,'Produção e/ou pesquisa (6)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (7,'Seguridade social (7)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (8,'Câmara municipal (8)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (9,'Assembleia legislativa (9)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (10,'Autarquia (10)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (11,'Delegacia de polícia civil (11)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (12,'Educação (12)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (13,'Fórum (13)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (14,'Fundação (14)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (15,'Procuradoria (15)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (16,'Secretaria (16)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (22,'Prefeitura (22)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_org_civil OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (1,'Policial (1)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (2,'Prisional (2)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (3,'Cartorial (3)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (4,'Gestão (4)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (5,'Eleitoral (5)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (6,'Produção e/ou pesquisa (6)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (7,'Seguridade social (7)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (8,'Câmara municipal (8)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (9,'Assembleia legislativa (9)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (10,'Autarquia (10)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (11,'Delegacia de polícia civil (11)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (12,'Educação (12)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (13,'Fórum (13)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (14,'Fundação (14)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (15,'Procuradoria (15)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (16,'Secretaria (16)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (22,'Prefeitura (22)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_org_civil (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_org_civil OWNER TO postgres# CREATE TABLE dominios.modal_uso ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT modal_uso_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.modal_uso (code,code_name) VALUES (4,'Rodoviário (4)'); -INSERT INTO dominios.modal_uso (code,code_name) VALUES (5,'Ferroviário (5)'); -INSERT INTO dominios.modal_uso (code,code_name) VALUES (6,'Metroviário (6)'); -INSERT INTO dominios.modal_uso (code,code_name) VALUES (7,'Dutos (7)'); -INSERT INTO dominios.modal_uso (code,code_name) VALUES (9,'Aeroportuário (9)'); -INSERT INTO dominios.modal_uso (code,code_name) VALUES (10,'Hidroviário (10)'); -INSERT INTO dominios.modal_uso (code,code_name) VALUES (14,'Portuário (14)'); -INSERT INTO dominios.modal_uso (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.modal_uso (code,code_name) VALUES (4,'Rodoviário (4)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (5,'Ferroviário (5)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (6,'Metroviário (6)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (7,'Dutos (7)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (9,'Aeroportuário (9)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (10,'Hidroviário (10)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (14,'Portuário (14)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.modal_uso OWNER TO postgres; +ALTER TABLE dominios.modal_uso OWNER TO postgres# CREATE TABLE dominios.causa ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT causa_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.causa (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.causa (code,code_name) VALUES (1,'Canalização (1)'); -INSERT INTO dominios.causa (code,code_name) VALUES (2,'Gruta ou fenda (2)'); -INSERT INTO dominios.causa (code,code_name) VALUES (3,'Absorção (3)'); -INSERT INTO dominios.causa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.causa (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.causa (code,code_name) VALUES (1,'Canalização (1)')# +INSERT INTO dominios.causa (code,code_name) VALUES (2,'Gruta ou fenda (2)')# +INSERT INTO dominios.causa (code,code_name) VALUES (3,'Absorção (3)')# +INSERT INTO dominios.causa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.causa OWNER TO postgres; +ALTER TABLE dominios.causa OWNER TO postgres# CREATE TABLE dominios.regime ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT regime_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.regime (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.regime (code,code_name) VALUES (1,'Permanente (1)'); -INSERT INTO dominios.regime (code,code_name) VALUES (2,'Permanente com grande variação (2)'); -INSERT INTO dominios.regime (code,code_name) VALUES (3,'Temporário (3)'); -INSERT INTO dominios.regime (code,code_name) VALUES (4,'Temporário com leito permanente (4)'); -INSERT INTO dominios.regime (code,code_name) VALUES (5,'Seco (5)'); -INSERT INTO dominios.regime (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.regime (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.regime (code,code_name) VALUES (1,'Permanente (1)')# +INSERT INTO dominios.regime (code,code_name) VALUES (2,'Permanente com grande variação (2)')# +INSERT INTO dominios.regime (code,code_name) VALUES (3,'Temporário (3)')# +INSERT INTO dominios.regime (code,code_name) VALUES (4,'Temporário com leito permanente (4)')# +INSERT INTO dominios.regime (code,code_name) VALUES (5,'Seco (5)')# +INSERT INTO dominios.regime (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.regime OWNER TO postgres; +ALTER TABLE dominios.regime OWNER TO postgres# CREATE TABLE dominios.rede_referencia ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT rede_referencia_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.rede_referencia (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.rede_referencia (code,code_name) VALUES (2,'Estadual (2)'); -INSERT INTO dominios.rede_referencia (code,code_name) VALUES (3,'Municipal (3)'); -INSERT INTO dominios.rede_referencia (code,code_name) VALUES (14,'Nacional (14)'); -INSERT INTO dominios.rede_referencia (code,code_name) VALUES (15,'Privada (15)'); -INSERT INTO dominios.rede_referencia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.rede_referencia (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.rede_referencia (code,code_name) VALUES (2,'Estadual (2)')# +INSERT INTO dominios.rede_referencia (code,code_name) VALUES (3,'Municipal (3)')# +INSERT INTO dominios.rede_referencia (code,code_name) VALUES (14,'Nacional (14)')# +INSERT INTO dominios.rede_referencia (code,code_name) VALUES (15,'Privada (15)')# +INSERT INTO dominios.rede_referencia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.rede_referencia OWNER TO postgres; +ALTER TABLE dominios.rede_referencia OWNER TO postgres# CREATE TABLE dominios.especie_trecho_energia ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT especie_trecho_energia_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.especie_trecho_energia (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.especie_trecho_energia (code,code_name) VALUES (2,'Transmissão (2)'); -INSERT INTO dominios.especie_trecho_energia (code,code_name) VALUES (3,'Distribuição (3)'); -INSERT INTO dominios.especie_trecho_energia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.especie_trecho_energia (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.especie_trecho_energia (code,code_name) VALUES (2,'Transmissão (2)')# +INSERT INTO dominios.especie_trecho_energia (code,code_name) VALUES (3,'Distribuição (3)')# +INSERT INTO dominios.especie_trecho_energia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.especie_trecho_energia OWNER TO postgres; +ALTER TABLE dominios.especie_trecho_energia OWNER TO postgres# CREATE TABLE dominios.tipo_edif_rod ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_edif_rod_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (8,'Terminal interestadual (8)'); -INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (9,'Terminal urbano (9)'); -INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (10,'Parada interestadual (10)'); -INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (13,'Posto de pedágio (13)'); -INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (15,'Administração (15)'); -INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (20,'Garagem (20)'); -INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (8,'Terminal interestadual (8)')# +INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (9,'Terminal urbano (9)')# +INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (10,'Parada interestadual (10)')# +INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (13,'Posto de pedágio (13)')# +INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (15,'Administração (15)')# +INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (20,'Garagem (20)')# +INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_edif_rod (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_edif_rod OWNER TO postgres; +ALTER TABLE dominios.tipo_edif_rod OWNER TO postgres# CREATE TABLE dominios.tipo_area ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_area_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_area (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (1,'Área de propriedade particular (1)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (2,'Área habitacional (2)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (3,'Área relacionada a dutos (3)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (4,'Área relacionada a edificação agropecuária ou extrativismo vegetal ou pesca (4)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (5,'Área relacionada a edificação de comércio ou serviços (5)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (6,'Área relacionada a edificação de ensino (6)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (7,'Área relacionada a edificação de saúde (7)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (8,'Área relacionada a edificação industrial (8)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (9,'Área relacionada a edificação religiosa (9)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (10,'Área relacionada a energia elétrica (10)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (11,'Área relacionada a equipamentos de desenvolvimento social (11)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (12,'Área relacionada a estação de medição de fenômenos (12)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (13,'Área relacionada ao extrativismo mineral (13)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (14,'Área relacionada a instalação de abastecimento de água (14)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (15,'Área relacionada a instalação de comunicações (15)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (16,'Área relacionada a instalação de estrutura de transporte (16)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (17,'Área relacionada a instalação de saneamento (17)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (18,'Área relacionada ao lazer (18)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (19,'Área relacionada a ruínas de valor histórico (19)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_area (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_area OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_area (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (1,'Área de propriedade particular (1)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (2,'Área habitacional (2)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (3,'Área relacionada a dutos (3)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (4,'Área relacionada a edificação agropecuária ou extrativismo vegetal ou pesca (4)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (5,'Área relacionada a edificação de comércio ou serviços (5)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (6,'Área relacionada a edificação de ensino (6)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (7,'Área relacionada a edificação de saúde (7)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (8,'Área relacionada a edificação industrial (8)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (9,'Área relacionada a edificação religiosa (9)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (10,'Área relacionada a energia elétrica (10)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (11,'Área relacionada a equipamentos de desenvolvimento social (11)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (12,'Área relacionada a estação de medição de fenômenos (12)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (13,'Área relacionada ao extrativismo mineral (13)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (14,'Área relacionada a instalação de abastecimento de água (14)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (15,'Área relacionada a instalação de comunicações (15)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (16,'Área relacionada a instalação de estrutura de transporte (16)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (17,'Área relacionada a instalação de saneamento (17)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (18,'Área relacionada ao lazer (18)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (19,'Área relacionada a ruínas de valor histórico (19)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_area (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_area OWNER TO postgres# CREATE TABLE dominios.tipo_alter_antrop ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_alter_antrop_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (24,'Caixa de empréstimo (24)'); -INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (26,'Corte (26)'); -INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (27,'Aterro (27)'); -INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (28,'Resíduo de bota-fora (28)'); -INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (29,'Resíduo sólido em geral (29)'); -INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (30,'Canal (30)'); -INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (31,'Vala (31)'); -INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (32,'Área de extração mineral (32)'); -INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_alter_antrop OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (24,'Caixa de empréstimo (24)')# +INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (26,'Corte (26)')# +INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (27,'Aterro (27)')# +INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (28,'Resíduo de bota-fora (28)')# +INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (29,'Resíduo sólido em geral (29)')# +INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (30,'Canal (30)')# +INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (31,'Vala (31)')# +INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (32,'Área de extração mineral (32)')# +INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_alter_antrop (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_alter_antrop OWNER TO postgres# CREATE TABLE dominios.tipo_edif_comunic ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_edif_comunic_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (1,'Centro de operações (1)'); -INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (2,'Central comutação e transmissão (2)'); -INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (3,'Estação rádio base (3)'); -INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (4,'Estação repetidora (4)'); -INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (5,'Administração (5)'); -INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (1,'Centro de operações (1)')# +INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (2,'Central comutação e transmissão (2)')# +INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (3,'Estação rádio base (3)')# +INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (4,'Estação repetidora (4)')# +INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (5,'Administração (5)')# +INSERT INTO dominios.tipo_edif_comunic (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_edif_comunic OWNER TO postgres; +ALTER TABLE dominios.tipo_edif_comunic OWNER TO postgres# CREATE TABLE dominios.tipo_tunel ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_tunel_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_tunel (code,code_name) VALUES (1,'Túnel (1)'); -INSERT INTO dominios.tipo_tunel (code,code_name) VALUES (2,'Passagem subterrânea (2)'); -INSERT INTO dominios.tipo_tunel (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_tunel (code,code_name) VALUES (1,'Túnel (1)')# +INSERT INTO dominios.tipo_tunel (code,code_name) VALUES (2,'Passagem subterrânea (2)')# +INSERT INTO dominios.tipo_tunel (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_tunel OWNER TO postgres; +ALTER TABLE dominios.tipo_tunel OWNER TO postgres# CREATE TABLE dominios.nr_linhas ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT nr_linhas_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.nr_linhas (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.nr_linhas (code,code_name) VALUES (1,'Simples (1)'); -INSERT INTO dominios.nr_linhas (code,code_name) VALUES (2,'Dupla (2)'); -INSERT INTO dominios.nr_linhas (code,code_name) VALUES (3,'Múltipla (3)'); -INSERT INTO dominios.nr_linhas (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (1,'Simples (1)')# +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (2,'Dupla (2)')# +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (3,'Múltipla (3)')# +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.nr_linhas OWNER TO postgres; +ALTER TABLE dominios.nr_linhas OWNER TO postgres# CREATE TABLE dominios.tipo_pto_ref_geod_topo ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_pto_ref_geod_topo_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (1,'Vértice de triangulação - VT (1)'); -INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (2,'Referência de nível - RN (2)'); -INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (3,'Estação gravimétrica - EG (3)'); -INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (4,'Estação de poligonal - EP (4)'); -INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (5,'Ponto astronômico - PA (5)'); -INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (6,'Ponto barométrico - B (6)'); -INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (7,'Ponto trigonométrico - RV (7)'); -INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (8,'Ponto de satélite - SAT (8)'); -INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_pto_ref_geod_topo OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (1,'Vértice de triangulação - VT (1)')# +INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (2,'Referência de nível - RN (2)')# +INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (3,'Estação gravimétrica - EG (3)')# +INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (4,'Estação de poligonal - EP (4)')# +INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (5,'Ponto astronômico - PA (5)')# +INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (6,'Ponto barométrico - B (6)')# +INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (7,'Ponto trigonométrico - RV (7)')# +INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (8,'Ponto de satélite - SAT (8)')# +INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_pto_ref_geod_topo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_pto_ref_geod_topo OWNER TO postgres# CREATE TABLE dominios.tipo_trecho_ferrov ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_trecho_ferrov_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_trecho_ferrov (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_trecho_ferrov (code,code_name) VALUES (5,'Trecho para bonde (5)'); -INSERT INTO dominios.tipo_trecho_ferrov (code,code_name) VALUES (6,'Trecho para aeromóvel (6)'); -INSERT INTO dominios.tipo_trecho_ferrov (code,code_name) VALUES (7,'Trecho para trem (7)'); -INSERT INTO dominios.tipo_trecho_ferrov (code,code_name) VALUES (8,'Trecho para metrô (8)'); -INSERT INTO dominios.tipo_trecho_ferrov (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_trecho_ferrov (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_trecho_ferrov (code,code_name) VALUES (5,'Trecho para bonde (5)')# +INSERT INTO dominios.tipo_trecho_ferrov (code,code_name) VALUES (6,'Trecho para aeromóvel (6)')# +INSERT INTO dominios.tipo_trecho_ferrov (code,code_name) VALUES (7,'Trecho para trem (7)')# +INSERT INTO dominios.tipo_trecho_ferrov (code,code_name) VALUES (8,'Trecho para metrô (8)')# +INSERT INTO dominios.tipo_trecho_ferrov (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_trecho_ferrov OWNER TO postgres; +ALTER TABLE dominios.tipo_trecho_ferrov OWNER TO postgres# CREATE TABLE dominios.material_predominante ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT material_predominante_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.material_predominante (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (4,'Rocha (4)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (12,'Areia (12)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (13,'Areia fina (13)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (14,'Lama (14)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (15,'Argila (15)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (16,'Lodo (16)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (18,'Cascalho (18)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (19,'Seixo (19)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (20,'Coral (20)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (21,'Concha (21)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (22,'Ervas marinhas (22)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (50,'Pedra (50)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (97,'Não aplicável (97)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (98,'Misto (98)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.material_predominante (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.material_predominante OWNER TO postgres; +)# + +INSERT INTO dominios.material_predominante (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (4,'Rocha (4)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (12,'Areia (12)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (13,'Areia fina (13)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (14,'Lama (14)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (15,'Argila (15)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (16,'Lodo (16)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (18,'Cascalho (18)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (19,'Seixo (19)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (20,'Coral (20)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (21,'Concha (21)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (22,'Ervas marinhas (22)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (50,'Pedra (50)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (98,'Misto (98)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.material_predominante (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.material_predominante OWNER TO postgres# CREATE TABLE dominios.tipo_rep_diplomatica ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_rep_diplomatica_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_rep_diplomatica (code,code_name) VALUES (2,'Embaixada (2)'); -INSERT INTO dominios.tipo_rep_diplomatica (code,code_name) VALUES (3,'Consulado (3)'); -INSERT INTO dominios.tipo_rep_diplomatica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_rep_diplomatica (code,code_name) VALUES (2,'Embaixada (2)')# +INSERT INTO dominios.tipo_rep_diplomatica (code,code_name) VALUES (3,'Consulado (3)')# +INSERT INTO dominios.tipo_rep_diplomatica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_rep_diplomatica OWNER TO postgres; +ALTER TABLE dominios.tipo_rep_diplomatica OWNER TO postgres# CREATE TABLE dominios.tipo_embarcacao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_embarcacao_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (2,'Balsa (2)'); -INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (3,'Lancha (3)'); -INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (6,'Empurrador-balsa (6)'); -INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (7,'Embarcação de pequeno porte (7)'); -INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (97,'Não aplicável (97)'); -INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (2,'Balsa (2)')# +INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (3,'Lancha (3)')# +INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (6,'Empurrador-balsa (6)')# +INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (7,'Embarcação de pequeno porte (7)')# +INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.tipo_embarcacao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_embarcacao OWNER TO postgres; +ALTER TABLE dominios.tipo_embarcacao OWNER TO postgres# CREATE TABLE dominios.tipo_terreno_exposto ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_terreno_exposto_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (4,'Pedregoso (4)'); -INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (12,'Areia (12)'); -INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (18,'Cascalho (18)'); -INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (23,'Terra (23)'); -INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (24,'Saibro (24)'); -INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (4,'Pedregoso (4)')# +INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (12,'Areia (12)')# +INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (18,'Cascalho (18)')# +INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (23,'Terra (23)')# +INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (24,'Saibro (24)')# +INSERT INTO dominios.tipo_terreno_exposto (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_terreno_exposto OWNER TO postgres; +ALTER TABLE dominios.tipo_terreno_exposto OWNER TO postgres# CREATE TABLE dominios.tipo_delim_fis ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_delim_fis_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_delim_fis (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_delim_fis (code,code_name) VALUES (1,'Cerca (1)'); -INSERT INTO dominios.tipo_delim_fis (code,code_name) VALUES (2,'Muro (2)'); -INSERT INTO dominios.tipo_delim_fis (code,code_name) VALUES (3,'Mureta (3)'); -INSERT INTO dominios.tipo_delim_fis (code,code_name) VALUES (4,'Gradil (4)'); -INSERT INTO dominios.tipo_delim_fis (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_delim_fis (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_delim_fis (code,code_name) VALUES (1,'Cerca (1)')# +INSERT INTO dominios.tipo_delim_fis (code,code_name) VALUES (2,'Muro (2)')# +INSERT INTO dominios.tipo_delim_fis (code,code_name) VALUES (3,'Mureta (3)')# +INSERT INTO dominios.tipo_delim_fis (code,code_name) VALUES (4,'Gradil (4)')# +INSERT INTO dominios.tipo_delim_fis (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_delim_fis OWNER TO postgres; +ALTER TABLE dominios.tipo_delim_fis OWNER TO postgres# CREATE TABLE dominios.tipo_banco ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_banco_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_banco (code,code_name) VALUES (1,'Fluvial (1)'); -INSERT INTO dominios.tipo_banco (code,code_name) VALUES (2,'Marítimo (2)'); -INSERT INTO dominios.tipo_banco (code,code_name) VALUES (3,'Lacustre (3)'); -INSERT INTO dominios.tipo_banco (code,code_name) VALUES (4,'Cordão arenoso (4)'); -INSERT INTO dominios.tipo_banco (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_banco (code,code_name) VALUES (1,'Fluvial (1)')# +INSERT INTO dominios.tipo_banco (code,code_name) VALUES (2,'Marítimo (2)')# +INSERT INTO dominios.tipo_banco (code,code_name) VALUES (3,'Lacustre (3)')# +INSERT INTO dominios.tipo_banco (code,code_name) VALUES (4,'Cordão arenoso (4)')# +INSERT INTO dominios.tipo_banco (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_banco OWNER TO postgres; +ALTER TABLE dominios.tipo_banco OWNER TO postgres# CREATE TABLE dominios.local_equip_desenv_social ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT local_equip_desenv_social_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (1,'Terras Indígena (1)'); -INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (2,'Terras de População Ribeirinha (2)'); -INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (3,'Terras Quilombola (3)'); -INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (4,'Rural (4)'); -INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (5,'Urbano central (5)'); -INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (6,'Urbana periférica (6)'); -INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (7,'Outras Comunidades tradicionais (7)'); -INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (1,'Terras Indígena (1)')# +INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (2,'Terras de População Ribeirinha (2)')# +INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (3,'Terras Quilombola (3)')# +INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (4,'Rural (4)')# +INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (5,'Urbano central (5)')# +INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (6,'Urbana periférica (6)')# +INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (7,'Outras Comunidades tradicionais (7)')# +INSERT INTO dominios.local_equip_desenv_social (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.local_equip_desenv_social OWNER TO postgres; +ALTER TABLE dominios.local_equip_desenv_social OWNER TO postgres# CREATE TABLE dominios.tipo_ref ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_ref_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_ref (code,code_name) VALUES (1,'Altimétrico (1)'); -INSERT INTO dominios.tipo_ref (code,code_name) VALUES (2,'Planimétrico (2)'); -INSERT INTO dominios.tipo_ref (code,code_name) VALUES (3,'Planialtimétrico (3)'); -INSERT INTO dominios.tipo_ref (code,code_name) VALUES (4,'Gravimétrico (4)'); -INSERT INTO dominios.tipo_ref (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (1,'Altimétrico (1)')# +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (2,'Planimétrico (2)')# +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (3,'Planialtimétrico (3)')# +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (4,'Gravimétrico (4)')# +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_ref OWNER TO postgres; +ALTER TABLE dominios.tipo_ref OWNER TO postgres# CREATE TABLE dominios.tipo_pista ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_pista_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_pista (code,code_name) VALUES (9,'Pista de pouso (9)'); -INSERT INTO dominios.tipo_pista (code,code_name) VALUES (10,'Pista de taxiamento (10)'); -INSERT INTO dominios.tipo_pista (code,code_name) VALUES (11,'Heliponto (11)'); -INSERT INTO dominios.tipo_pista (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_pista (code,code_name) VALUES (9,'Pista de pouso (9)')# +INSERT INTO dominios.tipo_pista (code,code_name) VALUES (10,'Pista de taxiamento (10)')# +INSERT INTO dominios.tipo_pista (code,code_name) VALUES (11,'Heliponto (11)')# +INSERT INTO dominios.tipo_pista (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_pista OWNER TO postgres; +ALTER TABLE dominios.tipo_pista OWNER TO postgres# CREATE TABLE dominios.destinacao_cemiterio ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT destinacao_cemiterio_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.destinacao_cemiterio (code,code_name) VALUES (2,'Humanos (2)'); -INSERT INTO dominios.destinacao_cemiterio (code,code_name) VALUES (3,'Animais (3)'); -INSERT INTO dominios.destinacao_cemiterio (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.destinacao_cemiterio (code,code_name) VALUES (2,'Humanos (2)')# +INSERT INTO dominios.destinacao_cemiterio (code,code_name) VALUES (3,'Animais (3)')# +INSERT INTO dominios.destinacao_cemiterio (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.destinacao_cemiterio OWNER TO postgres; +ALTER TABLE dominios.destinacao_cemiterio OWNER TO postgres# CREATE TABLE dominios.tipo_fonte_dagua ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_fonte_dagua_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_fonte_dagua (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_fonte_dagua (code,code_name) VALUES (1,'Poço (1)'); -INSERT INTO dominios.tipo_fonte_dagua (code,code_name) VALUES (2,'Poço artesiano (2)'); -INSERT INTO dominios.tipo_fonte_dagua (code,code_name) VALUES (3,'Olho d''água (3)'); -INSERT INTO dominios.tipo_fonte_dagua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_fonte_dagua (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_fonte_dagua (code,code_name) VALUES (1,'Poço (1)')# +INSERT INTO dominios.tipo_fonte_dagua (code,code_name) VALUES (2,'Poço artesiano (2)')# +INSERT INTO dominios.tipo_fonte_dagua (code,code_name) VALUES (3,'Olho d''água (3)')# +INSERT INTO dominios.tipo_fonte_dagua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_fonte_dagua OWNER TO postgres; +ALTER TABLE dominios.tipo_fonte_dagua OWNER TO postgres# CREATE TABLE dominios.tipo_edif_aero ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_edif_aero_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (15,'Administração (15)'); -INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (26,'Terminal de passageiros (26)'); -INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (27,'Terminal de cargas (27)'); -INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (28,'Torre de controle (28)'); -INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (29,'Hangar (29)'); -INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (30,'Serviço de combate a incêndios (SCI) (30)'); -INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (15,'Administração (15)')# +INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (26,'Terminal de passageiros (26)')# +INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (27,'Terminal de cargas (27)')# +INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (28,'Torre de controle (28)')# +INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (29,'Hangar (29)')# +INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (30,'Serviço de combate a incêndios (SCI) (30)')# +INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_edif_aero (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_edif_aero OWNER TO postgres; +ALTER TABLE dominios.tipo_edif_aero OWNER TO postgres# CREATE TABLE dominios.tipo_entroncamento ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_entroncamento_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (1,'Cruzamento ou injunções simples (1)'); -INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (2,'Círculo (2)'); -INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (3,'Trevo (3)'); -INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (4,'Rótula (4)'); -INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (5,'Entroncamento ferroviário (5)'); -INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (99,'Outros tipos de entroncamento em nível (99)'); -INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (1,'Cruzamento ou injunções simples (1)')# +INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (2,'Círculo (2)')# +INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (3,'Trevo (3)')# +INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (4,'Rótula (4)')# +INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (5,'Entroncamento ferroviário (5)')# +INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (99,'Outros tipos de entroncamento em nível (99)')# +INSERT INTO dominios.tipo_entroncamento (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_entroncamento OWNER TO postgres; +ALTER TABLE dominios.tipo_entroncamento OWNER TO postgres# CREATE TABLE dominios.tipo_est_gerad ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_est_gerad_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (5,'Eólica (5)'); -INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (6,'Solar (6)'); -INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (7,'Maré-motriz (7)'); -INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (8,'Hidrelétrica (8)'); -INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (9,'Termelétrica (9)'); -INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (5,'Eólica (5)')# +INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (6,'Solar (6)')# +INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (7,'Maré-motriz (7)')# +INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (8,'Hidrelétrica (8)')# +INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (9,'Termelétrica (9)')# +INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_est_gerad (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_est_gerad OWNER TO postgres; +ALTER TABLE dominios.tipo_est_gerad OWNER TO postgres# CREATE TABLE dominios.situacao_juridica ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT situacao_juridica_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.situacao_juridica (code,code_name) VALUES (1,'Delimitada (1)'); -INSERT INTO dominios.situacao_juridica (code,code_name) VALUES (2,'Declarada (2)'); -INSERT INTO dominios.situacao_juridica (code,code_name) VALUES (3,'Homologada ou demarcada (3)'); -INSERT INTO dominios.situacao_juridica (code,code_name) VALUES (4,'Regularizada (4)'); -INSERT INTO dominios.situacao_juridica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.situacao_juridica (code,code_name) VALUES (1,'Delimitada (1)')# +INSERT INTO dominios.situacao_juridica (code,code_name) VALUES (2,'Declarada (2)')# +INSERT INTO dominios.situacao_juridica (code,code_name) VALUES (3,'Homologada ou demarcada (3)')# +INSERT INTO dominios.situacao_juridica (code,code_name) VALUES (4,'Regularizada (4)')# +INSERT INTO dominios.situacao_juridica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.situacao_juridica OWNER TO postgres; +ALTER TABLE dominios.situacao_juridica OWNER TO postgres# CREATE TABLE dominios.tipo_edif_relig ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_edif_relig_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (1,'Igreja (1)'); -INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (2,'Templo (2)'); -INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (3,'Centro (3)'); -INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (4,'Mosteiro (4)'); -INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (5,'Convento (5)'); -INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (6,'Mesquita (6)'); -INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (7,'Sinagoga (7)'); -INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (8,'Terreiro (8)'); -INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (9,'Capela mortuária (9)'); -INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (10,'Administração (10)'); -INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_edif_relig OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (1,'Igreja (1)')# +INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (2,'Templo (2)')# +INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (3,'Centro (3)')# +INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (4,'Mosteiro (4)')# +INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (5,'Convento (5)')# +INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (6,'Mesquita (6)')# +INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (7,'Sinagoga (7)')# +INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (8,'Terreiro (8)')# +INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (9,'Capela mortuária (9)')# +INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (10,'Administração (10)')# +INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_edif_relig (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_edif_relig OWNER TO postgres# CREATE TABLE dominios.denominacao_associada ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT denominacao_associada_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (5,'Cristã (5)'); -INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (6,'Israelita (6)'); -INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (7,'Muçulmana (7)'); -INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (97,'Não aplicável (97)'); -INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (99,'Outras (99)'); -INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (5,'Cristã (5)')# +INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (6,'Israelita (6)')# +INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (7,'Muçulmana (7)')# +INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (99,'Outras (99)')# +INSERT INTO dominios.denominacao_associada (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.denominacao_associada OWNER TO postgres; +ALTER TABLE dominios.denominacao_associada OWNER TO postgres# CREATE TABLE dominios.tipo_lavoura ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_lavoura_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_lavoura (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_lavoura (code,code_name) VALUES (1,'Perene (1)'); -INSERT INTO dominios.tipo_lavoura (code,code_name) VALUES (2,'Semi-perene (2)'); -INSERT INTO dominios.tipo_lavoura (code,code_name) VALUES (3,'Anual (3)'); -INSERT INTO dominios.tipo_lavoura (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_lavoura (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_lavoura (code,code_name) VALUES (1,'Perene (1)')# +INSERT INTO dominios.tipo_lavoura (code,code_name) VALUES (2,'Semi-perene (2)')# +INSERT INTO dominios.tipo_lavoura (code,code_name) VALUES (3,'Anual (3)')# +INSERT INTO dominios.tipo_lavoura (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_lavoura OWNER TO postgres; +ALTER TABLE dominios.tipo_lavoura OWNER TO postgres# CREATE TABLE dominios.tipo_ilha ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_ilha_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (1,'Fluvial (1)'); -INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (2,'Marítima (2)'); -INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (3,'Lacustre (3)'); -INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (1,'Fluvial (1)')# +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (2,'Marítima (2)')# +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (3,'Lacustre (3)')# +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_ilha OWNER TO postgres; +ALTER TABLE dominios.tipo_ilha OWNER TO postgres# CREATE TABLE dominios.tipo_campo_quadra ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_campo_quadra_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (1,'Futebol (1)'); -INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (2,'Basquetebol (2)'); -INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (3,'Voleibol (3)'); -INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (4,'Pólo (4)'); -INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (5,'Hipismo (5)'); -INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (6,'Poliesportiva (6)'); -INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (7,'Tênis (7)'); -INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (1,'Futebol (1)')# +INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (2,'Basquetebol (2)')# +INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (3,'Voleibol (3)')# +INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (4,'Pólo (4)')# +INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (5,'Hipismo (5)')# +INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (6,'Poliesportiva (6)')# +INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (7,'Tênis (7)')# +INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_campo_quadra (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_campo_quadra OWNER TO postgres; +ALTER TABLE dominios.tipo_campo_quadra OWNER TO postgres# CREATE TABLE dominios.tipo_ponte ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_ponte_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_ponte (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_ponte (code,code_name) VALUES (1,'Móvel (1)'); -INSERT INTO dominios.tipo_ponte (code,code_name) VALUES (2,'Pênsil (2)'); -INSERT INTO dominios.tipo_ponte (code,code_name) VALUES (3,'Fixa (3)'); -INSERT INTO dominios.tipo_ponte (code,code_name) VALUES (7,'Estaiada (7)'); -INSERT INTO dominios.tipo_ponte (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_ponte (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_ponte (code,code_name) VALUES (1,'Móvel (1)')# +INSERT INTO dominios.tipo_ponte (code,code_name) VALUES (2,'Pênsil (2)')# +INSERT INTO dominios.tipo_ponte (code,code_name) VALUES (3,'Fixa (3)')# +INSERT INTO dominios.tipo_ponte (code,code_name) VALUES (7,'Estaiada (7)')# +INSERT INTO dominios.tipo_ponte (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_ponte OWNER TO postgres; +ALTER TABLE dominios.tipo_ponte OWNER TO postgres# CREATE TABLE dominios.tipo_edif_lazer ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_edif_lazer_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (1,'Estádio (1)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (2,'Ginásio (2)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (3,'Museu (3)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (4,'Teatro (4)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (5,'Anfiteatro (5)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (6,'Espaço de exibição de filmes (6)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (7,'Centro cultural (7)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (8,'Plataforma de pesca (8)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (9,'Arquivo (9)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (10,'Biblioteca (10)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (11,'Centro de documentação (11)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (12,'Circo (12)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (13,'Concha acústica (13)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (14,'Conservatório (14)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (15,'Coreto ou tribuna (15)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (17,'Equipamentos culturais diversos (17)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (18,'Espaço de eventos e/ou cultural (18)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (19,'Galeria (19)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (21,'Quiosque (21)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (22,'Administração (22)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_edif_lazer OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (1,'Estádio (1)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (2,'Ginásio (2)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (3,'Museu (3)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (4,'Teatro (4)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (5,'Anfiteatro (5)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (6,'Espaço de exibição de filmes (6)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (7,'Centro cultural (7)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (8,'Plataforma de pesca (8)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (9,'Arquivo (9)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (10,'Biblioteca (10)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (11,'Centro de documentação (11)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (12,'Circo (12)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (13,'Concha acústica (13)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (14,'Conservatório (14)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (15,'Coreto ou tribuna (15)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (17,'Equipamentos culturais diversos (17)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (18,'Espaço de eventos e/ou cultural (18)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (19,'Galeria (19)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (21,'Quiosque (21)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (22,'Administração (22)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_edif_lazer (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_edif_lazer OWNER TO postgres# CREATE TABLE dominios.finalidade_galeria_bueiro ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT finalidade_galeria_bueiro_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (1,'Abastecimento animal (1)'); -INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (2,'Abastecimento humano (2)'); -INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (3,'Abastecimento industrial (3)'); -INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (4,'Canalização de águas pluviais (4)'); -INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (5,'Canalização de curso d''água (5)'); -INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (6,'Canalização de efluentes domésticos (6)'); -INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (7,'Canalização de efluentes industriais (7)'); -INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (8,'Irrigação (8)'); -INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (1,'Abastecimento animal (1)')# +INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (2,'Abastecimento humano (2)')# +INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (3,'Abastecimento industrial (3)')# +INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (4,'Canalização de águas pluviais (4)')# +INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (5,'Canalização de curso d''água (5)')# +INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (6,'Canalização de efluentes domésticos (6)')# +INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (7,'Canalização de efluentes industriais (7)')# +INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (8,'Irrigação (8)')# +INSERT INTO dominios.finalidade_galeria_bueiro (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.finalidade_galeria_bueiro OWNER TO postgres; +ALTER TABLE dominios.finalidade_galeria_bueiro OWNER TO postgres# CREATE TABLE dominios.causa_exposicao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT causa_exposicao_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.causa_exposicao (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.causa_exposicao (code,code_name) VALUES (4,'Natural (4)'); -INSERT INTO dominios.causa_exposicao (code,code_name) VALUES (5,'Artificial (5)'); -INSERT INTO dominios.causa_exposicao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.causa_exposicao (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.causa_exposicao (code,code_name) VALUES (4,'Natural (4)')# +INSERT INTO dominios.causa_exposicao (code,code_name) VALUES (5,'Artificial (5)')# +INSERT INTO dominios.causa_exposicao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.causa_exposicao OWNER TO postgres; +ALTER TABLE dominios.causa_exposicao OWNER TO postgres# CREATE TABLE dominios.qualid_agua ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT qualid_agua_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.qualid_agua (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.qualid_agua (code,code_name) VALUES (1,'Potável (1)'); -INSERT INTO dominios.qualid_agua (code,code_name) VALUES (2,'Não potável (2)'); -INSERT INTO dominios.qualid_agua (code,code_name) VALUES (3,'Mineral (3)'); -INSERT INTO dominios.qualid_agua (code,code_name) VALUES (4,'Salobra (4)'); -INSERT INTO dominios.qualid_agua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.qualid_agua (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.qualid_agua (code,code_name) VALUES (1,'Potável (1)')# +INSERT INTO dominios.qualid_agua (code,code_name) VALUES (2,'Não potável (2)')# +INSERT INTO dominios.qualid_agua (code,code_name) VALUES (3,'Mineral (3)')# +INSERT INTO dominios.qualid_agua (code,code_name) VALUES (4,'Salobra (4)')# +INSERT INTO dominios.qualid_agua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.qualid_agua OWNER TO postgres; +ALTER TABLE dominios.qualid_agua OWNER TO postgres# CREATE TABLE dominios.tipo_exposicao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_exposicao_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (3,'Fechado (3)'); -INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (4,'Coberto (4)'); -INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (5,'Céu aberto (5)'); -INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (3,'Fechado (3)')# +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (4,'Coberto (4)')# +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (5,'Céu aberto (5)')# +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_exposicao OWNER TO postgres; +ALTER TABLE dominios.tipo_exposicao OWNER TO postgres# CREATE TABLE dominios.especie ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT especie_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.especie (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.especie (code,code_name) VALUES (10,'Cipó (10)'); -INSERT INTO dominios.especie (code,code_name) VALUES (11,'Bambu (11)'); -INSERT INTO dominios.especie (code,code_name) VALUES (17,'Palmeira (17)'); -INSERT INTO dominios.especie (code,code_name) VALUES (27,'Araucária (27)'); -INSERT INTO dominios.especie (code,code_name) VALUES (37,'Sem predominância (37)'); -INSERT INTO dominios.especie (code,code_name) VALUES (96,'Não identificado (96)'); -INSERT INTO dominios.especie (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.especie (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.especie (code,code_name) VALUES (10,'Cipó (10)')# +INSERT INTO dominios.especie (code,code_name) VALUES (11,'Bambu (11)')# +INSERT INTO dominios.especie (code,code_name) VALUES (17,'Palmeira (17)')# +INSERT INTO dominios.especie (code,code_name) VALUES (27,'Araucária (27)')# +INSERT INTO dominios.especie (code,code_name) VALUES (37,'Sem predominância (37)')# +INSERT INTO dominios.especie (code,code_name) VALUES (96,'Não identificado (96)')# +INSERT INTO dominios.especie (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.especie OWNER TO postgres; +ALTER TABLE dominios.especie OWNER TO postgres# CREATE TABLE dominios.tipo_equip_desenv_social ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_equip_desenv_social_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (1,'Banco de alimentos (1)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (2,'Barragem calçadão (2)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (3,'Bolsa verde (3)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (4,'Centro de convivência (4)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (5,'Centro POP (5)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (6,'Centro-dia (6)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (7,'Cisterna subterrânea (7)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (8,'Cisterna de polietileno (8)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (9,'Cisterna de placa (9)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (10,'Cozinha comunitária (10)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (11,'CRAS (11)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (12,'CREAS (12)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (13,'PAA (13)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (14,'PRONAF (14)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (15,'PRONATEC (15)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (16,'Restaurante popular (16)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (17,'Unidade de acolhimento para crianças e adolescentes (17)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (18,'Unidade de acolhimento para crianças e adolescentes (casa de passagem) (18)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (19,'Unidade de acolhimento para idosos (19)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (20,'Unidade de acolhimento para mulheres vítimas de violência (20)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (21,'Unidade de acolhimento para pessoas em situação de rua (21)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_equip_desenv_social OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (1,'Banco de alimentos (1)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (2,'Barragem calçadão (2)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (3,'Bolsa verde (3)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (4,'Centro de convivência (4)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (5,'Centro POP (5)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (6,'Centro-dia (6)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (7,'Cisterna subterrânea (7)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (8,'Cisterna de polietileno (8)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (9,'Cisterna de placa (9)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (10,'Cozinha comunitária (10)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (11,'CRAS (11)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (12,'CREAS (12)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (13,'PAA (13)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (14,'PRONAF (14)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (15,'PRONATEC (15)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (16,'Restaurante popular (16)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (17,'Unidade de acolhimento para crianças e adolescentes (17)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (18,'Unidade de acolhimento para crianças e adolescentes (casa de passagem) (18)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (19,'Unidade de acolhimento para idosos (19)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (20,'Unidade de acolhimento para mulheres vítimas de violência (20)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (21,'Unidade de acolhimento para pessoas em situação de rua (21)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_equip_desenv_social (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_equip_desenv_social OWNER TO postgres# CREATE TABLE dominios.situacao_marco ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT situacao_marco_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (1,'Bom (1)'); -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (2,'Destruído (2)'); -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (3,'Destruído sem chapa (3)'); -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (4,'Destruído com chapa danificada (4)'); -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (5,'Não encontrado (5)'); -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (6,'Não visitado (6)'); -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (7,'Não construído (7)'); -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (1,'Bom (1)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (2,'Destruído (2)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (3,'Destruído sem chapa (3)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (4,'Destruído com chapa danificada (4)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (5,'Não encontrado (5)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (6,'Não visitado (6)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (7,'Não construído (7)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.situacao_marco OWNER TO postgres; +ALTER TABLE dominios.situacao_marco OWNER TO postgres# CREATE TABLE dominios.tipo_caminho_aereo ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_caminho_aereo_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_caminho_aereo (code,code_name) VALUES (12,'Teleférico (12)'); -INSERT INTO dominios.tipo_caminho_aereo (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_caminho_aereo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_caminho_aereo (code,code_name) VALUES (12,'Teleférico (12)')# +INSERT INTO dominios.tipo_caminho_aereo (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_caminho_aereo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_caminho_aereo OWNER TO postgres; +ALTER TABLE dominios.tipo_caminho_aereo OWNER TO postgres# CREATE TABLE dominios.tipo_obst ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_obst_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_obst (code,code_name) VALUES (4,'Natural (4)'); -INSERT INTO dominios.tipo_obst (code,code_name) VALUES (5,'Artificial (5)'); -INSERT INTO dominios.tipo_obst (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_obst (code,code_name) VALUES (4,'Natural (4)')# +INSERT INTO dominios.tipo_obst (code,code_name) VALUES (5,'Artificial (5)')# +INSERT INTO dominios.tipo_obst (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_obst OWNER TO postgres; +ALTER TABLE dominios.tipo_obst OWNER TO postgres# CREATE TABLE dominios.tipo_produto_residuo ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_produto_residuo_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (3,'Petróleo (3)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (5,'Gás (5)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (6,'Grãos (6)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (16,'Vinhoto (16)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (17,'Estrume (17)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (18,'Cascalho (18)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (20,'Inseticida (20)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (21,'Folhagens (21)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (22,'Pedra (brita) (22)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (23,'Granito (23)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (24,'Mármore (24)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (25,'Bauxita (25)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (26,'Manganês (26)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (27,'Talco (27)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (28,'Óleo diesel (28)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (29,'Gasolina (29)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (30,'Álcool (30)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (31,'Querosene (31)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (32,'Cobre (32)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (33,'Carvão mineral (33)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (34,'Sal (34)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (35,'Ferro (35)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (36,'Escória (36)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (37,'Ouro (37)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (38,'Diamante (38)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (39,'Prata (39)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (40,'Pedra preciosa (40)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (41,'Forragem (41)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (42,'Areia (42)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (43,'Saibro/piçarra (43)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (45,'Ágata (45)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (46,'Água (46)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (47,'Água marinha (47)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (48,'Água mineral (48)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (49,'Alexandrita (49)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (50,'Ametista (50)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (51,'Amianto (51)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (52,'Argila (52)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (53,'Barita (53)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (54,'Bentonita (54)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (55,'Calcário (55)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (56,'Carvão vegetal (56)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (57,'Caulim (57)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (58,'Chorume (58)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (59,'Chumbo (59)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (60,'Citrino (60)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (61,'Crisoberilo (61)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (62,'Cristal de rocha (62)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (63,'Cromo (63)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (64,'Diatomita (64)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (65,'Dolomito (65)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (66,'Esgoto (66)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (67,'Esmeralda (67)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (68,'Estanho (68)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (69,'Feldspato (69)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (70,'Fosfato (70)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (71,'Gipsita (71)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (72,'Grafita (72)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (73,'Granada (73)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (74,'Lítio (74)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (75,'Lixo domiciliar e comercial (75)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (76,'Lixo séptico (76)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (77,'Lixo tóxico (77)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (78,'Magnesita (78)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (79,'Mica (79)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (80,'Nióbio (80)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (81,'Níquel (81)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (82,'Opala (82)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (83,'Rocha ornamental (83)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (84,'Sal-gema (84)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (85,'Terras raras (85)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (86,'Titânio (86)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (87,'Topázio (87)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (88,'Tório (88)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (89,'Tungstênio (89)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (90,'Turfa (90)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (91,'Turmalina (91)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (92,'Urânio (92)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (93,'Vermiculita (93)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (94,'Zinco (94)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (100,'Zircônio (100)'); -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_produto_residuo OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (3,'Petróleo (3)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (5,'Gás (5)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (6,'Grãos (6)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (16,'Vinhoto (16)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (17,'Estrume (17)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (18,'Cascalho (18)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (20,'Inseticida (20)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (21,'Folhagens (21)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (22,'Pedra (brita) (22)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (23,'Granito (23)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (24,'Mármore (24)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (25,'Bauxita (25)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (26,'Manganês (26)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (27,'Talco (27)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (28,'Óleo diesel (28)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (29,'Gasolina (29)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (30,'Álcool (30)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (31,'Querosene (31)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (32,'Cobre (32)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (33,'Carvão mineral (33)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (34,'Sal (34)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (35,'Ferro (35)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (36,'Escória (36)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (37,'Ouro (37)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (38,'Diamante (38)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (39,'Prata (39)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (40,'Pedra preciosa (40)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (41,'Forragem (41)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (42,'Areia (42)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (43,'Saibro/piçarra (43)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (45,'Ágata (45)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (46,'Água (46)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (47,'Água marinha (47)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (48,'Água mineral (48)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (49,'Alexandrita (49)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (50,'Ametista (50)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (51,'Amianto (51)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (52,'Argila (52)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (53,'Barita (53)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (54,'Bentonita (54)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (55,'Calcário (55)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (56,'Carvão vegetal (56)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (57,'Caulim (57)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (58,'Chorume (58)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (59,'Chumbo (59)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (60,'Citrino (60)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (61,'Crisoberilo (61)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (62,'Cristal de rocha (62)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (63,'Cromo (63)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (64,'Diatomita (64)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (65,'Dolomito (65)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (66,'Esgoto (66)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (67,'Esmeralda (67)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (68,'Estanho (68)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (69,'Feldspato (69)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (70,'Fosfato (70)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (71,'Gipsita (71)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (72,'Grafita (72)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (73,'Granada (73)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (74,'Lítio (74)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (75,'Lixo domiciliar e comercial (75)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (76,'Lixo séptico (76)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (77,'Lixo tóxico (77)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (78,'Magnesita (78)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (79,'Mica (79)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (80,'Nióbio (80)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (81,'Níquel (81)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (82,'Opala (82)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (83,'Rocha ornamental (83)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (84,'Sal-gema (84)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (85,'Terras raras (85)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (86,'Titânio (86)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (87,'Topázio (87)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (88,'Tório (88)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (89,'Tungstênio (89)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (90,'Turfa (90)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (91,'Turmalina (91)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (92,'Urânio (92)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (93,'Vermiculita (93)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (94,'Zinco (94)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (100,'Zircônio (100)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_produto_residuo OWNER TO postgres# CREATE TABLE dominios.tipo_massa_dagua ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_massa_dagua_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (1,'Rio (1)'); -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (3,'Oceano (3)'); -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (4,'Baía (4)'); -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (5,'Enseada (5)'); -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (6,'Meandro abandonado (6)'); -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (7,'Lago ou lagoa (7)'); -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (9,'Laguna (9)'); -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (10,'Represa/açude (10)'); -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_massa_dagua OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (1,'Rio (1)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (3,'Oceano (3)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (4,'Baía (4)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (5,'Enseada (5)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (6,'Meandro abandonado (6)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (7,'Lago ou lagoa (7)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (9,'Laguna (9)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (10,'Represa/açude (10)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_massa_dagua OWNER TO postgres# CREATE TABLE dominios.classe_ativ_econ ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT classe_ativ_econ_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (1,'Produção de energia elétrica (1)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (2,'Transmissão de energia elétrica (2)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (3,'Distribuição de energia elétrica (3)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (4,'Captação, tratamento e distribuição de água (4)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (5,'Telecomunicações (5)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (6,'Administração pública em geral (6)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (7,'Seguridade social (7)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (8,'Regulação das atividades econômicas (8)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (9,'Atividades de apoio à administração pública (9)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (10,'Relações exteriores (10)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (11,'Defesa (11)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (12,'Justiça (12)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (13,'Segurança e ordem pública (13)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (14,'Defesa civil (14)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (16,'Educação infantil - creche (16)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (17,'Educação infantil - pré-escola (17)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (18,'Ensino fundamental (18)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (19,'Ensino médio (19)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (20,'Educação superior - graduação (20)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (21,'Educação superior - graduação e pós-graduação (21)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (22,'Educação superior - pós-graduação e extensão (22)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (23,'Educação profissional de nível técnico (23)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (24,'Educação profissional de nível tecnológico (24)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (25,'Outras atividades de ensino (25)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (26,'Atendimento hospitalar (hospital) (26)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (27,'Atendimento às urgências e emergências (pronto-socorro) (27)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (28,'Atenção ambulatorial (posto e centro de saúde) (28)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (29,'Serviços de complementação diagnóstica ou terapêutica (29)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (30,'Outras atividades relacionadas com atenção à saúde (instituto de pesquisa) (30)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (31,'Serviços veterinários (31)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (32,'Serviços sociais com alojamento (32)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (33,'Serviços sociais sem alojamento (33)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (34,'Limpeza urbana e atividades relacionadas (34)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (35,'Atividades de organizações religiosas (35)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (36,'Regulação das atividades sociais e culturais (36)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (98,'Mista (98)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.classe_ativ_econ OWNER TO postgres; +)# + +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (1,'Produção de energia elétrica (1)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (2,'Transmissão de energia elétrica (2)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (3,'Distribuição de energia elétrica (3)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (4,'Captação, tratamento e distribuição de água (4)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (5,'Telecomunicações (5)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (6,'Administração pública em geral (6)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (7,'Seguridade social (7)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (8,'Regulação das atividades econômicas (8)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (9,'Atividades de apoio à administração pública (9)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (10,'Relações exteriores (10)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (11,'Defesa (11)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (12,'Justiça (12)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (13,'Segurança e ordem pública (13)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (14,'Defesa civil (14)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (16,'Educação infantil - creche (16)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (17,'Educação infantil - pré-escola (17)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (18,'Ensino fundamental (18)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (19,'Ensino médio (19)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (20,'Educação superior - graduação (20)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (21,'Educação superior - graduação e pós-graduação (21)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (22,'Educação superior - pós-graduação e extensão (22)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (23,'Educação profissional de nível técnico (23)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (24,'Educação profissional de nível tecnológico (24)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (25,'Outras atividades de ensino (25)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (26,'Atendimento hospitalar (hospital) (26)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (27,'Atendimento às urgências e emergências (pronto-socorro) (27)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (28,'Atenção ambulatorial (posto e centro de saúde) (28)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (29,'Serviços de complementação diagnóstica ou terapêutica (29)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (30,'Outras atividades relacionadas com atenção à saúde (instituto de pesquisa) (30)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (31,'Serviços veterinários (31)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (32,'Serviços sociais com alojamento (32)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (33,'Serviços sociais sem alojamento (33)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (34,'Limpeza urbana e atividades relacionadas (34)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (35,'Atividades de organizações religiosas (35)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (36,'Regulação das atividades sociais e culturais (36)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (98,'Mista (98)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.classe_ativ_econ (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.classe_ativ_econ OWNER TO postgres# CREATE TABLE dominios.situacao_agua ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT situacao_agua_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.situacao_agua (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.situacao_agua (code,code_name) VALUES (6,'Tratada (6)'); -INSERT INTO dominios.situacao_agua (code,code_name) VALUES (7,'Não tratada (7)'); -INSERT INTO dominios.situacao_agua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.situacao_agua (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.situacao_agua (code,code_name) VALUES (6,'Tratada (6)')# +INSERT INTO dominios.situacao_agua (code,code_name) VALUES (7,'Não tratada (7)')# +INSERT INTO dominios.situacao_agua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.situacao_agua OWNER TO postgres; +ALTER TABLE dominios.situacao_agua OWNER TO postgres# CREATE TABLE dominios.situacao_em_agua ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT situacao_em_agua_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.situacao_em_agua (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.situacao_em_agua (code,code_name) VALUES (4,'Emerso (4)'); -INSERT INTO dominios.situacao_em_agua (code,code_name) VALUES (5,'Submerso (5)'); -INSERT INTO dominios.situacao_em_agua (code,code_name) VALUES (7,'Cobre e descobre (7)'); -INSERT INTO dominios.situacao_em_agua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.situacao_em_agua (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.situacao_em_agua (code,code_name) VALUES (4,'Emerso (4)')# +INSERT INTO dominios.situacao_em_agua (code,code_name) VALUES (5,'Submerso (5)')# +INSERT INTO dominios.situacao_em_agua (code,code_name) VALUES (7,'Cobre e descobre (7)')# +INSERT INTO dominios.situacao_em_agua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.situacao_em_agua OWNER TO postgres; +ALTER TABLE dominios.situacao_em_agua OWNER TO postgres# CREATE TABLE dominios.auxiliar ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT auxiliar_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.auxiliar (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.auxiliar (code,code_name) VALUES (1,'Sim (1)'); -INSERT INTO dominios.auxiliar (code,code_name) VALUES (2,'Não (2)'); -INSERT INTO dominios.auxiliar (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.auxiliar (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.auxiliar (code,code_name) VALUES (1,'Sim (1)')# +INSERT INTO dominios.auxiliar (code,code_name) VALUES (2,'Não (2)')# +INSERT INTO dominios.auxiliar (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.auxiliar OWNER TO postgres; +ALTER TABLE dominios.auxiliar OWNER TO postgres# CREATE TABLE dominios.situacao_fisica ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT situacao_fisica_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (1,'Abandonada (1)'); -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (2,'Destruída (2)'); -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (3,'Em construção (3)'); -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (4,'Planejada (4)'); -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (5,'Construída (5)'); -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (6,'Construída, mas em obras (6)'); -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (97,'Não aplicável (97)'); -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (1,'Abandonada (1)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (2,'Destruída (2)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (3,'Em construção (3)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (4,'Planejada (4)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (5,'Construída (5)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (6,'Construída, mas em obras (6)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.situacao_fisica OWNER TO postgres; +ALTER TABLE dominios.situacao_fisica OWNER TO postgres# CREATE TABLE dominios.tipo_pavimentacao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_pavimentacao_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (2,'Asfalto (2)'); -INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (3,'Placa de concreto (3)'); -INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (4,'Pedra regular (4)'); -INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (5,'Ladrilho de concreto (5)'); -INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (6,'Paralelepípedo (6)'); -INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (7,'Pedra irregular (7)'); -INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (97,'Não aplicável (97)'); -INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (2,'Asfalto (2)')# +INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (3,'Placa de concreto (3)')# +INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (4,'Pedra regular (4)')# +INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (5,'Ladrilho de concreto (5)')# +INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (6,'Paralelepípedo (6)')# +INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (7,'Pedra irregular (7)')# +INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_pavimentacao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_pavimentacao OWNER TO postgres; +ALTER TABLE dominios.tipo_pavimentacao OWNER TO postgres# CREATE TABLE dominios.tipo_edif_energia ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_edif_energia_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (1,'Administração (1)'); -INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (2,'Oficinas (2)'); -INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (3,'Segurança (3)'); -INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (4,'Depósito (4)'); -INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (5,'Chaminé (5)'); -INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (1,'Administração (1)')# +INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (2,'Oficinas (2)')# +INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (3,'Segurança (3)')# +INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (4,'Depósito (4)')# +INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (5,'Chaminé (5)')# +INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_edif_energia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_edif_energia OWNER TO postgres; +ALTER TABLE dominios.tipo_edif_energia OWNER TO postgres# CREATE TABLE dominios.trafego ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT trafego_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.trafego (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.trafego (code,code_name) VALUES (1,'Permanente (1)'); -INSERT INTO dominios.trafego (code,code_name) VALUES (2,'Periódico (2)'); -INSERT INTO dominios.trafego (code,code_name) VALUES (4,'Temporário (4)'); -INSERT INTO dominios.trafego (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.trafego (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.trafego (code,code_name) VALUES (1,'Permanente (1)')# +INSERT INTO dominios.trafego (code,code_name) VALUES (2,'Periódico (2)')# +INSERT INTO dominios.trafego (code,code_name) VALUES (4,'Temporário (4)')# +INSERT INTO dominios.trafego (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.trafego OWNER TO postgres; +ALTER TABLE dominios.trafego OWNER TO postgres# CREATE TABLE dominios.tipo_manguezal ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_manguezal_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_manguezal (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_manguezal (code,code_name) VALUES (2,'Manguezal (2)'); -INSERT INTO dominios.tipo_manguezal (code,code_name) VALUES (3,'Manguezal tipo apicum (3)'); -INSERT INTO dominios.tipo_manguezal (code,code_name) VALUES (4,'Manguezal tipo salgado (4)'); -INSERT INTO dominios.tipo_manguezal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_manguezal (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_manguezal (code,code_name) VALUES (2,'Manguezal (2)')# +INSERT INTO dominios.tipo_manguezal (code,code_name) VALUES (3,'Manguezal tipo apicum (3)')# +INSERT INTO dominios.tipo_manguezal (code,code_name) VALUES (4,'Manguezal tipo salgado (4)')# +INSERT INTO dominios.tipo_manguezal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_manguezal OWNER TO postgres; +ALTER TABLE dominios.tipo_manguezal OWNER TO postgres# CREATE TABLE dominios.posicao_rel_edific ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT posicao_rel_edific_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.posicao_rel_edific (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.posicao_rel_edific (code,code_name) VALUES (14,'Isolada (14)'); -INSERT INTO dominios.posicao_rel_edific (code,code_name) VALUES (17,'Adjacente à edificação (17)'); -INSERT INTO dominios.posicao_rel_edific (code,code_name) VALUES (18,'Sobre edificação (18)'); -INSERT INTO dominios.posicao_rel_edific (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.posicao_rel_edific (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.posicao_rel_edific (code,code_name) VALUES (14,'Isolada (14)')# +INSERT INTO dominios.posicao_rel_edific (code,code_name) VALUES (17,'Adjacente à edificação (17)')# +INSERT INTO dominios.posicao_rel_edific (code,code_name) VALUES (18,'Sobre edificação (18)')# +INSERT INTO dominios.posicao_rel_edific (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.posicao_rel_edific OWNER TO postgres; +ALTER TABLE dominios.posicao_rel_edific OWNER TO postgres# CREATE TABLE dominios.posicao_relativa ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT posicao_relativa_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (2,'Superfície (2)'); -INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (3,'Elevada (3)'); -INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (4,'Emersa (4)'); -INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (5,'Submersa (5)'); -INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (6,'Subterrânea (6)'); -INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (2,'Superfície (2)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (3,'Elevada (3)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (4,'Emersa (4)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (5,'Submersa (5)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (6,'Subterrânea (6)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.posicao_relativa OWNER TO postgres; +ALTER TABLE dominios.posicao_relativa OWNER TO postgres# CREATE TABLE dominios.tipo_campo ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_campo_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_campo (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_campo (code,code_name) VALUES (1,'Sujo (1)'); -INSERT INTO dominios.tipo_campo (code,code_name) VALUES (2,'Limpo (2)'); -INSERT INTO dominios.tipo_campo (code,code_name) VALUES (3,'Rupestre (3)'); -INSERT INTO dominios.tipo_campo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_campo (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_campo (code,code_name) VALUES (1,'Sujo (1)')# +INSERT INTO dominios.tipo_campo (code,code_name) VALUES (2,'Limpo (2)')# +INSERT INTO dominios.tipo_campo (code,code_name) VALUES (3,'Rupestre (3)')# +INSERT INTO dominios.tipo_campo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_campo OWNER TO postgres; +ALTER TABLE dominios.tipo_campo OWNER TO postgres# CREATE TABLE dominios.tipo_passag_viad ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_passag_viad_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_passag_viad (code,code_name) VALUES (5,'Passagem elevada (5)'); -INSERT INTO dominios.tipo_passag_viad (code,code_name) VALUES (6,'Viaduto (6)'); -INSERT INTO dominios.tipo_passag_viad (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_passag_viad (code,code_name) VALUES (5,'Passagem elevada (5)')# +INSERT INTO dominios.tipo_passag_viad (code,code_name) VALUES (6,'Viaduto (6)')# +INSERT INTO dominios.tipo_passag_viad (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_passag_viad OWNER TO postgres; +ALTER TABLE dominios.tipo_passag_viad OWNER TO postgres# CREATE TABLE dominios.tipo_queda ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_queda_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_queda (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_queda (code,code_name) VALUES (1,'Cachoeira (1)'); -INSERT INTO dominios.tipo_queda (code,code_name) VALUES (2,'Salto (2)'); -INSERT INTO dominios.tipo_queda (code,code_name) VALUES (3,'Catarata (3)'); -INSERT INTO dominios.tipo_queda (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_queda (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_queda (code,code_name) VALUES (1,'Cachoeira (1)')# +INSERT INTO dominios.tipo_queda (code,code_name) VALUES (2,'Salto (2)')# +INSERT INTO dominios.tipo_queda (code,code_name) VALUES (3,'Catarata (3)')# +INSERT INTO dominios.tipo_queda (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_queda OWNER TO postgres; +ALTER TABLE dominios.tipo_queda OWNER TO postgres# CREATE TABLE dominios.tipo_conteudo ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_conteudo_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_conteudo (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_conteudo (code,code_name) VALUES (1,'Insumo (1)'); -INSERT INTO dominios.tipo_conteudo (code,code_name) VALUES (2,'Produto (2)'); -INSERT INTO dominios.tipo_conteudo (code,code_name) VALUES (3,'Resíduo (3)'); -INSERT INTO dominios.tipo_conteudo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_conteudo (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_conteudo (code,code_name) VALUES (1,'Insumo (1)')# +INSERT INTO dominios.tipo_conteudo (code,code_name) VALUES (2,'Produto (2)')# +INSERT INTO dominios.tipo_conteudo (code,code_name) VALUES (3,'Resíduo (3)')# +INSERT INTO dominios.tipo_conteudo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_conteudo OWNER TO postgres; +ALTER TABLE dominios.tipo_conteudo OWNER TO postgres# CREATE TABLE dominios.tipo_localidade ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_localidade_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (1,'Aglomerado rural isolado - Núcleo (1)'); -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (2,'Aglomerado rural isolado - Povoado (2)'); -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (3,'Outros aglomerados rurais (3)'); -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (4,'Capital (4)'); -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (5,'Cidade (5)'); -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (6,'Vila (6)'); -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (1,'Aglomerado rural isolado - Núcleo (1)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (2,'Aglomerado rural isolado - Povoado (2)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (3,'Outros aglomerados rurais (3)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (4,'Capital Estadual (4)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (5,'Cidade (5)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (6,'Vila (6)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (7,'Capital Federal (7)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_localidade OWNER TO postgres; +ALTER TABLE dominios.tipo_localidade OWNER TO postgres# CREATE TABLE dominios.proximidade ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT proximidade_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.proximidade (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.proximidade (code,code_name) VALUES (14,'Isolada (14)'); -INSERT INTO dominios.proximidade (code,code_name) VALUES (15,'Adjacente (15)'); -INSERT INTO dominios.proximidade (code,code_name) VALUES (16,'Coincidente (16)'); -INSERT INTO dominios.proximidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.proximidade (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.proximidade (code,code_name) VALUES (14,'Isolada (14)')# +INSERT INTO dominios.proximidade (code,code_name) VALUES (15,'Adjacente (15)')# +INSERT INTO dominios.proximidade (code,code_name) VALUES (16,'Coincidente (16)')# +INSERT INTO dominios.proximidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.proximidade OWNER TO postgres; +ALTER TABLE dominios.proximidade OWNER TO postgres# CREATE TABLE dominios.tipo_ext_min ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_ext_min_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (1,'Poço para água subterrânea (1)'); -INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (4,'Mina (4)'); -INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (5,'Garimpo (5)'); -INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (6,'Salina (6)'); -INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (8,'Poço de petróleo (8)'); -INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (1,'Poço para água subterrânea (1)')# +INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (4,'Mina (4)')# +INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (5,'Garimpo (5)')# +INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (6,'Salina (6)')# +INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (8,'Poço de petróleo (8)')# +INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_ext_min (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_ext_min OWNER TO postgres; +ALTER TABLE dominios.tipo_ext_min OWNER TO postgres# CREATE TABLE dominios.tipo_fundeadouro ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_fundeadouro_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_fundeadouro (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_fundeadouro (code,code_name) VALUES (1,'Com limite definido (1)'); -INSERT INTO dominios.tipo_fundeadouro (code,code_name) VALUES (2,'Sem limite definido (2)'); -INSERT INTO dominios.tipo_fundeadouro (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_fundeadouro (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_fundeadouro (code,code_name) VALUES (1,'Com limite definido (1)')# +INSERT INTO dominios.tipo_fundeadouro (code,code_name) VALUES (2,'Sem limite definido (2)')# +INSERT INTO dominios.tipo_fundeadouro (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_fundeadouro OWNER TO postgres; +ALTER TABLE dominios.tipo_fundeadouro OWNER TO postgres# CREATE TABLE dominios.classificacao_porte ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT classificacao_porte_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.classificacao_porte (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.classificacao_porte (code,code_name) VALUES (1,'Arbórea (1)'); -INSERT INTO dominios.classificacao_porte (code,code_name) VALUES (2,'Arbustiva (2)'); -INSERT INTO dominios.classificacao_porte (code,code_name) VALUES (3,'Herbácea (3)'); -INSERT INTO dominios.classificacao_porte (code,code_name) VALUES (4,'Rasteira (4)'); -INSERT INTO dominios.classificacao_porte (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.classificacao_porte (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.classificacao_porte (code,code_name) VALUES (1,'Arbórea (1)')# +INSERT INTO dominios.classificacao_porte (code,code_name) VALUES (2,'Arbustiva (2)')# +INSERT INTO dominios.classificacao_porte (code,code_name) VALUES (3,'Herbácea (3)')# +INSERT INTO dominios.classificacao_porte (code,code_name) VALUES (4,'Rasteira (4)')# +INSERT INTO dominios.classificacao_porte (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.classificacao_porte OWNER TO postgres; +ALTER TABLE dominios.classificacao_porte OWNER TO postgres# CREATE TABLE dominios.tipo_edif_comerc_serv ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_edif_comerc_serv_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (3,'Centro comercial (3)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (4,'Mercado público (4)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (5,'Centro de convenções (5)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (6,'Banca de jornal (6)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (7,'Hotel (7)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (8,'Restaurante (8)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (9,'Comércio de carnes (9)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (10,'Farmácia (10)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (11,'Banco (11)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (12,'Loja de conveniência (12)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (13,'Loja de materiais de construção e/ou ferragem (13)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (14,'Loja de móveis (14)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (15,'Loja de roupas e/ou tecidos (15)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (16,'Motel (16)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (17,'Oficina mecânica (17)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (18,'Outros comércios (18)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (19,'Posto de combustível (19)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (20,'Pousada (20)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (21,'Quiosque (21)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (22,'Quitanda (22)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (23,'Supermercado (23)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (24,'Venda de veículos (24)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (25,'Administração (25)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (26,'Centro de exposições (26)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (99,'Outros serviços (99)'); -INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_edif_comerc_serv OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (3,'Centro comercial (3)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (4,'Mercado público (4)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (5,'Centro de convenções (5)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (6,'Banca de jornal (6)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (7,'Hotel (7)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (8,'Restaurante (8)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (9,'Comércio de carnes (9)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (10,'Farmácia (10)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (11,'Banco (11)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (12,'Loja de conveniência (12)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (13,'Loja de materiais de construção e/ou ferragem (13)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (14,'Loja de móveis (14)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (15,'Loja de roupas e/ou tecidos (15)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (16,'Motel (16)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (17,'Oficina mecânica (17)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (18,'Outros comércios (18)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (19,'Posto de combustível (19)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (20,'Pousada (20)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (21,'Quiosque (21)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (22,'Quitanda (22)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (23,'Supermercado (23)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (24,'Venda de veículos (24)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (25,'Administração (25)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (26,'Centro de exposições (26)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (99,'Outros serviços (99)')# +INSERT INTO dominios.tipo_edif_comerc_serv (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_edif_comerc_serv OWNER TO postgres# CREATE TABLE dominios.situacao_costa ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT situacao_costa_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.situacao_costa (code,code_name) VALUES (10,'Contígua (10)'); -INSERT INTO dominios.situacao_costa (code,code_name) VALUES (11,'Afastada (11)'); -INSERT INTO dominios.situacao_costa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.situacao_costa (code,code_name) VALUES (10,'Contígua (10)')# +INSERT INTO dominios.situacao_costa (code,code_name) VALUES (11,'Afastada (11)')# +INSERT INTO dominios.situacao_costa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.situacao_costa OWNER TO postgres; +ALTER TABLE dominios.situacao_costa OWNER TO postgres# CREATE TABLE dominios.finalidade ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT finalidade_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.finalidade (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.finalidade (code,code_name) VALUES (1,'Comercial (1)'); -INSERT INTO dominios.finalidade (code,code_name) VALUES (2,'Serviço (2)'); -INSERT INTO dominios.finalidade (code,code_name) VALUES (4,'Residencial (4)'); -INSERT INTO dominios.finalidade (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.finalidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.finalidade (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.finalidade (code,code_name) VALUES (1,'Comercial (1)')# +INSERT INTO dominios.finalidade (code,code_name) VALUES (2,'Serviço (2)')# +INSERT INTO dominios.finalidade (code,code_name) VALUES (4,'Residencial (4)')# +INSERT INTO dominios.finalidade (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.finalidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.finalidade OWNER TO postgres; +ALTER TABLE dominios.finalidade OWNER TO postgres# CREATE TABLE dominios.referencial_altim ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT referencial_altim_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.referencial_altim (code,code_name) VALUES (1,'Torres (1)'); -INSERT INTO dominios.referencial_altim (code,code_name) VALUES (2,'Imbituba (2)'); -INSERT INTO dominios.referencial_altim (code,code_name) VALUES (3,'Santana (3)'); -INSERT INTO dominios.referencial_altim (code,code_name) VALUES (99,'Outra referência (99)'); -INSERT INTO dominios.referencial_altim (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (1,'Torres (1)')# +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (2,'Imbituba (2)')# +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (3,'Santana (3)')# +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (99,'Outra referência (99)')# +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.referencial_altim OWNER TO postgres; +ALTER TABLE dominios.referencial_altim OWNER TO postgres# CREATE TABLE dominios.tipo_pto_est_med ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_pto_est_med_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (1,'Climatológica principal - CP (1)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (2,'Climatológica auxiliar - CA (2)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (3,'Agroclimatológica - AC (3)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (4,'Pluviométrica - PL (4)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (5,'Eólica - EO (5)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (6,'Evaporimétrica - EV (6)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (7,'Solarimétrica - SL (7)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (8,'Radar metereológico - RD (8)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (9,'Radiossonda - RS (9)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (10,'Fluviométrica - FL (10)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (11,'Maregráfica - MA (11)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (12,'Marés terrestres-crosta (12)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (13,'Metero-maregráfica (13)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (14,'Hidrológica (14)'); -INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_pto_est_med OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (1,'Climatológica principal - CP (1)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (2,'Climatológica auxiliar - CA (2)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (3,'Agroclimatológica - AC (3)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (4,'Pluviométrica - PL (4)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (5,'Eólica - EO (5)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (6,'Evaporimétrica - EV (6)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (7,'Solarimétrica - SL (7)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (8,'Radar metereológico - RD (8)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (9,'Radiossonda - RS (9)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (10,'Fluviométrica - FL (10)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (11,'Maregráfica - MA (11)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (12,'Marés terrestres-crosta (12)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (13,'Metero-maregráfica (13)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (14,'Hidrológica (14)')# +INSERT INTO dominios.tipo_pto_est_med (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_pto_est_med OWNER TO postgres# CREATE TABLE dominios.tipo_recife ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_recife_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_recife (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_recife (code,code_name) VALUES (1,'Arenito (1)'); -INSERT INTO dominios.tipo_recife (code,code_name) VALUES (2,'Rochoso (2)'); -INSERT INTO dominios.tipo_recife (code,code_name) VALUES (20,'Coral (20)'); -INSERT INTO dominios.tipo_recife (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_recife (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_recife (code,code_name) VALUES (1,'Arenito (1)')# +INSERT INTO dominios.tipo_recife (code,code_name) VALUES (2,'Rochoso (2)')# +INSERT INTO dominios.tipo_recife (code,code_name) VALUES (20,'Coral (20)')# +INSERT INTO dominios.tipo_recife (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_recife OWNER TO postgres; +ALTER TABLE dominios.tipo_recife OWNER TO postgres# CREATE TABLE dominios.tipo_edif_agropec ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_edif_agropec_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (4,'Administração (4)'); -INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (12,'Sede operacional de fazenda (12)'); -INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (13,'Aviário (13)'); -INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (14,'Apiário (14)'); -INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (15,'Viveiro de plantas (15)'); -INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (16,'Viveiro para aquicultura (16)'); -INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (17,'Pocilga (17)'); -INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (18,'Curral (18)'); -INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_edif_agropec OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (4,'Administração (4)')# +INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (12,'Sede operacional de fazenda (12)')# +INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (13,'Aviário (13)')# +INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (14,'Apiário (14)')# +INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (15,'Viveiro de plantas (15)')# +INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (16,'Viveiro para aquicultura (16)')# +INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (17,'Pocilga (17)')# +INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (18,'Curral (18)')# +INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_edif_agropec (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_edif_agropec OWNER TO postgres# CREATE TABLE dominios.tipo_trecho_drenagem ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_trecho_drenagem_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (4,'Curso d''água (4)'); -INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (5,'Pluvial (5)'); -INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (4,'Curso d''água (4)')# +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (5,'Pluvial (5)')# +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_trecho_drenagem OWNER TO postgres; +ALTER TABLE dominios.tipo_trecho_drenagem OWNER TO postgres# CREATE TABLE dominios.tipo_cemiterio ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_cemiterio_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (1,'Crematório (1)'); -INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (2,'Parque (2)'); -INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (3,'Vertical (3)'); -INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (4,'Comum (4)'); -INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (5,'Túmulo isolado (5)'); -INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (6,'Horizontal/vertical (6)'); -INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (98,'Misto (98)'); -INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (1,'Crematório (1)')# +INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (2,'Parque (2)')# +INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (3,'Vertical (3)')# +INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (4,'Comum (4)')# +INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (5,'Túmulo isolado (5)')# +INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (6,'Horizontal/vertical (6)')# +INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (98,'Misto (98)')# +INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_cemiterio (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_cemiterio OWNER TO postgres; +ALTER TABLE dominios.tipo_cemiterio OWNER TO postgres# CREATE TABLE dominios.tipo_unid_uso_sust ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_unid_uso_sust_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (1,'Área de proteção ambiental - APA (1)'); -INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (2,'Área de relevante interesse ecológico – ARIE (2)'); -INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (3,'Floresta – FLO (3)'); -INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (4,'Reserva de desenvolvimento sustentável – RDS (4)'); -INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (5,'Reserva extrativista (5)'); -INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (6,'Reserva de fauna – REFAU (6)'); -INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (7,'Reserva particular de patrimônio natural – RPPN (7)'); -INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (1,'Área de proteção ambiental - APA (1)')# +INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (2,'Área de relevante interesse ecológico – ARIE (2)')# +INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (3,'Floresta – FLO (3)')# +INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (4,'Reserva de desenvolvimento sustentável – RDS (4)')# +INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (5,'Reserva extrativista (5)')# +INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (6,'Reserva de fauna – REFAU (6)')# +INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (7,'Reserva particular de patrimônio natural – RPPN (7)')# +INSERT INTO dominios.tipo_unid_uso_sust (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_unid_uso_sust OWNER TO postgres; +ALTER TABLE dominios.tipo_unid_uso_sust OWNER TO postgres# CREATE TABLE dominios.tipo_edif_port ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_edif_port_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (15,'Administração (15)'); -INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (26,'Terminal de passageiros (26)'); -INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (27,'Terminal de cargas (27)'); -INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (32,'Armazém (32)'); -INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (33,'Estaleiro (33)'); -INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (34,'Dique de estaleiro (34)'); -INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (35,'Rampa transportadora (35)'); -INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (36,'Carreira (36)'); -INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (37,'Terminal de uso privativo (37)'); -INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_edif_port OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (15,'Administração (15)')# +INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (26,'Terminal de passageiros (26)')# +INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (27,'Terminal de cargas (27)')# +INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (32,'Armazém (32)')# +INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (33,'Estaleiro (33)')# +INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (34,'Dique de estaleiro (34)')# +INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (35,'Rampa transportadora (35)')# +INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (36,'Carreira (36)')# +INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (37,'Terminal de uso privativo (37)')# +INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_edif_port (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_edif_port OWNER TO postgres# CREATE TABLE dominios.tipo_plataforma ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_plataforma_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_plataforma (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_plataforma (code,code_name) VALUES (3,'Petróleo (3)'); -INSERT INTO dominios.tipo_plataforma (code,code_name) VALUES (5,'Gás (5)'); -INSERT INTO dominios.tipo_plataforma (code,code_name) VALUES (98,'Misto (98)'); -INSERT INTO dominios.tipo_plataforma (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_plataforma (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_plataforma (code,code_name) VALUES (3,'Petróleo (3)')# +INSERT INTO dominios.tipo_plataforma (code,code_name) VALUES (5,'Gás (5)')# +INSERT INTO dominios.tipo_plataforma (code,code_name) VALUES (98,'Misto (98)')# +INSERT INTO dominios.tipo_plataforma (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_plataforma OWNER TO postgres; +ALTER TABLE dominios.tipo_plataforma OWNER TO postgres# CREATE TABLE dominios.tipo_posto_fisc ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_posto_fisc_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (10,'Tributação (10)'); -INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (12,'Fiscalização sanitária (12)'); -INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (13,'Posto de pesagem (13)'); -INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (98,'Misto (98)'); -INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (10,'Tributação (10)')# +INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (12,'Fiscalização sanitária (12)')# +INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (13,'Posto de pesagem (13)')# +INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (98,'Misto (98)')# +INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_posto_fisc (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_posto_fisc OWNER TO postgres; +ALTER TABLE dominios.tipo_posto_fisc OWNER TO postgres# CREATE TABLE dominios.tipo_unid_protegida ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_unid_protegida_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_unid_protegida (code,code_name) VALUES (1,'Unidade de conservação não SNUC (1)'); -INSERT INTO dominios.tipo_unid_protegida (code,code_name) VALUES (2,'Unidade de proteção integral (2)'); -INSERT INTO dominios.tipo_unid_protegida (code,code_name) VALUES (3,'Unidade de uso sustentável (3)'); -INSERT INTO dominios.tipo_unid_protegida (code,code_name) VALUES (4,'Unidade de conservação (4)'); -INSERT INTO dominios.tipo_unid_protegida (code,code_name) VALUES (5,'Outras unidades protegidas (5)'); -INSERT INTO dominios.tipo_unid_protegida (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_unid_protegida (code,code_name) VALUES (1,'Unidade de conservação não SNUC (1)')# +INSERT INTO dominios.tipo_unid_protegida (code,code_name) VALUES (2,'Unidade de proteção integral (2)')# +INSERT INTO dominios.tipo_unid_protegida (code,code_name) VALUES (3,'Unidade de uso sustentável (3)')# +INSERT INTO dominios.tipo_unid_protegida (code,code_name) VALUES (4,'Unidade de conservação (4)')# +INSERT INTO dominios.tipo_unid_protegida (code,code_name) VALUES (5,'Outras unidades protegidas (5)')# +INSERT INTO dominios.tipo_unid_protegida (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_unid_protegida OWNER TO postgres; +ALTER TABLE dominios.tipo_unid_protegida OWNER TO postgres# CREATE TABLE dominios.tipo_edif_abast ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_edif_abast_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (1,'Captação (1)'); -INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (2,'Tratamento (2)'); -INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (3,'Recalque (3)'); -INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (4,'Administração (4)'); -INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (98,'Misto (98)'); -INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (1,'Captação (1)')# +INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (2,'Tratamento (2)')# +INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (3,'Recalque (3)')# +INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (4,'Administração (4)')# +INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (98,'Misto (98)')# +INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_edif_abast (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_edif_abast OWNER TO postgres; +ALTER TABLE dominios.tipo_edif_abast OWNER TO postgres# CREATE TABLE dominios.proc_extracao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT proc_extracao_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.proc_extracao (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.proc_extracao (code,code_name) VALUES (1,'Mecanizado (1)'); -INSERT INTO dominios.proc_extracao (code,code_name) VALUES (2,'Manual (2)'); -INSERT INTO dominios.proc_extracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.proc_extracao (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.proc_extracao (code,code_name) VALUES (1,'Mecanizado (1)')# +INSERT INTO dominios.proc_extracao (code,code_name) VALUES (2,'Manual (2)')# +INSERT INTO dominios.proc_extracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.proc_extracao OWNER TO postgres; +ALTER TABLE dominios.proc_extracao OWNER TO postgres# CREATE TABLE dominios.tipo_area_umida ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_area_umida_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_area_umida (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_area_umida (code,code_name) VALUES (3,'Lamacento (3)'); -INSERT INTO dominios.tipo_area_umida (code,code_name) VALUES (4,'Arenoso (4)'); -INSERT INTO dominios.tipo_area_umida (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_area_umida (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_area_umida (code,code_name) VALUES (3,'Lamacento (3)')# +INSERT INTO dominios.tipo_area_umida (code,code_name) VALUES (4,'Arenoso (4)')# +INSERT INTO dominios.tipo_area_umida (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_area_umida OWNER TO postgres; +ALTER TABLE dominios.tipo_area_umida OWNER TO postgres# CREATE TABLE dominios.mat_transp ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT mat_transp_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.mat_transp (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (1,'Água (1)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (2,'Óleo (2)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (3,'Petróleo (3)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (4,'Nafta (4)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (5,'Gás (5)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (6,'Grãos (6)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (7,'Minério (7)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (8,'Efluentes (8)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (9,'Esgoto (9)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (29,'Gasolina (29)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (30,'Álcool (30)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (31,'Querosene (31)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.mat_transp (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.mat_transp OWNER TO postgres; +)# + +INSERT INTO dominios.mat_transp (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (1,'Água (1)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (2,'Óleo (2)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (3,'Petróleo (3)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (4,'Nafta (4)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (5,'Gás (5)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (6,'Grãos (6)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (7,'Minério (7)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (8,'Efluentes (8)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (9,'Esgoto (9)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (29,'Gasolina (29)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (30,'Álcool (30)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (31,'Querosene (31)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.mat_transp (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.mat_transp OWNER TO postgres# CREATE TABLE dominios.tipo_poco_mina ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_poco_mina_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_poco_mina (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_poco_mina (code,code_name) VALUES (2,'Horizontal (2)'); -INSERT INTO dominios.tipo_poco_mina (code,code_name) VALUES (3,'Vertical (3)'); -INSERT INTO dominios.tipo_poco_mina (code,code_name) VALUES (97,'Não aplicável (97)'); -INSERT INTO dominios.tipo_poco_mina (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_poco_mina (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_poco_mina (code,code_name) VALUES (2,'Horizontal (2)')# +INSERT INTO dominios.tipo_poco_mina (code,code_name) VALUES (3,'Vertical (3)')# +INSERT INTO dominios.tipo_poco_mina (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.tipo_poco_mina (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_poco_mina OWNER TO postgres; +ALTER TABLE dominios.tipo_poco_mina OWNER TO postgres# CREATE TABLE dominios.tipo_edif_metro_ferrov ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_edif_metro_ferrov_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (15,'Administração (15)'); -INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (16,'Estação ferroviária de passageiros (16)'); -INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (17,'Estação metroviária (17)'); -INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (18,'Terminal ferroviário de cargas (18)'); -INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (19,'Terminal ferroviário de passageiros e cargas (19)'); -INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (20,'Oficina de manutenção (20)'); -INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (15,'Administração (15)')# +INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (16,'Estação ferroviária de passageiros (16)')# +INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (17,'Estação metroviária (17)')# +INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (18,'Terminal ferroviário de cargas (18)')# +INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (19,'Terminal ferroviário de passageiros e cargas (19)')# +INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (20,'Oficina de manutenção (20)')# +INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_edif_metro_ferrov (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_edif_metro_ferrov OWNER TO postgres; +ALTER TABLE dominios.tipo_edif_metro_ferrov OWNER TO postgres# CREATE TABLE dominios.nivel_atencao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT nivel_atencao_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.nivel_atencao (code,code_name) VALUES (5,'Primário (5)'); -INSERT INTO dominios.nivel_atencao (code,code_name) VALUES (6,'Secundário (6)'); -INSERT INTO dominios.nivel_atencao (code,code_name) VALUES (7,'Terciário (7)'); -INSERT INTO dominios.nivel_atencao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.nivel_atencao (code,code_name) VALUES (5,'Primário (5)')# +INSERT INTO dominios.nivel_atencao (code,code_name) VALUES (6,'Secundário (6)')# +INSERT INTO dominios.nivel_atencao (code,code_name) VALUES (7,'Terciário (7)')# +INSERT INTO dominios.nivel_atencao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.nivel_atencao OWNER TO postgres; +ALTER TABLE dominios.nivel_atencao OWNER TO postgres# CREATE TABLE dominios.setor ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT setor_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.setor (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.setor (code,code_name) VALUES (1,'Energético (1)'); -INSERT INTO dominios.setor (code,code_name) VALUES (2,'Econômico (2)'); -INSERT INTO dominios.setor (code,code_name) VALUES (3,'Abastecimento de água (3)'); -INSERT INTO dominios.setor (code,code_name) VALUES (4,'Saneamento básico (4)'); -INSERT INTO dominios.setor (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.setor (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.setor (code,code_name) VALUES (1,'Energético (1)')# +INSERT INTO dominios.setor (code,code_name) VALUES (2,'Econômico (2)')# +INSERT INTO dominios.setor (code,code_name) VALUES (3,'Abastecimento de água (3)')# +INSERT INTO dominios.setor (code,code_name) VALUES (4,'Saneamento básico (4)')# +INSERT INTO dominios.setor (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.setor OWNER TO postgres; +ALTER TABLE dominios.setor OWNER TO postgres# CREATE TABLE dominios.revestimento ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT revestimento_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.revestimento (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.revestimento (code,code_name) VALUES (1,'Sem revestimento (leito natural) (1)'); -INSERT INTO dominios.revestimento (code,code_name) VALUES (2,'Revestimento primário (solto) (2)'); -INSERT INTO dominios.revestimento (code,code_name) VALUES (3,'Pavimentado (3)'); -INSERT INTO dominios.revestimento (code,code_name) VALUES (4,'Madeira (4)'); -INSERT INTO dominios.revestimento (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.revestimento (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.revestimento (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (1,'Sem revestimento (leito natural) (1)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (2,'Revestimento primário (solto) (2)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (3,'Pavimentado (3)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (4,'Madeira (4)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.revestimento OWNER TO postgres; +ALTER TABLE dominios.revestimento OWNER TO postgres# CREATE TABLE dominios.finalidade_deposito ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT finalidade_deposito_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.finalidade_deposito (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.finalidade_deposito (code,code_name) VALUES (2,'Tratamento (2)'); -INSERT INTO dominios.finalidade_deposito (code,code_name) VALUES (3,'Recalque (3)'); -INSERT INTO dominios.finalidade_deposito (code,code_name) VALUES (4,'Distribuição (4)'); -INSERT INTO dominios.finalidade_deposito (code,code_name) VALUES (8,'Armazenamento (8)'); -INSERT INTO dominios.finalidade_deposito (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.finalidade_deposito (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.finalidade_deposito (code,code_name) VALUES (2,'Tratamento (2)')# +INSERT INTO dominios.finalidade_deposito (code,code_name) VALUES (3,'Recalque (3)')# +INSERT INTO dominios.finalidade_deposito (code,code_name) VALUES (4,'Distribuição (4)')# +INSERT INTO dominios.finalidade_deposito (code,code_name) VALUES (8,'Armazenamento (8)')# +INSERT INTO dominios.finalidade_deposito (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.finalidade_deposito OWNER TO postgres; +ALTER TABLE dominios.finalidade_deposito OWNER TO postgres# CREATE TABLE dominios.tipo_poste ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_poste_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_poste (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_poste (code,code_name) VALUES (2,'Iluminação (2)'); -INSERT INTO dominios.tipo_poste (code,code_name) VALUES (3,'Ornamental (3)'); -INSERT INTO dominios.tipo_poste (code,code_name) VALUES (4,'Rede elétrica (4)'); -INSERT INTO dominios.tipo_poste (code,code_name) VALUES (5,'Sinalização (5)'); -INSERT INTO dominios.tipo_poste (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_poste (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_poste (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_poste (code,code_name) VALUES (2,'Iluminação (2)')# +INSERT INTO dominios.tipo_poste (code,code_name) VALUES (3,'Ornamental (3)')# +INSERT INTO dominios.tipo_poste (code,code_name) VALUES (4,'Rede elétrica (4)')# +INSERT INTO dominios.tipo_poste (code,code_name) VALUES (5,'Sinalização (5)')# +INSERT INTO dominios.tipo_poste (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_poste (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_poste OWNER TO postgres; +ALTER TABLE dominios.tipo_poste OWNER TO postgres# CREATE TABLE dominios.unidade_volume ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT unidade_volume_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.unidade_volume (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.unidade_volume (code,code_name) VALUES (1,'Litro (1)'); -INSERT INTO dominios.unidade_volume (code,code_name) VALUES (2,'Metro cúbico (2)'); -INSERT INTO dominios.unidade_volume (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.unidade_volume (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.unidade_volume (code,code_name) VALUES (1,'Litro (1)')# +INSERT INTO dominios.unidade_volume (code,code_name) VALUES (2,'Metro cúbico (2)')# +INSERT INTO dominios.unidade_volume (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.unidade_volume OWNER TO postgres; +ALTER TABLE dominios.unidade_volume OWNER TO postgres# CREATE TABLE dominios.tipo_edif_saneam ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_edif_saneam_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (3,'Recalque (3)'); -INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (5,'Tratamento de esgoto (5)'); -INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (6,'Usina de reciclagem (6)'); -INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (7,'Incinerador (7)'); -INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (8,'Administração (8)'); -INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (3,'Recalque (3)')# +INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (5,'Tratamento de esgoto (5)')# +INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (6,'Usina de reciclagem (6)')# +INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (7,'Incinerador (7)')# +INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (8,'Administração (8)')# +INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_edif_saneam (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_edif_saneam OWNER TO postgres; +ALTER TABLE dominios.tipo_edif_saneam OWNER TO postgres# CREATE TABLE dominios.tipo_sum_vert ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_sum_vert_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_sum_vert (code,code_name) VALUES (1,'Sumidouro (1)'); -INSERT INTO dominios.tipo_sum_vert (code,code_name) VALUES (2,'Vertedouro (2)'); -INSERT INTO dominios.tipo_sum_vert (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_sum_vert (code,code_name) VALUES (1,'Sumidouro (1)')# +INSERT INTO dominios.tipo_sum_vert (code,code_name) VALUES (2,'Vertedouro (2)')# +INSERT INTO dominios.tipo_sum_vert (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_sum_vert OWNER TO postgres; +ALTER TABLE dominios.tipo_sum_vert OWNER TO postgres# CREATE TABLE dominios.tipo_elevador ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_elevador_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_elevador (code,code_name) VALUES (2,'Inclinado (2)'); -INSERT INTO dominios.tipo_elevador (code,code_name) VALUES (3,'Vertical (3)'); -INSERT INTO dominios.tipo_elevador (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_elevador (code,code_name) VALUES (2,'Inclinado (2)')# +INSERT INTO dominios.tipo_elevador (code,code_name) VALUES (3,'Vertical (3)')# +INSERT INTO dominios.tipo_elevador (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_elevador OWNER TO postgres; +ALTER TABLE dominios.tipo_elevador OWNER TO postgres# CREATE TABLE dominios.tipo_elem_nat ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_elem_nat_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (1,'Serra (1)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (2,'Morro (2)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (3,'Montanha (3)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (4,'Chapada (4)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (5,'Maciço (5)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (6,'Planalto (6)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (7,'Planície (7)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (8,'Escarpa (8)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (9,'Península (9)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (10,'Ponta (10)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (11,'Cabo (11)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (12,'Praia (12)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (13,'Falésia (13)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (14,'Talude (14)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (15,'Caverna (15)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (16,'Dolina (16)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (17,'Duna (17)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (18,'Falha (18)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (19,'Fenda (19)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (20,'Gruta (20)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (21,'Ilha (21)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (22,'Pico (22)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (23,'Rocha (23)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_elem_nat OWNER TO postgres; +)# + +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (1,'Serra (1)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (2,'Morro (2)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (3,'Montanha (3)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (4,'Chapada (4)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (5,'Maciço (5)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (6,'Planalto (6)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (7,'Planície (7)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (8,'Escarpa (8)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (9,'Península (9)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (10,'Ponta (10)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (11,'Cabo (11)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (12,'Praia (12)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (13,'Falésia (13)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (14,'Talude (14)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (15,'Caverna (15)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (16,'Dolina (16)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (17,'Duna (17)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (18,'Falha (18)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (19,'Fenda (19)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (20,'Gruta (20)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (21,'Ilha (21)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (22,'Pico (22)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (23,'Rocha (23)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_elem_nat (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_elem_nat OWNER TO postgres# CREATE TABLE dominios.mat_condutor ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT mat_condutor_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.mat_condutor (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.mat_condutor (code,code_name) VALUES (1,'Fibra ótica (1)'); -INSERT INTO dominios.mat_condutor (code,code_name) VALUES (2,'Fio metálico (2)'); -INSERT INTO dominios.mat_condutor (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.mat_condutor (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.mat_condutor (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.mat_condutor (code,code_name) VALUES (1,'Fibra ótica (1)')# +INSERT INTO dominios.mat_condutor (code,code_name) VALUES (2,'Fio metálico (2)')# +INSERT INTO dominios.mat_condutor (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.mat_condutor (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.mat_condutor OWNER TO postgres; +ALTER TABLE dominios.mat_condutor OWNER TO postgres# CREATE TABLE dominios.mat_constr ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT mat_constr_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.mat_constr (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.mat_constr (code,code_name) VALUES (1,'Alvenaria (1)'); -INSERT INTO dominios.mat_constr (code,code_name) VALUES (2,'Concreto (2)'); -INSERT INTO dominios.mat_constr (code,code_name) VALUES (3,'Metal (3)'); -INSERT INTO dominios.mat_constr (code,code_name) VALUES (4,'Rocha (4)'); -INSERT INTO dominios.mat_constr (code,code_name) VALUES (5,'Madeira (5)'); -INSERT INTO dominios.mat_constr (code,code_name) VALUES (8,'Fibra (8)'); -INSERT INTO dominios.mat_constr (code,code_name) VALUES (23,'Terra (23)'); -INSERT INTO dominios.mat_constr (code,code_name) VALUES (97,'Não aplicável (97)'); -INSERT INTO dominios.mat_constr (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.mat_constr (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.mat_constr OWNER TO postgres; +)# + +INSERT INTO dominios.mat_constr (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.mat_constr (code,code_name) VALUES (1,'Alvenaria (1)')# +INSERT INTO dominios.mat_constr (code,code_name) VALUES (2,'Concreto (2)')# +INSERT INTO dominios.mat_constr (code,code_name) VALUES (3,'Metal (3)')# +INSERT INTO dominios.mat_constr (code,code_name) VALUES (4,'Rocha (4)')# +INSERT INTO dominios.mat_constr (code,code_name) VALUES (5,'Madeira (5)')# +INSERT INTO dominios.mat_constr (code,code_name) VALUES (8,'Fibra (8)')# +INSERT INTO dominios.mat_constr (code,code_name) VALUES (23,'Terra (23)')# +INSERT INTO dominios.mat_constr (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.mat_constr (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.mat_constr (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.mat_constr OWNER TO postgres# CREATE TABLE dominios.situacao_espacial ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT situacao_espacial_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (2,'Subterrânea (2)'); -INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (4,'Superposta nível 2 (4)'); -INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (5,'Nível do solo (5)'); -INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (7,'Superposta nível 3 (7)'); -INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (12,'Adjacente (12)'); -INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (13,'Superposta nível 1 (13)'); -INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (97,'Não aplicável (97)'); -INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (99,'Outra (99)'); -INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (2,'Subterrânea (2)')# +INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (4,'Superposta nível 2 (4)')# +INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (5,'Nível do solo (5)')# +INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (7,'Superposta nível 3 (7)')# +INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (12,'Adjacente (12)')# +INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (13,'Superposta nível 1 (13)')# +INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (99,'Outra (99)')# +INSERT INTO dominios.situacao_espacial (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.situacao_espacial OWNER TO postgres; +ALTER TABLE dominios.situacao_espacial OWNER TO postgres# CREATE TABLE dominios.tipo_associado ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_associado_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.tipo_associado (code,code_name) VALUES (1,'Cidade (1)'); -INSERT INTO dominios.tipo_associado (code,code_name) VALUES (4,'Vila (4)'); -INSERT INTO dominios.tipo_associado (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.tipo_associado (code,code_name) VALUES (1,'Cidade (1)')# +INSERT INTO dominios.tipo_associado (code,code_name) VALUES (4,'Vila (4)')# +INSERT INTO dominios.tipo_associado (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.tipo_associado OWNER TO postgres; +ALTER TABLE dominios.tipo_associado OWNER TO postgres# CREATE TABLE dominios.finalidade_patio ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT finalidade_patio_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (2,'Depósito temporário de cargas e contêineres (2)'); -INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (3,'Estacionamento de veículos (3)'); -INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (4,'Estacionamento de locomotivas (4)'); -INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (5,'Estacionamento de aeronaves (5)'); -INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (6,'Manobra de cargas (6)'); -INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (7,'Manobra de veículos em geral (7)'); -INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (8,'Manutenção (8)'); -INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (2,'Depósito temporário de cargas e contêineres (2)')# +INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (3,'Estacionamento de veículos (3)')# +INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (4,'Estacionamento de locomotivas (4)')# +INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (5,'Estacionamento de aeronaves (5)')# +INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (6,'Manobra de cargas (6)')# +INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (7,'Manobra de veículos em geral (7)')# +INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (8,'Manutenção (8)')# +INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.finalidade_patio (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.finalidade_patio OWNER TO postgres; +ALTER TABLE dominios.finalidade_patio OWNER TO postgres# CREATE TABLE dominios.jurisdicao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT jurisdicao_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.jurisdicao (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.jurisdicao (code,code_name) VALUES (1,'Federal (1)'); -INSERT INTO dominios.jurisdicao (code,code_name) VALUES (2,'Estadual/Distrital (2)'); -INSERT INTO dominios.jurisdicao (code,code_name) VALUES (3,'Municipal (3)'); -INSERT INTO dominios.jurisdicao (code,code_name) VALUES (4,'Internacional (4)'); -INSERT INTO dominios.jurisdicao (code,code_name) VALUES (8,'Propriedade particular (8)'); -INSERT INTO dominios.jurisdicao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (1,'Federal (1)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (2,'Estadual/Distrital (2)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (3,'Municipal (3)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (4,'Internacional (4)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (8,'Propriedade particular (8)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.jurisdicao OWNER TO postgres; +ALTER TABLE dominios.jurisdicao OWNER TO postgres# CREATE TABLE dominios.destinado_a ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT destinado_a_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.destinado_a (code,code_name) VALUES (0,'Desconhecido (0)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (5,'Madeira (5)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (18,'Açaí (18)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (34,'Turfa (34)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (35,'Látex (35)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (36,'Castanha (36)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (37,'Carnaúba (37)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (38,'Coco (38)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (39,'Jaborandi (39)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (40,'Palmito (40)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (41,'Babaçu (41)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (43,'Pecuária (43)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (44,'Pesca (44)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (99,'Outros (99)'); -INSERT INTO dominios.destinado_a (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.destinado_a OWNER TO postgres; +)# + +INSERT INTO dominios.destinado_a (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (5,'Madeira (5)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (18,'Açaí (18)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (34,'Turfa (34)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (35,'Látex (35)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (36,'Castanha (36)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (37,'Carnaúba (37)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (38,'Coco (38)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (39,'Jaborandi (39)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (40,'Palmito (40)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (41,'Babaçu (41)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (43,'Pecuária (43)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (44,'Pesca (44)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.destinado_a (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.destinado_a OWNER TO postgres# CREATE TABLE dominios.condicao_terreno ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT condicao_terreno_pk PRIMARY KEY (code) -); +)# -INSERT INTO dominios.condicao_terreno (code,code_name) VALUES (0,'Desconhecida (0)'); -INSERT INTO dominios.condicao_terreno (code,code_name) VALUES (1,'Seco (1)'); -INSERT INTO dominios.condicao_terreno (code,code_name) VALUES (2,'Irrigado (2)'); -INSERT INTO dominios.condicao_terreno (code,code_name) VALUES (3,'Inundado (3)'); -INSERT INTO dominios.condicao_terreno (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); +INSERT INTO dominios.condicao_terreno (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.condicao_terreno (code,code_name) VALUES (1,'Seco (1)')# +INSERT INTO dominios.condicao_terreno (code,code_name) VALUES (2,'Irrigado (2)')# +INSERT INTO dominios.condicao_terreno (code,code_name) VALUES (3,'Inundado (3)')# +INSERT INTO dominios.condicao_terreno (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# -ALTER TABLE dominios.condicao_terreno OWNER TO postgres; - -CREATE TABLE dominios.tipo_lim_politico ( - code smallint NOT NULL, - code_name text NOT NULL, - CONSTRAINT tipo_lim_politico_pk PRIMARY KEY (code) -); - -INSERT INTO dominios.tipo_lim_politico (code,code_name) VALUES (1,'Internacional (1)'); -INSERT INTO dominios.tipo_lim_politico (code,code_name) VALUES (2,'Estadual (2)'); -INSERT INTO dominios.tipo_lim_politico (code,code_name) VALUES (3,'Municipal (3)'); -INSERT INTO dominios.tipo_lim_politico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); - -ALTER TABLE dominios.tipo_lim_politico OWNER TO postgres; +ALTER TABLE dominios.condicao_terreno OWNER TO postgres# CREATE TABLE edgv.aer_pista_ponto_pouso_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipopista smallint NOT NULL, @@ -2723,61 +2712,63 @@ CREATE TABLE edgv.aer_pista_ponto_pouso_l( largura real, extensao real, altitude real, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT aer_pista_ponto_pouso_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX aer_pista_ponto_pouso_l_geom ON edgv.aer_pista_ponto_pouso_l USING gist (geom); +)# +CREATE INDEX aer_pista_ponto_pouso_l_geom ON edgv.aer_pista_ponto_pouso_l USING gist (geom)# -ALTER TABLE edgv.aer_pista_ponto_pouso_l OWNER TO postgres; +ALTER TABLE edgv.aer_pista_ponto_pouso_l OWNER TO postgres# ALTER TABLE edgv.aer_pista_ponto_pouso_l ADD CONSTRAINT aer_pista_ponto_pouso_l_tipopista_fk FOREIGN KEY (tipopista) REFERENCES dominios.tipo_pista (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_l ALTER COLUMN tipopista SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_l ALTER COLUMN tipopista SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_l ADD CONSTRAINT aer_pista_ponto_pouso_l_revestimento_fk FOREIGN KEY (revestimento) REFERENCES dominios.revestimento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_l ALTER COLUMN revestimento SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_l ALTER COLUMN revestimento SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_l ADD CONSTRAINT aer_pista_ponto_pouso_l_usopista_fk FOREIGN KEY (usopista) REFERENCES dominios.uso_pista (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_l ALTER COLUMN usopista SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_l ALTER COLUMN usopista SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_l ADD CONSTRAINT aer_pista_ponto_pouso_l_homologacao_fk FOREIGN KEY (homologacao) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_l ALTER COLUMN homologacao SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_l ALTER COLUMN homologacao SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_l ADD CONSTRAINT aer_pista_ponto_pouso_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_l ADD CONSTRAINT aer_pista_ponto_pouso_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.aer_pista_ponto_pouso_l - ADD CONSTRAINT aer_pista_ponto_pouso_l_situacaofisica_check - CHECK (situacaofisica = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.aer_pista_ponto_pouso_l ALTER COLUMN situacaofisica SET DEFAULT 9999; + ADD CONSTRAINT aer_pista_ponto_pouso_l_situacaofisica_check + CHECK (situacaofisica = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.aer_pista_ponto_pouso_l ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.aer_pista_ponto_pouso_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipopista smallint NOT NULL, @@ -2789,61 +2780,63 @@ CREATE TABLE edgv.aer_pista_ponto_pouso_p( largura real, extensao real, altitude real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT aer_pista_ponto_pouso_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX aer_pista_ponto_pouso_p_geom ON edgv.aer_pista_ponto_pouso_p USING gist (geom); +)# +CREATE INDEX aer_pista_ponto_pouso_p_geom ON edgv.aer_pista_ponto_pouso_p USING gist (geom)# -ALTER TABLE edgv.aer_pista_ponto_pouso_p OWNER TO postgres; +ALTER TABLE edgv.aer_pista_ponto_pouso_p OWNER TO postgres# ALTER TABLE edgv.aer_pista_ponto_pouso_p ADD CONSTRAINT aer_pista_ponto_pouso_p_tipopista_fk FOREIGN KEY (tipopista) REFERENCES dominios.tipo_pista (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_p ALTER COLUMN tipopista SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_p ALTER COLUMN tipopista SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_p ADD CONSTRAINT aer_pista_ponto_pouso_p_revestimento_fk FOREIGN KEY (revestimento) REFERENCES dominios.revestimento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_p ALTER COLUMN revestimento SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_p ALTER COLUMN revestimento SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_p ADD CONSTRAINT aer_pista_ponto_pouso_p_usopista_fk FOREIGN KEY (usopista) REFERENCES dominios.uso_pista (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_p ALTER COLUMN usopista SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_p ALTER COLUMN usopista SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_p ADD CONSTRAINT aer_pista_ponto_pouso_p_homologacao_fk FOREIGN KEY (homologacao) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_p ALTER COLUMN homologacao SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_p ALTER COLUMN homologacao SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_p ADD CONSTRAINT aer_pista_ponto_pouso_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_p ADD CONSTRAINT aer_pista_ponto_pouso_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.aer_pista_ponto_pouso_p - ADD CONSTRAINT aer_pista_ponto_pouso_p_situacaofisica_check - CHECK (situacaofisica = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.aer_pista_ponto_pouso_p ALTER COLUMN situacaofisica SET DEFAULT 9999; + ADD CONSTRAINT aer_pista_ponto_pouso_p_situacaofisica_check + CHECK (situacaofisica = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.aer_pista_ponto_pouso_p ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.aer_pista_ponto_pouso_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipopista smallint NOT NULL, @@ -2855,100 +2848,145 @@ CREATE TABLE edgv.aer_pista_ponto_pouso_a( largura real, extensao real, altitude real, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT aer_pista_ponto_pouso_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX aer_pista_ponto_pouso_a_geom ON edgv.aer_pista_ponto_pouso_a USING gist (geom); +)# +CREATE INDEX aer_pista_ponto_pouso_a_geom ON edgv.aer_pista_ponto_pouso_a USING gist (geom)# -ALTER TABLE edgv.aer_pista_ponto_pouso_a OWNER TO postgres; +ALTER TABLE edgv.aer_pista_ponto_pouso_a OWNER TO postgres# ALTER TABLE edgv.aer_pista_ponto_pouso_a ADD CONSTRAINT aer_pista_ponto_pouso_a_tipopista_fk FOREIGN KEY (tipopista) REFERENCES dominios.tipo_pista (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_a ALTER COLUMN tipopista SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_a ALTER COLUMN tipopista SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_a ADD CONSTRAINT aer_pista_ponto_pouso_a_revestimento_fk FOREIGN KEY (revestimento) REFERENCES dominios.revestimento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_a ALTER COLUMN revestimento SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_a ALTER COLUMN revestimento SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_a ADD CONSTRAINT aer_pista_ponto_pouso_a_usopista_fk FOREIGN KEY (usopista) REFERENCES dominios.uso_pista (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_a ALTER COLUMN usopista SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_a ALTER COLUMN usopista SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_a ADD CONSTRAINT aer_pista_ponto_pouso_a_homologacao_fk FOREIGN KEY (homologacao) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_a ALTER COLUMN homologacao SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_a ALTER COLUMN homologacao SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_a ADD CONSTRAINT aer_pista_ponto_pouso_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.aer_pista_ponto_pouso_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.aer_pista_ponto_pouso_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.aer_pista_ponto_pouso_a ADD CONSTRAINT aer_pista_ponto_pouso_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.aer_pista_ponto_pouso_a - ADD CONSTRAINT aer_pista_ponto_pouso_a_situacaofisica_check - CHECK (situacaofisica = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.aer_pista_ponto_pouso_a ALTER COLUMN situacaofisica SET DEFAULT 9999; + ADD CONSTRAINT aer_pista_ponto_pouso_a_situacaofisica_check + CHECK (situacaofisica = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.aer_pista_ponto_pouso_a ALTER COLUMN situacaofisica SET DEFAULT 9999# + +CREATE TABLE edgv.enc_subest_transm_distrib_energia_eletrica_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + idtsub integer, + centrodecarga smallint NOT NULL, + classeativecon smallint NOT NULL, + operacional smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT enc_subest_transm_distrib_energia_eletrica_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX enc_subest_transm_distrib_energia_eletrica_p_geom ON edgv.enc_subest_transm_distrib_energia_eletrica_p USING gist (geom)# + +ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_p OWNER TO postgres# + +ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_p + ADD CONSTRAINT enc_subest_transm_distrib_energia_eletrica_p_centrodecarga_fk FOREIGN KEY (centrodecarga) + REFERENCES dominios.auxiliar (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_p ALTER COLUMN centrodecarga SET DEFAULT 9999# + +ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_p + ADD CONSTRAINT enc_subest_transm_distrib_energia_eletrica_p_classeativecon_fk FOREIGN KEY (classeativecon) + REFERENCES dominios.classe_ativ_econ (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_p + ADD CONSTRAINT enc_subest_transm_distrib_energia_eletrica_p_classeativecon_check + CHECK (classeativecon = ANY(ARRAY[2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_p ALTER COLUMN classeativecon SET DEFAULT 9999# + +ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_p + ADD CONSTRAINT enc_subest_transm_distrib_energia_eletrica_p_operacional_fk FOREIGN KEY (operacional) + REFERENCES dominios.auxiliar (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_p ALTER COLUMN operacional SET DEFAULT 9999# CREATE TABLE edgv.enc_subest_transm_distrib_energia_eletrica_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), idtsub integer, centrodecarga smallint NOT NULL, classeativecon smallint NOT NULL, operacional smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT enc_subest_transm_distrib_energia_eletrica_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_subest_transm_distrib_energia_eletrica_a_geom ON edgv.enc_subest_transm_distrib_energia_eletrica_a USING gist (geom); +)# +CREATE INDEX enc_subest_transm_distrib_energia_eletrica_a_geom ON edgv.enc_subest_transm_distrib_energia_eletrica_a USING gist (geom)# -ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_a OWNER TO postgres; +ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_a OWNER TO postgres# ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_a ADD CONSTRAINT enc_subest_transm_distrib_energia_eletrica_a_centrodecarga_fk FOREIGN KEY (centrodecarga) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_a ALTER COLUMN centrodecarga SET DEFAULT 9999; +ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_a ALTER COLUMN centrodecarga SET DEFAULT 9999# ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_a ADD CONSTRAINT enc_subest_transm_distrib_energia_eletrica_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_a - ADD CONSTRAINT enc_subest_transm_distrib_energia_eletrica_a_classeativecon_check - CHECK (classeativecon = ANY(ARRAY[2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_a ALTER COLUMN classeativecon SET DEFAULT 9999; + ADD CONSTRAINT enc_subest_transm_distrib_energia_eletrica_a_classeativecon_check + CHECK (classeativecon = ANY(ARRAY[2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_a ADD CONSTRAINT enc_subest_transm_distrib_energia_eletrica_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_subest_transm_distrib_energia_eletrica_a ALTER COLUMN operacional SET DEFAULT 9999# CREATE TABLE edgv.cbge_deposito_geral_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -2963,96 +3001,98 @@ CREATE TABLE edgv.cbge_deposito_geral_p( tratamento smallint NOT NULL, estadofisico smallint NOT NULL, finalidadedep smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT cbge_deposito_geral_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_deposito_geral_p_geom ON edgv.cbge_deposito_geral_p USING gist (geom); +)# +CREATE INDEX cbge_deposito_geral_p_geom ON edgv.cbge_deposito_geral_p USING gist (geom)# -ALTER TABLE edgv.cbge_deposito_geral_p OWNER TO postgres; +ALTER TABLE edgv.cbge_deposito_geral_p OWNER TO postgres# ALTER TABLE edgv.cbge_deposito_geral_p ADD CONSTRAINT cbge_deposito_geral_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_p ADD CONSTRAINT cbge_deposito_geral_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_p ADD CONSTRAINT cbge_deposito_geral_p_tipodepgeral_fk FOREIGN KEY (tipodepgeral) REFERENCES dominios.tipo_dep_geral (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.cbge_deposito_geral_p - ADD CONSTRAINT cbge_deposito_geral_p_tipodepgeral_check - CHECK (tipodepgeral = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 19 :: SMALLINT, 26 :: SMALLINT, 32 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN tipodepgeral SET DEFAULT 9999; + ADD CONSTRAINT cbge_deposito_geral_p_tipodepgeral_check + CHECK (tipodepgeral = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 19 :: SMALLINT, 26 :: SMALLINT, 32 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN tipodepgeral SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_p ADD CONSTRAINT cbge_deposito_geral_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_p ADD CONSTRAINT cbge_deposito_geral_p_tipoexposicao_fk FOREIGN KEY (tipoexposicao) REFERENCES dominios.tipo_exposicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN tipoexposicao SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN tipoexposicao SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_p ADD CONSTRAINT cbge_deposito_geral_p_tipoprodutoresiduo_fk FOREIGN KEY (tipoprodutoresiduo) REFERENCES dominios.tipo_produto_residuo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN tipoprodutoresiduo SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN tipoprodutoresiduo SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_p ADD CONSTRAINT cbge_deposito_geral_p_tipoconteudo_fk FOREIGN KEY (tipoconteudo) REFERENCES dominios.tipo_conteudo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN tipoconteudo SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN tipoconteudo SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_p ADD CONSTRAINT cbge_deposito_geral_p_unidadevolume_fk FOREIGN KEY (unidadevolume) REFERENCES dominios.unidade_volume (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN unidadevolume SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN unidadevolume SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_p ADD CONSTRAINT cbge_deposito_geral_p_tratamento_fk FOREIGN KEY (tratamento) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN tratamento SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN tratamento SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_p ADD CONSTRAINT cbge_deposito_geral_p_estadofisico_fk FOREIGN KEY (estadofisico) REFERENCES dominios.estado_fisico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN estadofisico SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN estadofisico SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_p ADD CONSTRAINT cbge_deposito_geral_p_finalidadedep_fk FOREIGN KEY (finalidadedep) REFERENCES dominios.finalidade_deposito (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN finalidadedep SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_p ALTER COLUMN finalidadedep SET DEFAULT 9999# CREATE TABLE edgv.cbge_deposito_geral_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -3067,253 +3107,264 @@ CREATE TABLE edgv.cbge_deposito_geral_a( tratamento smallint NOT NULL, estadofisico smallint NOT NULL, finalidadedep smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_deposito_geral_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_deposito_geral_a_geom ON edgv.cbge_deposito_geral_a USING gist (geom); +)# +CREATE INDEX cbge_deposito_geral_a_geom ON edgv.cbge_deposito_geral_a USING gist (geom)# -ALTER TABLE edgv.cbge_deposito_geral_a OWNER TO postgres; +ALTER TABLE edgv.cbge_deposito_geral_a OWNER TO postgres# ALTER TABLE edgv.cbge_deposito_geral_a ADD CONSTRAINT cbge_deposito_geral_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_a ADD CONSTRAINT cbge_deposito_geral_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_a ADD CONSTRAINT cbge_deposito_geral_a_tipodepgeral_fk FOREIGN KEY (tipodepgeral) REFERENCES dominios.tipo_dep_geral (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.cbge_deposito_geral_a - ADD CONSTRAINT cbge_deposito_geral_a_tipodepgeral_check - CHECK (tipodepgeral = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 19 :: SMALLINT, 26 :: SMALLINT, 32 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN tipodepgeral SET DEFAULT 9999; + ADD CONSTRAINT cbge_deposito_geral_a_tipodepgeral_check + CHECK (tipodepgeral = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 19 :: SMALLINT, 26 :: SMALLINT, 32 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN tipodepgeral SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_a ADD CONSTRAINT cbge_deposito_geral_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_a ADD CONSTRAINT cbge_deposito_geral_a_tipoexposicao_fk FOREIGN KEY (tipoexposicao) REFERENCES dominios.tipo_exposicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN tipoexposicao SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN tipoexposicao SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_a ADD CONSTRAINT cbge_deposito_geral_a_tipoprodutoresiduo_fk FOREIGN KEY (tipoprodutoresiduo) REFERENCES dominios.tipo_produto_residuo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN tipoprodutoresiduo SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN tipoprodutoresiduo SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_a ADD CONSTRAINT cbge_deposito_geral_a_tipoconteudo_fk FOREIGN KEY (tipoconteudo) REFERENCES dominios.tipo_conteudo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN tipoconteudo SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN tipoconteudo SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_a ADD CONSTRAINT cbge_deposito_geral_a_unidadevolume_fk FOREIGN KEY (unidadevolume) REFERENCES dominios.unidade_volume (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN unidadevolume SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN unidadevolume SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_a ADD CONSTRAINT cbge_deposito_geral_a_tratamento_fk FOREIGN KEY (tratamento) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN tratamento SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN tratamento SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_a ADD CONSTRAINT cbge_deposito_geral_a_estadofisico_fk FOREIGN KEY (estadofisico) REFERENCES dominios.estado_fisico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN estadofisico SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN estadofisico SET DEFAULT 9999# ALTER TABLE edgv.cbge_deposito_geral_a ADD CONSTRAINT cbge_deposito_geral_a_finalidadedep_fk FOREIGN KEY (finalidadedep) REFERENCES dominios.finalidade_deposito (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN finalidadedep SET DEFAULT 9999; +ALTER TABLE edgv.cbge_deposito_geral_a ALTER COLUMN finalidadedep SET DEFAULT 9999# CREATE TABLE edgv.cbge_area_agropec_ext_vegetal_pesca_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoarea smallint NOT NULL, destinadoa smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_area_agropec_ext_vegetal_pesca_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_area_agropec_ext_vegetal_pesca_a_geom ON edgv.cbge_area_agropec_ext_vegetal_pesca_a USING gist (geom); +)# +CREATE INDEX cbge_area_agropec_ext_vegetal_pesca_a_geom ON edgv.cbge_area_agropec_ext_vegetal_pesca_a USING gist (geom)# -ALTER TABLE edgv.cbge_area_agropec_ext_vegetal_pesca_a OWNER TO postgres; +ALTER TABLE edgv.cbge_area_agropec_ext_vegetal_pesca_a OWNER TO postgres# ALTER TABLE edgv.cbge_area_agropec_ext_vegetal_pesca_a ADD CONSTRAINT cbge_area_agropec_ext_vegetal_pesca_a_tipoarea_fk FOREIGN KEY (tipoarea) REFERENCES dominios.tipo_area (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.cbge_area_agropec_ext_vegetal_pesca_a - ADD CONSTRAINT cbge_area_agropec_ext_vegetal_pesca_a_tipoarea_check - CHECK (tipoarea = ANY(ARRAY[4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.cbge_area_agropec_ext_vegetal_pesca_a ALTER COLUMN tipoarea SET DEFAULT 9999; + ADD CONSTRAINT cbge_area_agropec_ext_vegetal_pesca_a_tipoarea_check + CHECK (tipoarea = ANY(ARRAY[4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.cbge_area_agropec_ext_vegetal_pesca_a ALTER COLUMN tipoarea SET DEFAULT 9999# ALTER TABLE edgv.cbge_area_agropec_ext_vegetal_pesca_a ADD CONSTRAINT cbge_area_agropec_ext_vegetal_pesca_a_destinadoa_fk FOREIGN KEY (destinadoa) REFERENCES dominios.destinado_a (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_area_agropec_ext_vegetal_pesca_a ALTER COLUMN destinadoa SET DEFAULT 9999; +ALTER TABLE edgv.cbge_area_agropec_ext_vegetal_pesca_a ALTER COLUMN destinadoa SET DEFAULT 9999# CREATE TABLE edgv.cbge_canteiro_central_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, situacaoespacial smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT cbge_canteiro_central_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_canteiro_central_l_geom ON edgv.cbge_canteiro_central_l USING gist (geom); +)# +CREATE INDEX cbge_canteiro_central_l_geom ON edgv.cbge_canteiro_central_l USING gist (geom)# -ALTER TABLE edgv.cbge_canteiro_central_l OWNER TO postgres; +ALTER TABLE edgv.cbge_canteiro_central_l OWNER TO postgres# ALTER TABLE edgv.cbge_canteiro_central_l ADD CONSTRAINT cbge_canteiro_central_l_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_canteiro_central_l ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.cbge_canteiro_central_l ALTER COLUMN situacaoespacial SET DEFAULT 9999# CREATE TABLE edgv.cbge_canteiro_central_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, situacaoespacial smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_canteiro_central_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_canteiro_central_a_geom ON edgv.cbge_canteiro_central_a USING gist (geom); +)# +CREATE INDEX cbge_canteiro_central_a_geom ON edgv.cbge_canteiro_central_a USING gist (geom)# -ALTER TABLE edgv.cbge_canteiro_central_a OWNER TO postgres; +ALTER TABLE edgv.cbge_canteiro_central_a OWNER TO postgres# ALTER TABLE edgv.cbge_canteiro_central_a ADD CONSTRAINT cbge_canteiro_central_a_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_canteiro_central_a ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.cbge_canteiro_central_a ALTER COLUMN situacaoespacial SET DEFAULT 9999# CREATE TABLE edgv.cbge_poste_p( - id serial NOT NULL, - codident varchar(80), + id uuid NOT NULL DEFAULT uuid_generate_v4(), + codident varchar(255), geometriaaproximada boolean NOT NULL, matconstr smallint NOT NULL, tipoposte smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT cbge_poste_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_poste_p_geom ON edgv.cbge_poste_p USING gist (geom); +)# +CREATE INDEX cbge_poste_p_geom ON edgv.cbge_poste_p USING gist (geom)# -ALTER TABLE edgv.cbge_poste_p OWNER TO postgres; +ALTER TABLE edgv.cbge_poste_p OWNER TO postgres# ALTER TABLE edgv.cbge_poste_p ADD CONSTRAINT cbge_poste_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_poste_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.cbge_poste_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.cbge_poste_p ADD CONSTRAINT cbge_poste_p_tipoposte_fk FOREIGN KEY (tipoposte) REFERENCES dominios.tipo_poste (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_poste_p ALTER COLUMN tipoposte SET DEFAULT 9999; +ALTER TABLE edgv.cbge_poste_p ALTER COLUMN tipoposte SET DEFAULT 9999# CREATE TABLE edgv.cbge_espelho_dagua_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), - codident varchar(80), + codident varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_espelho_dagua_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_espelho_dagua_a_geom ON edgv.cbge_espelho_dagua_a USING gist (geom); +)# +CREATE INDEX cbge_espelho_dagua_a_geom ON edgv.cbge_espelho_dagua_a USING gist (geom)# -ALTER TABLE edgv.cbge_espelho_dagua_a OWNER TO postgres; +ALTER TABLE edgv.cbge_espelho_dagua_a OWNER TO postgres# CREATE TABLE edgv.cbge_entroncamento_area_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoentroncamento smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_entroncamento_area_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_entroncamento_area_a_geom ON edgv.cbge_entroncamento_area_a USING gist (geom); +)# +CREATE INDEX cbge_entroncamento_area_a_geom ON edgv.cbge_entroncamento_area_a USING gist (geom)# -ALTER TABLE edgv.cbge_entroncamento_area_a OWNER TO postgres; +ALTER TABLE edgv.cbge_entroncamento_area_a OWNER TO postgres# ALTER TABLE edgv.cbge_entroncamento_area_a ADD CONSTRAINT cbge_entroncamento_area_a_tipoentroncamento_fk FOREIGN KEY (tipoentroncamento) REFERENCES dominios.tipo_entroncamento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_entroncamento_area_a ALTER COLUMN tipoentroncamento SET DEFAULT 9999; +ALTER TABLE edgv.cbge_entroncamento_area_a ALTER COLUMN tipoentroncamento SET DEFAULT 9999# CREATE TABLE edgv.cbge_retorno_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT cbge_retorno_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_retorno_l_geom ON edgv.cbge_retorno_l USING gist (geom); +)# +CREATE INDEX cbge_retorno_l_geom ON edgv.cbge_retorno_l USING gist (geom)# -ALTER TABLE edgv.cbge_retorno_l OWNER TO postgres; +ALTER TABLE edgv.cbge_retorno_l OWNER TO postgres# CREATE TABLE edgv.cbge_retorno_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT cbge_retorno_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_retorno_p_geom ON edgv.cbge_retorno_p USING gist (geom); +)# +CREATE INDEX cbge_retorno_p_geom ON edgv.cbge_retorno_p USING gist (geom)# -ALTER TABLE edgv.cbge_retorno_p OWNER TO postgres; +ALTER TABLE edgv.cbge_retorno_p OWNER TO postgres# CREATE TABLE edgv.cbge_trecho_arruamento_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, jurisdicao smallint NOT NULL, administracao smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), revestimento smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, @@ -3325,98 +3376,99 @@ CREATE TABLE edgv.cbge_trecho_arruamento_l( tipovia smallint NOT NULL, meiofio smallint NOT NULL, sarjeta smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT cbge_trecho_arruamento_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_trecho_arruamento_l_geom ON edgv.cbge_trecho_arruamento_l USING gist (geom); +)# +CREATE INDEX cbge_trecho_arruamento_l_geom ON edgv.cbge_trecho_arruamento_l USING gist (geom)# -ALTER TABLE edgv.cbge_trecho_arruamento_l OWNER TO postgres; +ALTER TABLE edgv.cbge_trecho_arruamento_l OWNER TO postgres# ALTER TABLE edgv.cbge_trecho_arruamento_l ADD CONSTRAINT cbge_trecho_arruamento_l_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_l ADD CONSTRAINT cbge_trecho_arruamento_l_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_l ADD CONSTRAINT cbge_trecho_arruamento_l_revestimento_fk FOREIGN KEY (revestimento) REFERENCES dominios.revestimento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN revestimento SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN revestimento SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_l ADD CONSTRAINT cbge_trecho_arruamento_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_l ADD CONSTRAINT cbge_trecho_arruamento_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_l ADD CONSTRAINT cbge_trecho_arruamento_l_canteirodivisorio_fk FOREIGN KEY (canteirodivisorio) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN canteirodivisorio SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN canteirodivisorio SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_l ADD CONSTRAINT cbge_trecho_arruamento_l_trafego_fk FOREIGN KEY (trafego) REFERENCES dominios.trafego (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN trafego SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN trafego SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_l ADD CONSTRAINT cbge_trecho_arruamento_l_tipopavimentacao_fk FOREIGN KEY (tipopavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN tipopavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN tipopavimentacao SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_l ADD CONSTRAINT cbge_trecho_arruamento_l_tipovia_fk FOREIGN KEY (tipovia) REFERENCES dominios.tipo_via (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN tipovia SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN tipovia SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_l ADD CONSTRAINT cbge_trecho_arruamento_l_meiofio_fk FOREIGN KEY (meiofio) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN meiofio SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN meiofio SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_l ADD CONSTRAINT cbge_trecho_arruamento_l_sarjeta_fk FOREIGN KEY (sarjeta) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN sarjeta SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_l ALTER COLUMN sarjeta SET DEFAULT 9999# CREATE TABLE edgv.cbge_trecho_arruamento_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, jurisdicao smallint NOT NULL, administracao smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), revestimento smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, @@ -3428,236 +3480,243 @@ CREATE TABLE edgv.cbge_trecho_arruamento_a( tipovia smallint NOT NULL, meiofio smallint NOT NULL, sarjeta smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_trecho_arruamento_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_trecho_arruamento_a_geom ON edgv.cbge_trecho_arruamento_a USING gist (geom); +)# +CREATE INDEX cbge_trecho_arruamento_a_geom ON edgv.cbge_trecho_arruamento_a USING gist (geom)# -ALTER TABLE edgv.cbge_trecho_arruamento_a OWNER TO postgres; +ALTER TABLE edgv.cbge_trecho_arruamento_a OWNER TO postgres# ALTER TABLE edgv.cbge_trecho_arruamento_a ADD CONSTRAINT cbge_trecho_arruamento_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_a ADD CONSTRAINT cbge_trecho_arruamento_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_a ADD CONSTRAINT cbge_trecho_arruamento_a_revestimento_fk FOREIGN KEY (revestimento) REFERENCES dominios.revestimento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN revestimento SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN revestimento SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_a ADD CONSTRAINT cbge_trecho_arruamento_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_a ADD CONSTRAINT cbge_trecho_arruamento_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_a ADD CONSTRAINT cbge_trecho_arruamento_a_canteirodivisorio_fk FOREIGN KEY (canteirodivisorio) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN canteirodivisorio SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN canteirodivisorio SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_a ADD CONSTRAINT cbge_trecho_arruamento_a_trafego_fk FOREIGN KEY (trafego) REFERENCES dominios.trafego (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN trafego SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN trafego SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_a ADD CONSTRAINT cbge_trecho_arruamento_a_tipopavimentacao_fk FOREIGN KEY (tipopavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN tipopavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN tipopavimentacao SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_a ADD CONSTRAINT cbge_trecho_arruamento_a_tipovia_fk FOREIGN KEY (tipovia) REFERENCES dominios.tipo_via (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN tipovia SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN tipovia SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_a ADD CONSTRAINT cbge_trecho_arruamento_a_meiofio_fk FOREIGN KEY (meiofio) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN meiofio SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN meiofio SET DEFAULT 9999# ALTER TABLE edgv.cbge_trecho_arruamento_a ADD CONSTRAINT cbge_trecho_arruamento_a_sarjeta_fk FOREIGN KEY (sarjeta) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN sarjeta SET DEFAULT 9999; +ALTER TABLE edgv.cbge_trecho_arruamento_a ALTER COLUMN sarjeta SET DEFAULT 9999# CREATE TABLE edgv.cbge_cemiterio_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipocemiterio smallint NOT NULL, denominacaoassociada smallint NOT NULL, destinacaocemiterio smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT cbge_cemiterio_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_cemiterio_p_geom ON edgv.cbge_cemiterio_p USING gist (geom); +)# +CREATE INDEX cbge_cemiterio_p_geom ON edgv.cbge_cemiterio_p USING gist (geom)# -ALTER TABLE edgv.cbge_cemiterio_p OWNER TO postgres; +ALTER TABLE edgv.cbge_cemiterio_p OWNER TO postgres# ALTER TABLE edgv.cbge_cemiterio_p ADD CONSTRAINT cbge_cemiterio_p_tipocemiterio_fk FOREIGN KEY (tipocemiterio) REFERENCES dominios.tipo_cemiterio (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_cemiterio_p ALTER COLUMN tipocemiterio SET DEFAULT 9999; +ALTER TABLE edgv.cbge_cemiterio_p ALTER COLUMN tipocemiterio SET DEFAULT 9999# ALTER TABLE edgv.cbge_cemiterio_p ADD CONSTRAINT cbge_cemiterio_p_denominacaoassociada_fk FOREIGN KEY (denominacaoassociada) REFERENCES dominios.denominacao_associada (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_cemiterio_p ALTER COLUMN denominacaoassociada SET DEFAULT 9999; +ALTER TABLE edgv.cbge_cemiterio_p ALTER COLUMN denominacaoassociada SET DEFAULT 9999# ALTER TABLE edgv.cbge_cemiterio_p ADD CONSTRAINT cbge_cemiterio_p_destinacaocemiterio_fk FOREIGN KEY (destinacaocemiterio) REFERENCES dominios.destinacao_cemiterio (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_cemiterio_p ALTER COLUMN destinacaocemiterio SET DEFAULT 9999; +ALTER TABLE edgv.cbge_cemiterio_p ALTER COLUMN destinacaocemiterio SET DEFAULT 9999# CREATE TABLE edgv.cbge_cemiterio_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipocemiterio smallint NOT NULL, denominacaoassociada smallint NOT NULL, destinacaocemiterio smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_cemiterio_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_cemiterio_a_geom ON edgv.cbge_cemiterio_a USING gist (geom); +)# +CREATE INDEX cbge_cemiterio_a_geom ON edgv.cbge_cemiterio_a USING gist (geom)# -ALTER TABLE edgv.cbge_cemiterio_a OWNER TO postgres; +ALTER TABLE edgv.cbge_cemiterio_a OWNER TO postgres# ALTER TABLE edgv.cbge_cemiterio_a ADD CONSTRAINT cbge_cemiterio_a_tipocemiterio_fk FOREIGN KEY (tipocemiterio) REFERENCES dominios.tipo_cemiterio (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_cemiterio_a ALTER COLUMN tipocemiterio SET DEFAULT 9999; +ALTER TABLE edgv.cbge_cemiterio_a ALTER COLUMN tipocemiterio SET DEFAULT 9999# ALTER TABLE edgv.cbge_cemiterio_a ADD CONSTRAINT cbge_cemiterio_a_denominacaoassociada_fk FOREIGN KEY (denominacaoassociada) REFERENCES dominios.denominacao_associada (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_cemiterio_a ALTER COLUMN denominacaoassociada SET DEFAULT 9999; +ALTER TABLE edgv.cbge_cemiterio_a ALTER COLUMN denominacaoassociada SET DEFAULT 9999# ALTER TABLE edgv.cbge_cemiterio_a ADD CONSTRAINT cbge_cemiterio_a_destinacaocemiterio_fk FOREIGN KEY (destinacaocemiterio) REFERENCES dominios.destinacao_cemiterio (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_cemiterio_a ALTER COLUMN destinacaocemiterio SET DEFAULT 9999; +ALTER TABLE edgv.cbge_cemiterio_a ALTER COLUMN destinacaocemiterio SET DEFAULT 9999# CREATE TABLE edgv.cbge_delimitacao_fisica_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipodelimfis smallint NOT NULL, matconstr smallint NOT NULL, eletrificada smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT cbge_delimitacao_fisica_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_delimitacao_fisica_l_geom ON edgv.cbge_delimitacao_fisica_l USING gist (geom); +)# +CREATE INDEX cbge_delimitacao_fisica_l_geom ON edgv.cbge_delimitacao_fisica_l USING gist (geom)# -ALTER TABLE edgv.cbge_delimitacao_fisica_l OWNER TO postgres; +ALTER TABLE edgv.cbge_delimitacao_fisica_l OWNER TO postgres# ALTER TABLE edgv.cbge_delimitacao_fisica_l ADD CONSTRAINT cbge_delimitacao_fisica_l_tipodelimfis_fk FOREIGN KEY (tipodelimfis) REFERENCES dominios.tipo_delim_fis (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_delimitacao_fisica_l ALTER COLUMN tipodelimfis SET DEFAULT 9999; +ALTER TABLE edgv.cbge_delimitacao_fisica_l ALTER COLUMN tipodelimfis SET DEFAULT 9999# ALTER TABLE edgv.cbge_delimitacao_fisica_l ADD CONSTRAINT cbge_delimitacao_fisica_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_delimitacao_fisica_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.cbge_delimitacao_fisica_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.cbge_delimitacao_fisica_l ADD CONSTRAINT cbge_delimitacao_fisica_l_eletrificada_fk FOREIGN KEY (eletrificada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_delimitacao_fisica_l ALTER COLUMN eletrificada SET DEFAULT 9999; +ALTER TABLE edgv.cbge_delimitacao_fisica_l ALTER COLUMN eletrificada SET DEFAULT 9999# CREATE TABLE edgv.cbge_area_construida_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_area_construida_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_area_construida_a_geom ON edgv.cbge_area_construida_a USING gist (geom); +)# +CREATE INDEX cbge_area_construida_a_geom ON edgv.cbge_area_construida_a USING gist (geom)# -ALTER TABLE edgv.cbge_area_construida_a OWNER TO postgres; +ALTER TABLE edgv.cbge_area_construida_a OWNER TO postgres# CREATE TABLE edgv.cbge_area_habitacional_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoarea smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_area_habitacional_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_area_habitacional_a_geom ON edgv.cbge_area_habitacional_a USING gist (geom); +)# +CREATE INDEX cbge_area_habitacional_a_geom ON edgv.cbge_area_habitacional_a USING gist (geom)# -ALTER TABLE edgv.cbge_area_habitacional_a OWNER TO postgres; +ALTER TABLE edgv.cbge_area_habitacional_a OWNER TO postgres# ALTER TABLE edgv.cbge_area_habitacional_a ADD CONSTRAINT cbge_area_habitacional_a_tipoarea_fk FOREIGN KEY (tipoarea) REFERENCES dominios.tipo_area (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.cbge_area_habitacional_a - ADD CONSTRAINT cbge_area_habitacional_a_tipoarea_check - CHECK (tipoarea = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.cbge_area_habitacional_a ALTER COLUMN tipoarea SET DEFAULT 9999; + ADD CONSTRAINT cbge_area_habitacional_a_tipoarea_check + CHECK (tipoarea = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.cbge_area_habitacional_a ALTER COLUMN tipoarea SET DEFAULT 9999# CREATE TABLE edgv.cbge_estacionamento_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, modaluso smallint NOT NULL, @@ -3666,249 +3725,263 @@ CREATE TABLE edgv.cbge_estacionamento_a( situacaofisica smallint NOT NULL, finalidadepatio smallint NOT NULL, publico smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_estacionamento_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_estacionamento_a_geom ON edgv.cbge_estacionamento_a USING gist (geom); +)# +CREATE INDEX cbge_estacionamento_a_geom ON edgv.cbge_estacionamento_a USING gist (geom)# -ALTER TABLE edgv.cbge_estacionamento_a OWNER TO postgres; +ALTER TABLE edgv.cbge_estacionamento_a OWNER TO postgres# ALTER TABLE edgv.cbge_estacionamento_a ADD CONSTRAINT cbge_estacionamento_a_modaluso_fk FOREIGN KEY (modaluso) REFERENCES dominios.modal_uso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.cbge_estacionamento_a - ADD CONSTRAINT cbge_estacionamento_a_modaluso_check - CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.cbge_estacionamento_a ALTER COLUMN modaluso SET DEFAULT 9999; + ADD CONSTRAINT cbge_estacionamento_a_modaluso_check + CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.cbge_estacionamento_a ALTER COLUMN modaluso SET DEFAULT 9999# ALTER TABLE edgv.cbge_estacionamento_a ADD CONSTRAINT cbge_estacionamento_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_estacionamento_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.cbge_estacionamento_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.cbge_estacionamento_a ADD CONSTRAINT cbge_estacionamento_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_estacionamento_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.cbge_estacionamento_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.cbge_estacionamento_a ADD CONSTRAINT cbge_estacionamento_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_estacionamento_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.cbge_estacionamento_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.cbge_estacionamento_a ADD CONSTRAINT cbge_estacionamento_a_finalidadepatio_fk FOREIGN KEY (finalidadepatio) REFERENCES dominios.finalidade_patio (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.cbge_estacionamento_a - ADD CONSTRAINT cbge_estacionamento_a_finalidadepatio_check - CHECK (finalidadepatio = ANY(ARRAY[3 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.cbge_estacionamento_a ALTER COLUMN finalidadepatio SET DEFAULT 9999; + ADD CONSTRAINT cbge_estacionamento_a_finalidadepatio_check + CHECK (finalidadepatio = ANY(ARRAY[3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.cbge_estacionamento_a ALTER COLUMN finalidadepatio SET DEFAULT 9999# ALTER TABLE edgv.cbge_estacionamento_a ADD CONSTRAINT cbge_estacionamento_a_publico_fk FOREIGN KEY (publico) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_estacionamento_a ALTER COLUMN publico SET DEFAULT 9999; +ALTER TABLE edgv.cbge_estacionamento_a ALTER COLUMN publico SET DEFAULT 9999# CREATE TABLE edgv.cbge_praca_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, turistica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_praca_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_praca_a_geom ON edgv.cbge_praca_a USING gist (geom); +)# +CREATE INDEX cbge_praca_a_geom ON edgv.cbge_praca_a USING gist (geom)# -ALTER TABLE edgv.cbge_praca_a OWNER TO postgres; +ALTER TABLE edgv.cbge_praca_a OWNER TO postgres# ALTER TABLE edgv.cbge_praca_a ADD CONSTRAINT cbge_praca_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_praca_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.cbge_praca_a ALTER COLUMN turistica SET DEFAULT 9999# CREATE TABLE edgv.cbge_area_duto_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoarea smallint NOT NULL, areavalvulas smallint NOT NULL, bombeamento smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_area_duto_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_area_duto_a_geom ON edgv.cbge_area_duto_a USING gist (geom); +)# +CREATE INDEX cbge_area_duto_a_geom ON edgv.cbge_area_duto_a USING gist (geom)# -ALTER TABLE edgv.cbge_area_duto_a OWNER TO postgres; +ALTER TABLE edgv.cbge_area_duto_a OWNER TO postgres# ALTER TABLE edgv.cbge_area_duto_a ADD CONSTRAINT cbge_area_duto_a_tipoarea_fk FOREIGN KEY (tipoarea) REFERENCES dominios.tipo_area (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.cbge_area_duto_a - ADD CONSTRAINT cbge_area_duto_a_tipoarea_check - CHECK (tipoarea = ANY(ARRAY[3 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.cbge_area_duto_a ALTER COLUMN tipoarea SET DEFAULT 9999; + ADD CONSTRAINT cbge_area_duto_a_tipoarea_check + CHECK (tipoarea = ANY(ARRAY[3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.cbge_area_duto_a ALTER COLUMN tipoarea SET DEFAULT 9999# ALTER TABLE edgv.cbge_area_duto_a ADD CONSTRAINT cbge_area_duto_a_areavalvulas_fk FOREIGN KEY (areavalvulas) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_area_duto_a ALTER COLUMN areavalvulas SET DEFAULT 9999; +ALTER TABLE edgv.cbge_area_duto_a ALTER COLUMN areavalvulas SET DEFAULT 9999# ALTER TABLE edgv.cbge_area_duto_a ADD CONSTRAINT cbge_area_duto_a_bombeamento_fk FOREIGN KEY (bombeamento) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_area_duto_a ALTER COLUMN bombeamento SET DEFAULT 9999; +ALTER TABLE edgv.cbge_area_duto_a ALTER COLUMN bombeamento SET DEFAULT 9999# CREATE TABLE edgv.cbge_area_de_propriedade_particular_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoarea smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_area_de_propriedade_particular_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_area_de_propriedade_particular_a_geom ON edgv.cbge_area_de_propriedade_particular_a USING gist (geom); +)# +CREATE INDEX cbge_area_de_propriedade_particular_a_geom ON edgv.cbge_area_de_propriedade_particular_a USING gist (geom)# -ALTER TABLE edgv.cbge_area_de_propriedade_particular_a OWNER TO postgres; +ALTER TABLE edgv.cbge_area_de_propriedade_particular_a OWNER TO postgres# ALTER TABLE edgv.cbge_area_de_propriedade_particular_a ADD CONSTRAINT cbge_area_de_propriedade_particular_a_tipoarea_fk FOREIGN KEY (tipoarea) REFERENCES dominios.tipo_area (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.cbge_area_de_propriedade_particular_a - ADD CONSTRAINT cbge_area_de_propriedade_particular_a_tipoarea_check - CHECK (tipoarea = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.cbge_area_de_propriedade_particular_a ALTER COLUMN tipoarea SET DEFAULT 9999; + ADD CONSTRAINT cbge_area_de_propriedade_particular_a_tipoarea_check + CHECK (tipoarea = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.cbge_area_de_propriedade_particular_a ALTER COLUMN tipoarea SET DEFAULT 9999# CREATE TABLE edgv.cbge_quadra_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_quadra_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_quadra_a_geom ON edgv.cbge_quadra_a USING gist (geom); +)# +CREATE INDEX cbge_quadra_a_geom ON edgv.cbge_quadra_a USING gist (geom)# -ALTER TABLE edgv.cbge_quadra_a OWNER TO postgres; +ALTER TABLE edgv.cbge_quadra_a OWNER TO postgres# CREATE TABLE edgv.cbge_area_uso_especifico_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoarea smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_area_uso_especifico_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_area_uso_especifico_a_geom ON edgv.cbge_area_uso_especifico_a USING gist (geom); +)# +CREATE INDEX cbge_area_uso_especifico_a_geom ON edgv.cbge_area_uso_especifico_a USING gist (geom)# -ALTER TABLE edgv.cbge_area_uso_especifico_a OWNER TO postgres; +ALTER TABLE edgv.cbge_area_uso_especifico_a OWNER TO postgres# ALTER TABLE edgv.cbge_area_uso_especifico_a ADD CONSTRAINT cbge_area_uso_especifico_a_tipoarea_fk FOREIGN KEY (tipoarea) REFERENCES dominios.tipo_area (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.cbge_area_uso_especifico_a - ADD CONSTRAINT cbge_area_uso_especifico_a_tipoarea_check - CHECK (tipoarea = ANY(ARRAY[0 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 15 :: SMALLINT, 16 :: SMALLINT, 17 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.cbge_area_uso_especifico_a ALTER COLUMN tipoarea SET DEFAULT 9999; + ADD CONSTRAINT cbge_area_uso_especifico_a_tipoarea_check + CHECK (tipoarea = ANY(ARRAY[0 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 15 :: SMALLINT, 16 :: SMALLINT, 17 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.cbge_area_uso_especifico_a ALTER COLUMN tipoarea SET DEFAULT 9999# CREATE TABLE edgv.cbge_passeio_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, largura real, calcada smallint NOT NULL, pavimentacao smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT cbge_passeio_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_passeio_l_geom ON edgv.cbge_passeio_l USING gist (geom); +)# +CREATE INDEX cbge_passeio_l_geom ON edgv.cbge_passeio_l USING gist (geom)# -ALTER TABLE edgv.cbge_passeio_l OWNER TO postgres; +ALTER TABLE edgv.cbge_passeio_l OWNER TO postgres# ALTER TABLE edgv.cbge_passeio_l ADD CONSTRAINT cbge_passeio_l_calcada_fk FOREIGN KEY (calcada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_passeio_l ALTER COLUMN calcada SET DEFAULT 9999; +ALTER TABLE edgv.cbge_passeio_l ALTER COLUMN calcada SET DEFAULT 9999# ALTER TABLE edgv.cbge_passeio_l ADD CONSTRAINT cbge_passeio_l_pavimentacao_fk FOREIGN KEY (pavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_passeio_l ALTER COLUMN pavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.cbge_passeio_l ALTER COLUMN pavimentacao SET DEFAULT 9999# CREATE TABLE edgv.cbge_passeio_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, largura real, calcada smallint NOT NULL, pavimentacao smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_passeio_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_passeio_a_geom ON edgv.cbge_passeio_a USING gist (geom); +)# +CREATE INDEX cbge_passeio_a_geom ON edgv.cbge_passeio_a USING gist (geom)# -ALTER TABLE edgv.cbge_passeio_a OWNER TO postgres; +ALTER TABLE edgv.cbge_passeio_a OWNER TO postgres# ALTER TABLE edgv.cbge_passeio_a ADD CONSTRAINT cbge_passeio_a_calcada_fk FOREIGN KEY (calcada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_passeio_a ALTER COLUMN calcada SET DEFAULT 9999; +ALTER TABLE edgv.cbge_passeio_a ALTER COLUMN calcada SET DEFAULT 9999# ALTER TABLE edgv.cbge_passeio_a ADD CONSTRAINT cbge_passeio_a_pavimentacao_fk FOREIGN KEY (pavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.cbge_passeio_a ALTER COLUMN pavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.cbge_passeio_a ALTER COLUMN pavimentacao SET DEFAULT 9999# CREATE TABLE edgv.cbge_largo_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT cbge_largo_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX cbge_largo_a_geom ON edgv.cbge_largo_a USING gist (geom); +)# +CREATE INDEX cbge_largo_a_geom ON edgv.cbge_largo_a USING gist (geom)# -ALTER TABLE edgv.cbge_largo_a OWNER TO postgres; +ALTER TABLE edgv.cbge_largo_a OWNER TO postgres# CREATE TABLE edgv.dut_galeria_bueiro_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipotrechoduto smallint NOT NULL, @@ -3923,85 +3996,88 @@ CREATE TABLE edgv.dut_galeria_bueiro_l( finalidade smallint NOT NULL, pesosuportmaximo real, largura real, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT dut_galeria_bueiro_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX dut_galeria_bueiro_l_geom ON edgv.dut_galeria_bueiro_l USING gist (geom); +)# +CREATE INDEX dut_galeria_bueiro_l_geom ON edgv.dut_galeria_bueiro_l USING gist (geom)# -ALTER TABLE edgv.dut_galeria_bueiro_l OWNER TO postgres; +ALTER TABLE edgv.dut_galeria_bueiro_l OWNER TO postgres# ALTER TABLE edgv.dut_galeria_bueiro_l ADD CONSTRAINT dut_galeria_bueiro_l_tipotrechoduto_fk FOREIGN KEY (tipotrechoduto) REFERENCES dominios.tipo_trecho_duto (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.dut_galeria_bueiro_l - ADD CONSTRAINT dut_galeria_bueiro_l_tipotrechoduto_check - CHECK (tipotrechoduto = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN tipotrechoduto SET DEFAULT 9999; + ADD CONSTRAINT dut_galeria_bueiro_l_tipotrechoduto_check + CHECK (tipotrechoduto = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN tipotrechoduto SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_l ADD CONSTRAINT dut_galeria_bueiro_l_mattransp_fk FOREIGN KEY (mattransp) REFERENCES dominios.mat_transp (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN mattransp SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN mattransp SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_l ADD CONSTRAINT dut_galeria_bueiro_l_setor_fk FOREIGN KEY (setor) REFERENCES dominios.setor (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.dut_galeria_bueiro_l - ADD CONSTRAINT dut_galeria_bueiro_l_setor_check - CHECK (setor = ANY(ARRAY[0 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN setor SET DEFAULT 9999; + ADD CONSTRAINT dut_galeria_bueiro_l_setor_check + CHECK (setor = ANY(ARRAY[0 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN setor SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_l ADD CONSTRAINT dut_galeria_bueiro_l_posicaorelativa_fk FOREIGN KEY (posicaorelativa) REFERENCES dominios.posicao_relativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN posicaorelativa SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN posicaorelativa SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_l ADD CONSTRAINT dut_galeria_bueiro_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_l ADD CONSTRAINT dut_galeria_bueiro_l_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN situacaoespacial SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_l ADD CONSTRAINT dut_galeria_bueiro_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_l ADD CONSTRAINT dut_galeria_bueiro_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_l ADD CONSTRAINT dut_galeria_bueiro_l_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade_galeria_bueiro (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN finalidade SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_l ALTER COLUMN finalidade SET DEFAULT 9999# CREATE TABLE edgv.dut_galeria_bueiro_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipotrechoduto smallint NOT NULL, @@ -4016,85 +4092,88 @@ CREATE TABLE edgv.dut_galeria_bueiro_p( finalidade smallint NOT NULL, pesosuportmaximo real, largura real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT dut_galeria_bueiro_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX dut_galeria_bueiro_p_geom ON edgv.dut_galeria_bueiro_p USING gist (geom); +)# +CREATE INDEX dut_galeria_bueiro_p_geom ON edgv.dut_galeria_bueiro_p USING gist (geom)# -ALTER TABLE edgv.dut_galeria_bueiro_p OWNER TO postgres; +ALTER TABLE edgv.dut_galeria_bueiro_p OWNER TO postgres# ALTER TABLE edgv.dut_galeria_bueiro_p ADD CONSTRAINT dut_galeria_bueiro_p_tipotrechoduto_fk FOREIGN KEY (tipotrechoduto) REFERENCES dominios.tipo_trecho_duto (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.dut_galeria_bueiro_p - ADD CONSTRAINT dut_galeria_bueiro_p_tipotrechoduto_check - CHECK (tipotrechoduto = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN tipotrechoduto SET DEFAULT 9999; + ADD CONSTRAINT dut_galeria_bueiro_p_tipotrechoduto_check + CHECK (tipotrechoduto = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN tipotrechoduto SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_p ADD CONSTRAINT dut_galeria_bueiro_p_mattransp_fk FOREIGN KEY (mattransp) REFERENCES dominios.mat_transp (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN mattransp SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN mattransp SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_p ADD CONSTRAINT dut_galeria_bueiro_p_setor_fk FOREIGN KEY (setor) REFERENCES dominios.setor (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.dut_galeria_bueiro_p - ADD CONSTRAINT dut_galeria_bueiro_p_setor_check - CHECK (setor = ANY(ARRAY[0 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN setor SET DEFAULT 9999; + ADD CONSTRAINT dut_galeria_bueiro_p_setor_check + CHECK (setor = ANY(ARRAY[0 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN setor SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_p ADD CONSTRAINT dut_galeria_bueiro_p_posicaorelativa_fk FOREIGN KEY (posicaorelativa) REFERENCES dominios.posicao_relativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN posicaorelativa SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN posicaorelativa SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_p ADD CONSTRAINT dut_galeria_bueiro_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_p ADD CONSTRAINT dut_galeria_bueiro_p_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN situacaoespacial SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_p ADD CONSTRAINT dut_galeria_bueiro_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_p ADD CONSTRAINT dut_galeria_bueiro_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.dut_galeria_bueiro_p ADD CONSTRAINT dut_galeria_bueiro_p_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade_galeria_bueiro (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN finalidade SET DEFAULT 9999; +ALTER TABLE edgv.dut_galeria_bueiro_p ALTER COLUMN finalidade SET DEFAULT 9999# CREATE TABLE edgv.dut_trecho_duto_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipotrechoduto smallint NOT NULL, @@ -4106,207 +4185,212 @@ CREATE TABLE edgv.dut_trecho_duto_l( situacaoespacial smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT dut_trecho_duto_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX dut_trecho_duto_l_geom ON edgv.dut_trecho_duto_l USING gist (geom); +)# +CREATE INDEX dut_trecho_duto_l_geom ON edgv.dut_trecho_duto_l USING gist (geom)# -ALTER TABLE edgv.dut_trecho_duto_l OWNER TO postgres; +ALTER TABLE edgv.dut_trecho_duto_l OWNER TO postgres# ALTER TABLE edgv.dut_trecho_duto_l ADD CONSTRAINT dut_trecho_duto_l_tipotrechoduto_fk FOREIGN KEY (tipotrechoduto) REFERENCES dominios.tipo_trecho_duto (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.dut_trecho_duto_l - ADD CONSTRAINT dut_trecho_duto_l_tipotrechoduto_check - CHECK (tipotrechoduto = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN tipotrechoduto SET DEFAULT 9999; + ADD CONSTRAINT dut_trecho_duto_l_tipotrechoduto_check + CHECK (tipotrechoduto = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN tipotrechoduto SET DEFAULT 9999# ALTER TABLE edgv.dut_trecho_duto_l ADD CONSTRAINT dut_trecho_duto_l_mattransp_fk FOREIGN KEY (mattransp) REFERENCES dominios.mat_transp (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN mattransp SET DEFAULT 9999; +ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN mattransp SET DEFAULT 9999# ALTER TABLE edgv.dut_trecho_duto_l ADD CONSTRAINT dut_trecho_duto_l_setor_fk FOREIGN KEY (setor) REFERENCES dominios.setor (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN setor SET DEFAULT 9999; +ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN setor SET DEFAULT 9999# ALTER TABLE edgv.dut_trecho_duto_l ADD CONSTRAINT dut_trecho_duto_l_posicaorelativa_fk FOREIGN KEY (posicaorelativa) REFERENCES dominios.posicao_relativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN posicaorelativa SET DEFAULT 9999; +ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN posicaorelativa SET DEFAULT 9999# ALTER TABLE edgv.dut_trecho_duto_l ADD CONSTRAINT dut_trecho_duto_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.dut_trecho_duto_l ADD CONSTRAINT dut_trecho_duto_l_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN situacaoespacial SET DEFAULT 9999# ALTER TABLE edgv.dut_trecho_duto_l ADD CONSTRAINT dut_trecho_duto_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.dut_trecho_duto_l ADD CONSTRAINT dut_trecho_duto_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.dut_trecho_duto_l ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.eco_equip_agropec_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, tipoequipagropec smallint NOT NULL, matconstr smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT eco_equip_agropec_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX eco_equip_agropec_l_geom ON edgv.eco_equip_agropec_l USING gist (geom); +)# +CREATE INDEX eco_equip_agropec_l_geom ON edgv.eco_equip_agropec_l USING gist (geom)# -ALTER TABLE edgv.eco_equip_agropec_l OWNER TO postgres; +ALTER TABLE edgv.eco_equip_agropec_l OWNER TO postgres# ALTER TABLE edgv.eco_equip_agropec_l ADD CONSTRAINT eco_equip_agropec_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_equip_agropec_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.eco_equip_agropec_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.eco_equip_agropec_l ADD CONSTRAINT eco_equip_agropec_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_equip_agropec_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.eco_equip_agropec_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.eco_equip_agropec_l ADD CONSTRAINT eco_equip_agropec_l_tipoequipagropec_fk FOREIGN KEY (tipoequipagropec) REFERENCES dominios.tipo_equip_agropec (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_equip_agropec_l ALTER COLUMN tipoequipagropec SET DEFAULT 9999; +ALTER TABLE edgv.eco_equip_agropec_l ALTER COLUMN tipoequipagropec SET DEFAULT 9999# ALTER TABLE edgv.eco_equip_agropec_l ADD CONSTRAINT eco_equip_agropec_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_equip_agropec_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.eco_equip_agropec_l ALTER COLUMN matconstr SET DEFAULT 9999# CREATE TABLE edgv.eco_equip_agropec_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, tipoequipagropec smallint NOT NULL, matconstr smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT eco_equip_agropec_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX eco_equip_agropec_p_geom ON edgv.eco_equip_agropec_p USING gist (geom); +)# +CREATE INDEX eco_equip_agropec_p_geom ON edgv.eco_equip_agropec_p USING gist (geom)# -ALTER TABLE edgv.eco_equip_agropec_p OWNER TO postgres; +ALTER TABLE edgv.eco_equip_agropec_p OWNER TO postgres# ALTER TABLE edgv.eco_equip_agropec_p ADD CONSTRAINT eco_equip_agropec_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_equip_agropec_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.eco_equip_agropec_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.eco_equip_agropec_p ADD CONSTRAINT eco_equip_agropec_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_equip_agropec_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.eco_equip_agropec_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.eco_equip_agropec_p ADD CONSTRAINT eco_equip_agropec_p_tipoequipagropec_fk FOREIGN KEY (tipoequipagropec) REFERENCES dominios.tipo_equip_agropec (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_equip_agropec_p ALTER COLUMN tipoequipagropec SET DEFAULT 9999; +ALTER TABLE edgv.eco_equip_agropec_p ALTER COLUMN tipoequipagropec SET DEFAULT 9999# ALTER TABLE edgv.eco_equip_agropec_p ADD CONSTRAINT eco_equip_agropec_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_equip_agropec_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.eco_equip_agropec_p ALTER COLUMN matconstr SET DEFAULT 9999# CREATE TABLE edgv.eco_equip_agropec_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, tipoequipagropec smallint NOT NULL, matconstr smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT eco_equip_agropec_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX eco_equip_agropec_a_geom ON edgv.eco_equip_agropec_a USING gist (geom); +)# +CREATE INDEX eco_equip_agropec_a_geom ON edgv.eco_equip_agropec_a USING gist (geom)# -ALTER TABLE edgv.eco_equip_agropec_a OWNER TO postgres; +ALTER TABLE edgv.eco_equip_agropec_a OWNER TO postgres# ALTER TABLE edgv.eco_equip_agropec_a ADD CONSTRAINT eco_equip_agropec_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_equip_agropec_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.eco_equip_agropec_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.eco_equip_agropec_a ADD CONSTRAINT eco_equip_agropec_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_equip_agropec_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.eco_equip_agropec_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.eco_equip_agropec_a ADD CONSTRAINT eco_equip_agropec_a_tipoequipagropec_fk FOREIGN KEY (tipoequipagropec) REFERENCES dominios.tipo_equip_agropec (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_equip_agropec_a ALTER COLUMN tipoequipagropec SET DEFAULT 9999; +ALTER TABLE edgv.eco_equip_agropec_a ALTER COLUMN tipoequipagropec SET DEFAULT 9999# ALTER TABLE edgv.eco_equip_agropec_a ADD CONSTRAINT eco_equip_agropec_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_equip_agropec_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.eco_equip_agropec_a ALTER COLUMN matconstr SET DEFAULT 9999# CREATE TABLE edgv.eco_ext_mineral_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, @@ -4319,92 +4403,95 @@ CREATE TABLE edgv.eco_ext_mineral_p( procextracao smallint NOT NULL, formaextracao smallint NOT NULL, atividade smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT eco_ext_mineral_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX eco_ext_mineral_p_geom ON edgv.eco_ext_mineral_p USING gist (geom); +)# +CREATE INDEX eco_ext_mineral_p_geom ON edgv.eco_ext_mineral_p USING gist (geom)# -ALTER TABLE edgv.eco_ext_mineral_p OWNER TO postgres; +ALTER TABLE edgv.eco_ext_mineral_p OWNER TO postgres# ALTER TABLE edgv.eco_ext_mineral_p ADD CONSTRAINT eco_ext_mineral_p_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.eco_ext_mineral_p - ADD CONSTRAINT eco_ext_mineral_p_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[32 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT eco_ext_mineral_p_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[32 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN tipoalterantrop SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_p ADD CONSTRAINT eco_ext_mineral_p_secaoativecon_fk FOREIGN KEY (secaoativecon) REFERENCES dominios.secao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.eco_ext_mineral_p - ADD CONSTRAINT eco_ext_mineral_p_secaoativecon_check - CHECK (secaoativecon = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN secaoativecon SET DEFAULT 9999; + ADD CONSTRAINT eco_ext_mineral_p_secaoativecon_check + CHECK (secaoativecon = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN secaoativecon SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_p ADD CONSTRAINT eco_ext_mineral_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_p ADD CONSTRAINT eco_ext_mineral_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_p ADD CONSTRAINT eco_ext_mineral_p_tipoextmin_fk FOREIGN KEY (tipoextmin) REFERENCES dominios.tipo_ext_min (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN tipoextmin SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN tipoextmin SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_p ADD CONSTRAINT eco_ext_mineral_p_tipoproduto_fk FOREIGN KEY (tipoproduto) REFERENCES dominios.tipo_produto_residuo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN tipoproduto SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN tipoproduto SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_p ADD CONSTRAINT eco_ext_mineral_p_tipopocomina_fk FOREIGN KEY (tipopocomina) REFERENCES dominios.tipo_poco_mina (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN tipopocomina SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN tipopocomina SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_p ADD CONSTRAINT eco_ext_mineral_p_procextracao_fk FOREIGN KEY (procextracao) REFERENCES dominios.proc_extracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN procextracao SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN procextracao SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_p ADD CONSTRAINT eco_ext_mineral_p_formaextracao_fk FOREIGN KEY (formaextracao) REFERENCES dominios.forma_extracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN formaextracao SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN formaextracao SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_p ADD CONSTRAINT eco_ext_mineral_p_atividade_fk FOREIGN KEY (atividade) REFERENCES dominios.atividade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN atividade SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_p ALTER COLUMN atividade SET DEFAULT 9999# CREATE TABLE edgv.eco_ext_mineral_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, @@ -4417,132 +4504,137 @@ CREATE TABLE edgv.eco_ext_mineral_a( procextracao smallint NOT NULL, formaextracao smallint NOT NULL, atividade smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT eco_ext_mineral_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX eco_ext_mineral_a_geom ON edgv.eco_ext_mineral_a USING gist (geom); +)# +CREATE INDEX eco_ext_mineral_a_geom ON edgv.eco_ext_mineral_a USING gist (geom)# -ALTER TABLE edgv.eco_ext_mineral_a OWNER TO postgres; +ALTER TABLE edgv.eco_ext_mineral_a OWNER TO postgres# ALTER TABLE edgv.eco_ext_mineral_a ADD CONSTRAINT eco_ext_mineral_a_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.eco_ext_mineral_a - ADD CONSTRAINT eco_ext_mineral_a_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[32 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT eco_ext_mineral_a_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[32 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN tipoalterantrop SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_a ADD CONSTRAINT eco_ext_mineral_a_secaoativecon_fk FOREIGN KEY (secaoativecon) REFERENCES dominios.secao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.eco_ext_mineral_a - ADD CONSTRAINT eco_ext_mineral_a_secaoativecon_check - CHECK (secaoativecon = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN secaoativecon SET DEFAULT 9999; + ADD CONSTRAINT eco_ext_mineral_a_secaoativecon_check + CHECK (secaoativecon = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN secaoativecon SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_a ADD CONSTRAINT eco_ext_mineral_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_a ADD CONSTRAINT eco_ext_mineral_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_a ADD CONSTRAINT eco_ext_mineral_a_tipoextmin_fk FOREIGN KEY (tipoextmin) REFERENCES dominios.tipo_ext_min (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN tipoextmin SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN tipoextmin SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_a ADD CONSTRAINT eco_ext_mineral_a_tipoproduto_fk FOREIGN KEY (tipoproduto) REFERENCES dominios.tipo_produto_residuo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN tipoproduto SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN tipoproduto SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_a ADD CONSTRAINT eco_ext_mineral_a_tipopocomina_fk FOREIGN KEY (tipopocomina) REFERENCES dominios.tipo_poco_mina (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN tipopocomina SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN tipopocomina SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_a ADD CONSTRAINT eco_ext_mineral_a_procextracao_fk FOREIGN KEY (procextracao) REFERENCES dominios.proc_extracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN procextracao SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN procextracao SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_a ADD CONSTRAINT eco_ext_mineral_a_formaextracao_fk FOREIGN KEY (formaextracao) REFERENCES dominios.forma_extracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN formaextracao SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN formaextracao SET DEFAULT 9999# ALTER TABLE edgv.eco_ext_mineral_a ADD CONSTRAINT eco_ext_mineral_a_atividade_fk FOREIGN KEY (atividade) REFERENCES dominios.atividade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN atividade SET DEFAULT 9999; +ALTER TABLE edgv.eco_ext_mineral_a ALTER COLUMN atividade SET DEFAULT 9999# CREATE TABLE edgv.eco_plataforma_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoplataforma smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT eco_plataforma_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX eco_plataforma_p_geom ON edgv.eco_plataforma_p USING gist (geom); +)# +CREATE INDEX eco_plataforma_p_geom ON edgv.eco_plataforma_p USING gist (geom)# -ALTER TABLE edgv.eco_plataforma_p OWNER TO postgres; +ALTER TABLE edgv.eco_plataforma_p OWNER TO postgres# ALTER TABLE edgv.eco_plataforma_p ADD CONSTRAINT eco_plataforma_p_tipoplataforma_fk FOREIGN KEY (tipoplataforma) REFERENCES dominios.tipo_plataforma (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_plataforma_p ALTER COLUMN tipoplataforma SET DEFAULT 9999; +ALTER TABLE edgv.eco_plataforma_p ALTER COLUMN tipoplataforma SET DEFAULT 9999# CREATE TABLE edgv.eco_plataforma_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoplataforma smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT eco_plataforma_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX eco_plataforma_a_geom ON edgv.eco_plataforma_a USING gist (geom); +)# +CREATE INDEX eco_plataforma_a_geom ON edgv.eco_plataforma_a USING gist (geom)# -ALTER TABLE edgv.eco_plataforma_a OWNER TO postgres; +ALTER TABLE edgv.eco_plataforma_a OWNER TO postgres# ALTER TABLE edgv.eco_plataforma_a ADD CONSTRAINT eco_plataforma_a_tipoplataforma_fk FOREIGN KEY (tipoplataforma) REFERENCES dominios.tipo_plataforma (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.eco_plataforma_a ALTER COLUMN tipoplataforma SET DEFAULT 9999; +ALTER TABLE edgv.eco_plataforma_a ALTER COLUMN tipoplataforma SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_rodoviaria_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -4553,106 +4645,107 @@ CREATE TABLE edgv.edf_edif_rodoviaria_p( cultura smallint NOT NULL, tipoedifrod smallint NOT NULL, jurisdicao smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), administracao smallint NOT NULL, classeativecon smallint NOT NULL, divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_rodoviaria_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_rodoviaria_p_geom ON edgv.edf_edif_rodoviaria_p USING gist (geom); +)# +CREATE INDEX edf_edif_rodoviaria_p_geom ON edgv.edf_edif_rodoviaria_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_rodoviaria_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_rodoviaria_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_rodoviaria_p ADD CONSTRAINT edf_edif_rodoviaria_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_p ADD CONSTRAINT edf_edif_rodoviaria_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_p ADD CONSTRAINT edf_edif_rodoviaria_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_p ADD CONSTRAINT edf_edif_rodoviaria_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_p ADD CONSTRAINT edf_edif_rodoviaria_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_p ADD CONSTRAINT edf_edif_rodoviaria_p_tipoedifrod_fk FOREIGN KEY (tipoedifrod) REFERENCES dominios.tipo_edif_rod (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN tipoedifrod SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN tipoedifrod SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_p ADD CONSTRAINT edf_edif_rodoviaria_p_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_p ADD CONSTRAINT edf_edif_rodoviaria_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_p ADD CONSTRAINT edf_edif_rodoviaria_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_p ADD CONSTRAINT edf_edif_rodoviaria_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_p ADD CONSTRAINT edf_edif_rodoviaria_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_p ADD CONSTRAINT edf_edif_rodoviaria_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_rodoviaria_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -4663,106 +4756,107 @@ CREATE TABLE edgv.edf_edif_rodoviaria_a( cultura smallint NOT NULL, tipoedifrod smallint NOT NULL, jurisdicao smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), administracao smallint NOT NULL, classeativecon smallint NOT NULL, divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_rodoviaria_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_rodoviaria_a_geom ON edgv.edf_edif_rodoviaria_a USING gist (geom); +)# +CREATE INDEX edf_edif_rodoviaria_a_geom ON edgv.edf_edif_rodoviaria_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_rodoviaria_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_rodoviaria_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_rodoviaria_a ADD CONSTRAINT edf_edif_rodoviaria_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_a ADD CONSTRAINT edf_edif_rodoviaria_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_a ADD CONSTRAINT edf_edif_rodoviaria_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_a ADD CONSTRAINT edf_edif_rodoviaria_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_a ADD CONSTRAINT edf_edif_rodoviaria_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_a ADD CONSTRAINT edf_edif_rodoviaria_a_tipoedifrod_fk FOREIGN KEY (tipoedifrod) REFERENCES dominios.tipo_edif_rod (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN tipoedifrod SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN tipoedifrod SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_a ADD CONSTRAINT edf_edif_rodoviaria_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_a ADD CONSTRAINT edf_edif_rodoviaria_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_a ADD CONSTRAINT edf_edif_rodoviaria_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_a ADD CONSTRAINT edf_edif_rodoviaria_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_a ADD CONSTRAINT edf_edif_rodoviaria_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_rodoviaria_a ADD CONSTRAINT edf_edif_rodoviaria_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_rodoviaria_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_constr_turistica_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -4779,110 +4873,112 @@ CREATE TABLE edgv.edf_edif_constr_turistica_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_constr_turistica_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_constr_turistica_p_geom ON edgv.edf_edif_constr_turistica_p USING gist (geom); +)# +CREATE INDEX edf_edif_constr_turistica_p_geom ON edgv.edf_edif_constr_turistica_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_constr_turistica_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_constr_turistica_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_constr_turistica_p ADD CONSTRAINT edf_edif_constr_turistica_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_p ADD CONSTRAINT edf_edif_constr_turistica_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_p ADD CONSTRAINT edf_edif_constr_turistica_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_p ADD CONSTRAINT edf_edif_constr_turistica_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_constr_turistica_p - ADD CONSTRAINT edf_edif_constr_turistica_p_turistica_check - CHECK (turistica = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN turistica SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_constr_turistica_p_turistica_check + CHECK (turistica = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_p ADD CONSTRAINT edf_edif_constr_turistica_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_p ADD CONSTRAINT edf_edif_constr_turistica_p_tipoedifturist_fk FOREIGN KEY (tipoedifturist) REFERENCES dominios.tipo_edif_turist (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN tipoedifturist SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN tipoedifturist SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_p ADD CONSTRAINT edf_edif_constr_turistica_p_ovgd_fk FOREIGN KEY (ovgd) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN ovgd SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN ovgd SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_p ADD CONSTRAINT edf_edif_constr_turistica_p_tombada_fk FOREIGN KEY (tombada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN tombada SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN tombada SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_p ADD CONSTRAINT edf_edif_constr_turistica_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_p ADD CONSTRAINT edf_edif_constr_turistica_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_p ADD CONSTRAINT edf_edif_constr_turistica_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_p ADD CONSTRAINT edf_edif_constr_turistica_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_p ADD CONSTRAINT edf_edif_constr_turistica_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_constr_turistica_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -4899,110 +4995,112 @@ CREATE TABLE edgv.edf_edif_constr_turistica_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_constr_turistica_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_constr_turistica_a_geom ON edgv.edf_edif_constr_turistica_a USING gist (geom); +)# +CREATE INDEX edf_edif_constr_turistica_a_geom ON edgv.edf_edif_constr_turistica_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_constr_turistica_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_constr_turistica_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_constr_turistica_a ADD CONSTRAINT edf_edif_constr_turistica_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_a ADD CONSTRAINT edf_edif_constr_turistica_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_a ADD CONSTRAINT edf_edif_constr_turistica_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_a ADD CONSTRAINT edf_edif_constr_turistica_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_constr_turistica_a - ADD CONSTRAINT edf_edif_constr_turistica_a_turistica_check - CHECK (turistica = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN turistica SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_constr_turistica_a_turistica_check + CHECK (turistica = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_a ADD CONSTRAINT edf_edif_constr_turistica_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_a ADD CONSTRAINT edf_edif_constr_turistica_a_tipoedifturist_fk FOREIGN KEY (tipoedifturist) REFERENCES dominios.tipo_edif_turist (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN tipoedifturist SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN tipoedifturist SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_a ADD CONSTRAINT edf_edif_constr_turistica_a_ovgd_fk FOREIGN KEY (ovgd) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN ovgd SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN ovgd SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_a ADD CONSTRAINT edf_edif_constr_turistica_a_tombada_fk FOREIGN KEY (tombada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN tombada SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN tombada SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_a ADD CONSTRAINT edf_edif_constr_turistica_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_a ADD CONSTRAINT edf_edif_constr_turistica_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_a ADD CONSTRAINT edf_edif_constr_turistica_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_a ADD CONSTRAINT edf_edif_constr_turistica_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_turistica_a ADD CONSTRAINT edf_edif_constr_turistica_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_turistica_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_representacao_diplomatica_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -5017,93 +5115,94 @@ CREATE TABLE edgv.edf_representacao_diplomatica_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_representacao_diplomatica_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_representacao_diplomatica_p_geom ON edgv.edf_representacao_diplomatica_p USING gist (geom); +)# +CREATE INDEX edf_representacao_diplomatica_p_geom ON edgv.edf_representacao_diplomatica_p USING gist (geom)# -ALTER TABLE edgv.edf_representacao_diplomatica_p OWNER TO postgres; +ALTER TABLE edgv.edf_representacao_diplomatica_p OWNER TO postgres# ALTER TABLE edgv.edf_representacao_diplomatica_p ADD CONSTRAINT edf_representacao_diplomatica_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_p ADD CONSTRAINT edf_representacao_diplomatica_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_p ADD CONSTRAINT edf_representacao_diplomatica_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_p ADD CONSTRAINT edf_representacao_diplomatica_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_p ADD CONSTRAINT edf_representacao_diplomatica_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_p ADD CONSTRAINT edf_representacao_diplomatica_p_tiporepdiplomatica_fk FOREIGN KEY (tiporepdiplomatica) REFERENCES dominios.tipo_rep_diplomatica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN tiporepdiplomatica SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN tiporepdiplomatica SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_p ADD CONSTRAINT edf_representacao_diplomatica_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_p ADD CONSTRAINT edf_representacao_diplomatica_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_p ADD CONSTRAINT edf_representacao_diplomatica_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_p ADD CONSTRAINT edf_representacao_diplomatica_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_p ADD CONSTRAINT edf_representacao_diplomatica_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_representacao_diplomatica_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -5118,93 +5217,94 @@ CREATE TABLE edgv.edf_representacao_diplomatica_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_representacao_diplomatica_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_representacao_diplomatica_a_geom ON edgv.edf_representacao_diplomatica_a USING gist (geom); +)# +CREATE INDEX edf_representacao_diplomatica_a_geom ON edgv.edf_representacao_diplomatica_a USING gist (geom)# -ALTER TABLE edgv.edf_representacao_diplomatica_a OWNER TO postgres; +ALTER TABLE edgv.edf_representacao_diplomatica_a OWNER TO postgres# ALTER TABLE edgv.edf_representacao_diplomatica_a ADD CONSTRAINT edf_representacao_diplomatica_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_a ADD CONSTRAINT edf_representacao_diplomatica_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_a ADD CONSTRAINT edf_representacao_diplomatica_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_a ADD CONSTRAINT edf_representacao_diplomatica_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_a ADD CONSTRAINT edf_representacao_diplomatica_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_a ADD CONSTRAINT edf_representacao_diplomatica_a_tiporepdiplomatica_fk FOREIGN KEY (tiporepdiplomatica) REFERENCES dominios.tipo_rep_diplomatica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN tiporepdiplomatica SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN tiporepdiplomatica SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_a ADD CONSTRAINT edf_representacao_diplomatica_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_a ADD CONSTRAINT edf_representacao_diplomatica_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_a ADD CONSTRAINT edf_representacao_diplomatica_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_a ADD CONSTRAINT edf_representacao_diplomatica_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_representacao_diplomatica_a ADD CONSTRAINT edf_representacao_diplomatica_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_representacao_diplomatica_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -5219,93 +5319,94 @@ CREATE TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_agropec_ext_vegetal_pesca_p_geom ON edgv.edf_edif_agropec_ext_vegetal_pesca_p USING gist (geom); +)# +CREATE INDEX edf_edif_agropec_ext_vegetal_pesca_p_geom ON edgv.edf_edif_agropec_ext_vegetal_pesca_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_p_tipoedifagropec_fk FOREIGN KEY (tipoedifagropec) REFERENCES dominios.tipo_edif_agropec (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN tipoedifagropec SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN tipoedifagropec SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -5320,93 +5421,94 @@ CREATE TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_agropec_ext_vegetal_pesca_a_geom ON edgv.edf_edif_agropec_ext_vegetal_pesca_a USING gist (geom); +)# +CREATE INDEX edf_edif_agropec_ext_vegetal_pesca_a_geom ON edgv.edf_edif_agropec_ext_vegetal_pesca_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_a_tipoedifagropec_fk FOREIGN KEY (tipoedifagropec) REFERENCES dominios.tipo_edif_agropec (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN tipoedifagropec SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN tipoedifagropec SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ADD CONSTRAINT edf_edif_agropec_ext_vegetal_pesca_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_agropec_ext_vegetal_pesca_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_constr_aeroportuaria_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -5417,106 +5519,107 @@ CREATE TABLE edgv.edf_edif_constr_aeroportuaria_p( cultura smallint NOT NULL, tipoedifaero smallint NOT NULL, jurisdicao smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), administracao smallint NOT NULL, classeativecon smallint NOT NULL, divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_constr_aeroportuaria_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_constr_aeroportuaria_p_geom ON edgv.edf_edif_constr_aeroportuaria_p USING gist (geom); +)# +CREATE INDEX edf_edif_constr_aeroportuaria_p_geom ON edgv.edf_edif_constr_aeroportuaria_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ADD CONSTRAINT edf_edif_constr_aeroportuaria_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ADD CONSTRAINT edf_edif_constr_aeroportuaria_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ADD CONSTRAINT edf_edif_constr_aeroportuaria_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ADD CONSTRAINT edf_edif_constr_aeroportuaria_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ADD CONSTRAINT edf_edif_constr_aeroportuaria_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ADD CONSTRAINT edf_edif_constr_aeroportuaria_p_tipoedifaero_fk FOREIGN KEY (tipoedifaero) REFERENCES dominios.tipo_edif_aero (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN tipoedifaero SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN tipoedifaero SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ADD CONSTRAINT edf_edif_constr_aeroportuaria_p_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ADD CONSTRAINT edf_edif_constr_aeroportuaria_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ADD CONSTRAINT edf_edif_constr_aeroportuaria_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ADD CONSTRAINT edf_edif_constr_aeroportuaria_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ADD CONSTRAINT edf_edif_constr_aeroportuaria_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ADD CONSTRAINT edf_edif_constr_aeroportuaria_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_constr_aeroportuaria_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -5527,106 +5630,107 @@ CREATE TABLE edgv.edf_edif_constr_aeroportuaria_a( cultura smallint NOT NULL, tipoedifaero smallint NOT NULL, jurisdicao smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), administracao smallint NOT NULL, classeativecon smallint NOT NULL, divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_constr_aeroportuaria_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_constr_aeroportuaria_a_geom ON edgv.edf_edif_constr_aeroportuaria_a USING gist (geom); +)# +CREATE INDEX edf_edif_constr_aeroportuaria_a_geom ON edgv.edf_edif_constr_aeroportuaria_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ADD CONSTRAINT edf_edif_constr_aeroportuaria_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ADD CONSTRAINT edf_edif_constr_aeroportuaria_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ADD CONSTRAINT edf_edif_constr_aeroportuaria_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ADD CONSTRAINT edf_edif_constr_aeroportuaria_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ADD CONSTRAINT edf_edif_constr_aeroportuaria_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ADD CONSTRAINT edf_edif_constr_aeroportuaria_a_tipoedifaero_fk FOREIGN KEY (tipoedifaero) REFERENCES dominios.tipo_edif_aero (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN tipoedifaero SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN tipoedifaero SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ADD CONSTRAINT edf_edif_constr_aeroportuaria_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ADD CONSTRAINT edf_edif_constr_aeroportuaria_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ADD CONSTRAINT edf_edif_constr_aeroportuaria_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ADD CONSTRAINT edf_edif_constr_aeroportuaria_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ADD CONSTRAINT edf_edif_constr_aeroportuaria_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ADD CONSTRAINT edf_edif_constr_aeroportuaria_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_aeroportuaria_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_banheiro_publico_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -5640,86 +5744,87 @@ CREATE TABLE edgv.edf_banheiro_publico_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_banheiro_publico_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_banheiro_publico_p_geom ON edgv.edf_banheiro_publico_p USING gist (geom); +)# +CREATE INDEX edf_banheiro_publico_p_geom ON edgv.edf_banheiro_publico_p USING gist (geom)# -ALTER TABLE edgv.edf_banheiro_publico_p OWNER TO postgres; +ALTER TABLE edgv.edf_banheiro_publico_p OWNER TO postgres# ALTER TABLE edgv.edf_banheiro_publico_p ADD CONSTRAINT edf_banheiro_publico_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_p ADD CONSTRAINT edf_banheiro_publico_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_p ADD CONSTRAINT edf_banheiro_publico_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_p ADD CONSTRAINT edf_banheiro_publico_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_p ADD CONSTRAINT edf_banheiro_publico_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_p ADD CONSTRAINT edf_banheiro_publico_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_p ADD CONSTRAINT edf_banheiro_publico_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_p ADD CONSTRAINT edf_banheiro_publico_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_p ADD CONSTRAINT edf_banheiro_publico_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_p ADD CONSTRAINT edf_banheiro_publico_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_banheiro_publico_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -5733,86 +5838,87 @@ CREATE TABLE edgv.edf_banheiro_publico_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_banheiro_publico_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_banheiro_publico_a_geom ON edgv.edf_banheiro_publico_a USING gist (geom); +)# +CREATE INDEX edf_banheiro_publico_a_geom ON edgv.edf_banheiro_publico_a USING gist (geom)# -ALTER TABLE edgv.edf_banheiro_publico_a OWNER TO postgres; +ALTER TABLE edgv.edf_banheiro_publico_a OWNER TO postgres# ALTER TABLE edgv.edf_banheiro_publico_a ADD CONSTRAINT edf_banheiro_publico_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_a ADD CONSTRAINT edf_banheiro_publico_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_a ADD CONSTRAINT edf_banheiro_publico_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_a ADD CONSTRAINT edf_banheiro_publico_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_a ADD CONSTRAINT edf_banheiro_publico_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_a ADD CONSTRAINT edf_banheiro_publico_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_a ADD CONSTRAINT edf_banheiro_publico_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_a ADD CONSTRAINT edf_banheiro_publico_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_a ADD CONSTRAINT edf_banheiro_publico_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_banheiro_publico_a ADD CONSTRAINT edf_banheiro_publico_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_banheiro_publico_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_metro_ferroviaria_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -5823,106 +5929,107 @@ CREATE TABLE edgv.edf_edif_metro_ferroviaria_p( cultura smallint NOT NULL, tipoedifmetroferrov smallint NOT NULL, jurisdicao smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), administracao smallint NOT NULL, classeativecon smallint NOT NULL, divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_metro_ferroviaria_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_metro_ferroviaria_p_geom ON edgv.edf_edif_metro_ferroviaria_p USING gist (geom); +)# +CREATE INDEX edf_edif_metro_ferroviaria_p_geom ON edgv.edf_edif_metro_ferroviaria_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ADD CONSTRAINT edf_edif_metro_ferroviaria_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ADD CONSTRAINT edf_edif_metro_ferroviaria_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ADD CONSTRAINT edf_edif_metro_ferroviaria_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ADD CONSTRAINT edf_edif_metro_ferroviaria_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ADD CONSTRAINT edf_edif_metro_ferroviaria_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ADD CONSTRAINT edf_edif_metro_ferroviaria_p_tipoedifmetroferrov_fk FOREIGN KEY (tipoedifmetroferrov) REFERENCES dominios.tipo_edif_metro_ferrov (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN tipoedifmetroferrov SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN tipoedifmetroferrov SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ADD CONSTRAINT edf_edif_metro_ferroviaria_p_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ADD CONSTRAINT edf_edif_metro_ferroviaria_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ADD CONSTRAINT edf_edif_metro_ferroviaria_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ADD CONSTRAINT edf_edif_metro_ferroviaria_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ADD CONSTRAINT edf_edif_metro_ferroviaria_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ADD CONSTRAINT edf_edif_metro_ferroviaria_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_metro_ferroviaria_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -5933,106 +6040,107 @@ CREATE TABLE edgv.edf_edif_metro_ferroviaria_a( cultura smallint NOT NULL, tipoedifmetroferrov smallint NOT NULL, jurisdicao smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), administracao smallint NOT NULL, classeativecon smallint NOT NULL, divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_metro_ferroviaria_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_metro_ferroviaria_a_geom ON edgv.edf_edif_metro_ferroviaria_a USING gist (geom); +)# +CREATE INDEX edf_edif_metro_ferroviaria_a_geom ON edgv.edf_edif_metro_ferroviaria_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ADD CONSTRAINT edf_edif_metro_ferroviaria_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ADD CONSTRAINT edf_edif_metro_ferroviaria_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ADD CONSTRAINT edf_edif_metro_ferroviaria_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ADD CONSTRAINT edf_edif_metro_ferroviaria_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ADD CONSTRAINT edf_edif_metro_ferroviaria_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ADD CONSTRAINT edf_edif_metro_ferroviaria_a_tipoedifmetroferrov_fk FOREIGN KEY (tipoedifmetroferrov) REFERENCES dominios.tipo_edif_metro_ferrov (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN tipoedifmetroferrov SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN tipoedifmetroferrov SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ADD CONSTRAINT edf_edif_metro_ferroviaria_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ADD CONSTRAINT edf_edif_metro_ferroviaria_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ADD CONSTRAINT edf_edif_metro_ferroviaria_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ADD CONSTRAINT edf_edif_metro_ferroviaria_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ADD CONSTRAINT edf_edif_metro_ferroviaria_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ADD CONSTRAINT edf_edif_metro_ferroviaria_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_metro_ferroviaria_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_comerc_serv_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -6048,100 +6156,101 @@ CREATE TABLE edgv.edf_edif_comerc_serv_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_comerc_serv_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_comerc_serv_p_geom ON edgv.edf_edif_comerc_serv_p USING gist (geom); +)# +CREATE INDEX edf_edif_comerc_serv_p_geom ON edgv.edf_edif_comerc_serv_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_comerc_serv_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_comerc_serv_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_comerc_serv_p ADD CONSTRAINT edf_edif_comerc_serv_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_p ADD CONSTRAINT edf_edif_comerc_serv_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_p ADD CONSTRAINT edf_edif_comerc_serv_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_p ADD CONSTRAINT edf_edif_comerc_serv_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_p ADD CONSTRAINT edf_edif_comerc_serv_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_p ADD CONSTRAINT edf_edif_comerc_serv_p_tipoedifcomercserv_fk FOREIGN KEY (tipoedifcomercserv) REFERENCES dominios.tipo_edif_comerc_serv (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN tipoedifcomercserv SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN tipoedifcomercserv SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_p ADD CONSTRAINT edf_edif_comerc_serv_p_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN finalidade SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN finalidade SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_p ADD CONSTRAINT edf_edif_comerc_serv_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_p ADD CONSTRAINT edf_edif_comerc_serv_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_p ADD CONSTRAINT edf_edif_comerc_serv_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_p ADD CONSTRAINT edf_edif_comerc_serv_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_p ADD CONSTRAINT edf_edif_comerc_serv_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_comerc_serv_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -6157,100 +6266,101 @@ CREATE TABLE edgv.edf_edif_comerc_serv_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_comerc_serv_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_comerc_serv_a_geom ON edgv.edf_edif_comerc_serv_a USING gist (geom); +)# +CREATE INDEX edf_edif_comerc_serv_a_geom ON edgv.edf_edif_comerc_serv_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_comerc_serv_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_comerc_serv_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_comerc_serv_a ADD CONSTRAINT edf_edif_comerc_serv_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_a ADD CONSTRAINT edf_edif_comerc_serv_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_a ADD CONSTRAINT edf_edif_comerc_serv_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_a ADD CONSTRAINT edf_edif_comerc_serv_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_a ADD CONSTRAINT edf_edif_comerc_serv_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_a ADD CONSTRAINT edf_edif_comerc_serv_a_tipoedifcomercserv_fk FOREIGN KEY (tipoedifcomercserv) REFERENCES dominios.tipo_edif_comerc_serv (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN tipoedifcomercserv SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN tipoedifcomercserv SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_a ADD CONSTRAINT edf_edif_comerc_serv_a_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN finalidade SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN finalidade SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_a ADD CONSTRAINT edf_edif_comerc_serv_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_a ADD CONSTRAINT edf_edif_comerc_serv_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_a ADD CONSTRAINT edf_edif_comerc_serv_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_a ADD CONSTRAINT edf_edif_comerc_serv_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comerc_serv_a ADD CONSTRAINT edf_edif_comerc_serv_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comerc_serv_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edificacao_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -6264,86 +6374,87 @@ CREATE TABLE edgv.edf_edificacao_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edificacao_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edificacao_p_geom ON edgv.edf_edificacao_p USING gist (geom); +)# +CREATE INDEX edf_edificacao_p_geom ON edgv.edf_edificacao_p USING gist (geom)# -ALTER TABLE edgv.edf_edificacao_p OWNER TO postgres; +ALTER TABLE edgv.edf_edificacao_p OWNER TO postgres# ALTER TABLE edgv.edf_edificacao_p ADD CONSTRAINT edf_edificacao_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_p ADD CONSTRAINT edf_edificacao_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_p ADD CONSTRAINT edf_edificacao_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_p ADD CONSTRAINT edf_edificacao_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_p ADD CONSTRAINT edf_edificacao_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_p ADD CONSTRAINT edf_edificacao_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_p ADD CONSTRAINT edf_edificacao_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_p ADD CONSTRAINT edf_edificacao_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_p ADD CONSTRAINT edf_edificacao_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_p ADD CONSTRAINT edf_edificacao_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edificacao_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -6357,86 +6468,87 @@ CREATE TABLE edgv.edf_edificacao_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edificacao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edificacao_a_geom ON edgv.edf_edificacao_a USING gist (geom); +)# +CREATE INDEX edf_edificacao_a_geom ON edgv.edf_edificacao_a USING gist (geom)# -ALTER TABLE edgv.edf_edificacao_a OWNER TO postgres; +ALTER TABLE edgv.edf_edificacao_a OWNER TO postgres# ALTER TABLE edgv.edf_edificacao_a ADD CONSTRAINT edf_edificacao_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_a ADD CONSTRAINT edf_edificacao_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_a ADD CONSTRAINT edf_edificacao_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_a ADD CONSTRAINT edf_edificacao_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_a ADD CONSTRAINT edf_edificacao_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_a ADD CONSTRAINT edf_edificacao_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_a ADD CONSTRAINT edf_edificacao_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_a ADD CONSTRAINT edf_edificacao_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_a ADD CONSTRAINT edf_edificacao_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edificacao_a ADD CONSTRAINT edf_edificacao_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edificacao_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_saude_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -6451,93 +6563,94 @@ CREATE TABLE edgv.edf_edif_saude_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_saude_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_saude_p_geom ON edgv.edf_edif_saude_p USING gist (geom); +)# +CREATE INDEX edf_edif_saude_p_geom ON edgv.edf_edif_saude_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_saude_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_saude_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_saude_p ADD CONSTRAINT edf_edif_saude_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_p ADD CONSTRAINT edf_edif_saude_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_p ADD CONSTRAINT edf_edif_saude_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_p ADD CONSTRAINT edf_edif_saude_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_p ADD CONSTRAINT edf_edif_saude_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_p ADD CONSTRAINT edf_edif_saude_p_nivelatencao_fk FOREIGN KEY (nivelatencao) REFERENCES dominios.nivel_atencao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN nivelatencao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN nivelatencao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_p ADD CONSTRAINT edf_edif_saude_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_p ADD CONSTRAINT edf_edif_saude_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_p ADD CONSTRAINT edf_edif_saude_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_p ADD CONSTRAINT edf_edif_saude_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_p ADD CONSTRAINT edf_edif_saude_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_saude_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -6552,93 +6665,94 @@ CREATE TABLE edgv.edf_edif_saude_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_saude_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_saude_a_geom ON edgv.edf_edif_saude_a USING gist (geom); +)# +CREATE INDEX edf_edif_saude_a_geom ON edgv.edf_edif_saude_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_saude_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_saude_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_saude_a ADD CONSTRAINT edf_edif_saude_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_a ADD CONSTRAINT edf_edif_saude_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_a ADD CONSTRAINT edf_edif_saude_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_a ADD CONSTRAINT edf_edif_saude_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_a ADD CONSTRAINT edf_edif_saude_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_a ADD CONSTRAINT edf_edif_saude_a_nivelatencao_fk FOREIGN KEY (nivelatencao) REFERENCES dominios.nivel_atencao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN nivelatencao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN nivelatencao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_a ADD CONSTRAINT edf_edif_saude_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_a ADD CONSTRAINT edf_edif_saude_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_a ADD CONSTRAINT edf_edif_saude_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_a ADD CONSTRAINT edf_edif_saude_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saude_a ADD CONSTRAINT edf_edif_saude_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saude_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_posto_guarda_municipal_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -6655,116 +6769,120 @@ CREATE TABLE edgv.edf_posto_guarda_municipal_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_posto_guarda_municipal_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_posto_guarda_municipal_p_geom ON edgv.edf_posto_guarda_municipal_p USING gist (geom); +)# +CREATE INDEX edf_posto_guarda_municipal_p_geom ON edgv.edf_posto_guarda_municipal_p USING gist (geom)# -ALTER TABLE edgv.edf_posto_guarda_municipal_p OWNER TO postgres; +ALTER TABLE edgv.edf_posto_guarda_municipal_p OWNER TO postgres# ALTER TABLE edgv.edf_posto_guarda_municipal_p ADD CONSTRAINT edf_posto_guarda_municipal_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_p ADD CONSTRAINT edf_posto_guarda_municipal_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_p ADD CONSTRAINT edf_posto_guarda_municipal_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_p ADD CONSTRAINT edf_posto_guarda_municipal_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_p ADD CONSTRAINT edf_posto_guarda_municipal_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_p ADD CONSTRAINT edf_posto_guarda_municipal_p_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_guarda_municipal_p - ADD CONSTRAINT edf_posto_guarda_municipal_p_tipousoedif_check - CHECK (tipousoedif = ANY(ARRAY[5 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN tipousoedif SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_guarda_municipal_p_tipousoedif_check + CHECK (tipousoedif = ANY(ARRAY[5 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_p ADD CONSTRAINT edf_posto_guarda_municipal_p_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_guarda_municipal_p - ADD CONSTRAINT edf_posto_guarda_municipal_p_jurisdicao_check - CHECK (jurisdicao = ANY(ARRAY[3 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN jurisdicao SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_guarda_municipal_p_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_p ADD CONSTRAINT edf_posto_guarda_municipal_p_tipoedifpubcivil_fk FOREIGN KEY (tipoedifpubcivil) REFERENCES dominios.tipo_org_civil (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_guarda_municipal_p - ADD CONSTRAINT edf_posto_guarda_municipal_p_tipoedifpubcivil_check - CHECK (tipoedifpubcivil = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_guarda_municipal_p_tipoedifpubcivil_check + CHECK (tipoedifpubcivil = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_p ADD CONSTRAINT edf_posto_guarda_municipal_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_p ADD CONSTRAINT edf_posto_guarda_municipal_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_p ADD CONSTRAINT edf_posto_guarda_municipal_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_p ADD CONSTRAINT edf_posto_guarda_municipal_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_p ADD CONSTRAINT edf_posto_guarda_municipal_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_posto_guarda_municipal_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -6781,116 +6899,120 @@ CREATE TABLE edgv.edf_posto_guarda_municipal_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_posto_guarda_municipal_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_posto_guarda_municipal_a_geom ON edgv.edf_posto_guarda_municipal_a USING gist (geom); +)# +CREATE INDEX edf_posto_guarda_municipal_a_geom ON edgv.edf_posto_guarda_municipal_a USING gist (geom)# -ALTER TABLE edgv.edf_posto_guarda_municipal_a OWNER TO postgres; +ALTER TABLE edgv.edf_posto_guarda_municipal_a OWNER TO postgres# ALTER TABLE edgv.edf_posto_guarda_municipal_a ADD CONSTRAINT edf_posto_guarda_municipal_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_a ADD CONSTRAINT edf_posto_guarda_municipal_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_a ADD CONSTRAINT edf_posto_guarda_municipal_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_a ADD CONSTRAINT edf_posto_guarda_municipal_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_a ADD CONSTRAINT edf_posto_guarda_municipal_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_a ADD CONSTRAINT edf_posto_guarda_municipal_a_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_guarda_municipal_a - ADD CONSTRAINT edf_posto_guarda_municipal_a_tipousoedif_check - CHECK (tipousoedif = ANY(ARRAY[5 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN tipousoedif SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_guarda_municipal_a_tipousoedif_check + CHECK (tipousoedif = ANY(ARRAY[5 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_a ADD CONSTRAINT edf_posto_guarda_municipal_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_guarda_municipal_a - ADD CONSTRAINT edf_posto_guarda_municipal_a_jurisdicao_check - CHECK (jurisdicao = ANY(ARRAY[3 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN jurisdicao SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_guarda_municipal_a_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_a ADD CONSTRAINT edf_posto_guarda_municipal_a_tipoedifpubcivil_fk FOREIGN KEY (tipoedifpubcivil) REFERENCES dominios.tipo_org_civil (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_guarda_municipal_a - ADD CONSTRAINT edf_posto_guarda_municipal_a_tipoedifpubcivil_check - CHECK (tipoedifpubcivil = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_guarda_municipal_a_tipoedifpubcivil_check + CHECK (tipoedifpubcivil = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_a ADD CONSTRAINT edf_posto_guarda_municipal_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_a ADD CONSTRAINT edf_posto_guarda_municipal_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_a ADD CONSTRAINT edf_posto_guarda_municipal_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_a ADD CONSTRAINT edf_posto_guarda_municipal_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_guarda_municipal_a ADD CONSTRAINT edf_posto_guarda_municipal_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_guarda_municipal_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_abast_agua_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -6905,93 +7027,94 @@ CREATE TABLE edgv.edf_edif_abast_agua_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_abast_agua_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_abast_agua_p_geom ON edgv.edf_edif_abast_agua_p USING gist (geom); +)# +CREATE INDEX edf_edif_abast_agua_p_geom ON edgv.edf_edif_abast_agua_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_abast_agua_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_abast_agua_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_abast_agua_p ADD CONSTRAINT edf_edif_abast_agua_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_p ADD CONSTRAINT edf_edif_abast_agua_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_p ADD CONSTRAINT edf_edif_abast_agua_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_p ADD CONSTRAINT edf_edif_abast_agua_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_p ADD CONSTRAINT edf_edif_abast_agua_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_p ADD CONSTRAINT edf_edif_abast_agua_p_tipoedifabast_fk FOREIGN KEY (tipoedifabast) REFERENCES dominios.tipo_edif_abast (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN tipoedifabast SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN tipoedifabast SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_p ADD CONSTRAINT edf_edif_abast_agua_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_p ADD CONSTRAINT edf_edif_abast_agua_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_p ADD CONSTRAINT edf_edif_abast_agua_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_p ADD CONSTRAINT edf_edif_abast_agua_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_p ADD CONSTRAINT edf_edif_abast_agua_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_abast_agua_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -7006,93 +7129,94 @@ CREATE TABLE edgv.edf_edif_abast_agua_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_abast_agua_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_abast_agua_a_geom ON edgv.edf_edif_abast_agua_a USING gist (geom); +)# +CREATE INDEX edf_edif_abast_agua_a_geom ON edgv.edf_edif_abast_agua_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_abast_agua_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_abast_agua_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_abast_agua_a ADD CONSTRAINT edf_edif_abast_agua_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_a ADD CONSTRAINT edf_edif_abast_agua_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_a ADD CONSTRAINT edf_edif_abast_agua_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_a ADD CONSTRAINT edf_edif_abast_agua_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_a ADD CONSTRAINT edf_edif_abast_agua_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_a ADD CONSTRAINT edf_edif_abast_agua_a_tipoedifabast_fk FOREIGN KEY (tipoedifabast) REFERENCES dominios.tipo_edif_abast (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN tipoedifabast SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN tipoedifabast SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_a ADD CONSTRAINT edf_edif_abast_agua_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_a ADD CONSTRAINT edf_edif_abast_agua_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_a ADD CONSTRAINT edf_edif_abast_agua_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_a ADD CONSTRAINT edf_edif_abast_agua_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_abast_agua_a ADD CONSTRAINT edf_edif_abast_agua_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_abast_agua_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_posto_fiscal_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -7105,123 +7229,125 @@ CREATE TABLE edgv.edf_posto_fiscal_p( jurisdicao smallint NOT NULL, tipoedifpubcivil smallint NOT NULL, tipopostofisc smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), administracao smallint NOT NULL, classeativecon smallint NOT NULL, divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_posto_fiscal_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_posto_fiscal_p_geom ON edgv.edf_posto_fiscal_p USING gist (geom); +)# +CREATE INDEX edf_posto_fiscal_p_geom ON edgv.edf_posto_fiscal_p USING gist (geom)# -ALTER TABLE edgv.edf_posto_fiscal_p OWNER TO postgres; +ALTER TABLE edgv.edf_posto_fiscal_p OWNER TO postgres# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN tipousoedif SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_tipoedifpubcivil_fk FOREIGN KEY (tipoedifpubcivil) REFERENCES dominios.tipo_org_civil (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_fiscal_p - ADD CONSTRAINT edf_posto_fiscal_p_tipoedifpubcivil_check - CHECK (tipoedifpubcivil = ANY(ARRAY[99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_fiscal_p_tipoedifpubcivil_check + CHECK (tipoedifpubcivil = ANY(ARRAY[99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_tipopostofisc_fk FOREIGN KEY (tipopostofisc) REFERENCES dominios.tipo_posto_fisc (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN tipopostofisc SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN tipopostofisc SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_p ADD CONSTRAINT edf_posto_fiscal_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_posto_fiscal_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -7234,123 +7360,125 @@ CREATE TABLE edgv.edf_posto_fiscal_a( jurisdicao smallint NOT NULL, tipoedifpubcivil smallint NOT NULL, tipopostofisc smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), administracao smallint NOT NULL, classeativecon smallint NOT NULL, divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_posto_fiscal_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_posto_fiscal_a_geom ON edgv.edf_posto_fiscal_a USING gist (geom); +)# +CREATE INDEX edf_posto_fiscal_a_geom ON edgv.edf_posto_fiscal_a USING gist (geom)# -ALTER TABLE edgv.edf_posto_fiscal_a OWNER TO postgres; +ALTER TABLE edgv.edf_posto_fiscal_a OWNER TO postgres# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN tipousoedif SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_tipoedifpubcivil_fk FOREIGN KEY (tipoedifpubcivil) REFERENCES dominios.tipo_org_civil (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_fiscal_a - ADD CONSTRAINT edf_posto_fiscal_a_tipoedifpubcivil_check - CHECK (tipoedifpubcivil = ANY(ARRAY[99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_fiscal_a_tipoedifpubcivil_check + CHECK (tipoedifpubcivil = ANY(ARRAY[99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_tipopostofisc_fk FOREIGN KEY (tipopostofisc) REFERENCES dominios.tipo_posto_fisc (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN tipopostofisc SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN tipopostofisc SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_fiscal_a ADD CONSTRAINT edf_posto_fiscal_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_fiscal_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_religiosa_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -7361,114 +7489,115 @@ CREATE TABLE edgv.edf_edif_religiosa_p( cultura smallint NOT NULL, tipoedifrelig smallint NOT NULL, ensino smallint NOT NULL, - religiao varchar(100), + religiao varchar(255), crista smallint NOT NULL, administracao smallint NOT NULL, classeativecon smallint NOT NULL, divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_religiosa_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_religiosa_p_geom ON edgv.edf_edif_religiosa_p USING gist (geom); +)# +CREATE INDEX edf_edif_religiosa_p_geom ON edgv.edf_edif_religiosa_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_religiosa_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_religiosa_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_religiosa_p ADD CONSTRAINT edf_edif_religiosa_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_p ADD CONSTRAINT edf_edif_religiosa_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_p ADD CONSTRAINT edf_edif_religiosa_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_p ADD CONSTRAINT edf_edif_religiosa_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_p ADD CONSTRAINT edf_edif_religiosa_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_p ADD CONSTRAINT edf_edif_religiosa_p_tipoedifrelig_fk FOREIGN KEY (tipoedifrelig) REFERENCES dominios.tipo_edif_relig (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN tipoedifrelig SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN tipoedifrelig SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_p ADD CONSTRAINT edf_edif_religiosa_p_ensino_fk FOREIGN KEY (ensino) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN ensino SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN ensino SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_p ADD CONSTRAINT edf_edif_religiosa_p_crista_fk FOREIGN KEY (crista) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN crista SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN crista SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_p ADD CONSTRAINT edf_edif_religiosa_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_p ADD CONSTRAINT edf_edif_religiosa_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_p ADD CONSTRAINT edf_edif_religiosa_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_p ADD CONSTRAINT edf_edif_religiosa_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_p ADD CONSTRAINT edf_edif_religiosa_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_religiosa_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -7479,114 +7608,115 @@ CREATE TABLE edgv.edf_edif_religiosa_a( cultura smallint NOT NULL, tipoedifrelig smallint NOT NULL, ensino smallint NOT NULL, - religiao varchar(100), + religiao varchar(255), crista smallint NOT NULL, administracao smallint NOT NULL, classeativecon smallint NOT NULL, divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_religiosa_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_religiosa_a_geom ON edgv.edf_edif_religiosa_a USING gist (geom); +)# +CREATE INDEX edf_edif_religiosa_a_geom ON edgv.edf_edif_religiosa_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_religiosa_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_religiosa_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_religiosa_a ADD CONSTRAINT edf_edif_religiosa_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_a ADD CONSTRAINT edf_edif_religiosa_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_a ADD CONSTRAINT edf_edif_religiosa_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_a ADD CONSTRAINT edf_edif_religiosa_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_a ADD CONSTRAINT edf_edif_religiosa_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_a ADD CONSTRAINT edf_edif_religiosa_a_tipoedifrelig_fk FOREIGN KEY (tipoedifrelig) REFERENCES dominios.tipo_edif_relig (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN tipoedifrelig SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN tipoedifrelig SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_a ADD CONSTRAINT edf_edif_religiosa_a_ensino_fk FOREIGN KEY (ensino) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN ensino SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN ensino SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_a ADD CONSTRAINT edf_edif_religiosa_a_crista_fk FOREIGN KEY (crista) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN crista SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN crista SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_a ADD CONSTRAINT edf_edif_religiosa_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_a ADD CONSTRAINT edf_edif_religiosa_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_a ADD CONSTRAINT edf_edif_religiosa_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_a ADD CONSTRAINT edf_edif_religiosa_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_religiosa_a ADD CONSTRAINT edf_edif_religiosa_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_religiosa_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_ext_mineral_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -7600,86 +7730,87 @@ CREATE TABLE edgv.edf_edif_ext_mineral_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_ext_mineral_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_ext_mineral_p_geom ON edgv.edf_edif_ext_mineral_p USING gist (geom); +)# +CREATE INDEX edf_edif_ext_mineral_p_geom ON edgv.edf_edif_ext_mineral_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_ext_mineral_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_ext_mineral_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_ext_mineral_p ADD CONSTRAINT edf_edif_ext_mineral_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_p ADD CONSTRAINT edf_edif_ext_mineral_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_p ADD CONSTRAINT edf_edif_ext_mineral_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_p ADD CONSTRAINT edf_edif_ext_mineral_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_p ADD CONSTRAINT edf_edif_ext_mineral_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_p ADD CONSTRAINT edf_edif_ext_mineral_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_p ADD CONSTRAINT edf_edif_ext_mineral_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_p ADD CONSTRAINT edf_edif_ext_mineral_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_p ADD CONSTRAINT edf_edif_ext_mineral_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_p ADD CONSTRAINT edf_edif_ext_mineral_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_ext_mineral_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -7693,86 +7824,87 @@ CREATE TABLE edgv.edf_edif_ext_mineral_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_ext_mineral_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_ext_mineral_a_geom ON edgv.edf_edif_ext_mineral_a USING gist (geom); +)# +CREATE INDEX edf_edif_ext_mineral_a_geom ON edgv.edf_edif_ext_mineral_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_ext_mineral_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_ext_mineral_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_ext_mineral_a ADD CONSTRAINT edf_edif_ext_mineral_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_a ADD CONSTRAINT edf_edif_ext_mineral_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_a ADD CONSTRAINT edf_edif_ext_mineral_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_a ADD CONSTRAINT edf_edif_ext_mineral_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_a ADD CONSTRAINT edf_edif_ext_mineral_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_a ADD CONSTRAINT edf_edif_ext_mineral_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_a ADD CONSTRAINT edf_edif_ext_mineral_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_a ADD CONSTRAINT edf_edif_ext_mineral_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_a ADD CONSTRAINT edf_edif_ext_mineral_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ext_mineral_a ADD CONSTRAINT edf_edif_ext_mineral_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ext_mineral_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_constr_est_med_fen_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -7786,86 +7918,87 @@ CREATE TABLE edgv.edf_edif_constr_est_med_fen_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_constr_est_med_fen_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_constr_est_med_fen_p_geom ON edgv.edf_edif_constr_est_med_fen_p USING gist (geom); +)# +CREATE INDEX edf_edif_constr_est_med_fen_p_geom ON edgv.edf_edif_constr_est_med_fen_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ADD CONSTRAINT edf_edif_constr_est_med_fen_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ADD CONSTRAINT edf_edif_constr_est_med_fen_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ADD CONSTRAINT edf_edif_constr_est_med_fen_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ADD CONSTRAINT edf_edif_constr_est_med_fen_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ADD CONSTRAINT edf_edif_constr_est_med_fen_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ADD CONSTRAINT edf_edif_constr_est_med_fen_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ADD CONSTRAINT edf_edif_constr_est_med_fen_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ADD CONSTRAINT edf_edif_constr_est_med_fen_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ADD CONSTRAINT edf_edif_constr_est_med_fen_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ADD CONSTRAINT edf_edif_constr_est_med_fen_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_constr_est_med_fen_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -7879,86 +8012,87 @@ CREATE TABLE edgv.edf_edif_constr_est_med_fen_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_constr_est_med_fen_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_constr_est_med_fen_a_geom ON edgv.edf_edif_constr_est_med_fen_a USING gist (geom); +)# +CREATE INDEX edf_edif_constr_est_med_fen_a_geom ON edgv.edf_edif_constr_est_med_fen_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ADD CONSTRAINT edf_edif_constr_est_med_fen_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ADD CONSTRAINT edf_edif_constr_est_med_fen_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ADD CONSTRAINT edf_edif_constr_est_med_fen_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ADD CONSTRAINT edf_edif_constr_est_med_fen_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ADD CONSTRAINT edf_edif_constr_est_med_fen_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ADD CONSTRAINT edf_edif_constr_est_med_fen_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ADD CONSTRAINT edf_edif_constr_est_med_fen_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ADD CONSTRAINT edf_edif_constr_est_med_fen_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ADD CONSTRAINT edf_edif_constr_est_med_fen_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ADD CONSTRAINT edf_edif_constr_est_med_fen_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_est_med_fen_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_ensino_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -7972,86 +8106,87 @@ CREATE TABLE edgv.edf_edif_ensino_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_ensino_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_ensino_p_geom ON edgv.edf_edif_ensino_p USING gist (geom); +)# +CREATE INDEX edf_edif_ensino_p_geom ON edgv.edf_edif_ensino_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_ensino_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_ensino_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_ensino_p ADD CONSTRAINT edf_edif_ensino_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_p ADD CONSTRAINT edf_edif_ensino_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_p ADD CONSTRAINT edf_edif_ensino_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_p ADD CONSTRAINT edf_edif_ensino_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_p ADD CONSTRAINT edf_edif_ensino_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_p ADD CONSTRAINT edf_edif_ensino_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_p ADD CONSTRAINT edf_edif_ensino_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_p ADD CONSTRAINT edf_edif_ensino_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_p ADD CONSTRAINT edf_edif_ensino_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_p ADD CONSTRAINT edf_edif_ensino_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_ensino_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -8065,86 +8200,87 @@ CREATE TABLE edgv.edf_edif_ensino_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_ensino_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_ensino_a_geom ON edgv.edf_edif_ensino_a USING gist (geom); +)# +CREATE INDEX edf_edif_ensino_a_geom ON edgv.edf_edif_ensino_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_ensino_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_ensino_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_ensino_a ADD CONSTRAINT edf_edif_ensino_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_a ADD CONSTRAINT edf_edif_ensino_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_a ADD CONSTRAINT edf_edif_ensino_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_a ADD CONSTRAINT edf_edif_ensino_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_a ADD CONSTRAINT edf_edif_ensino_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_a ADD CONSTRAINT edf_edif_ensino_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_a ADD CONSTRAINT edf_edif_ensino_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_a ADD CONSTRAINT edf_edif_ensino_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_a ADD CONSTRAINT edf_edif_ensino_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_ensino_a ADD CONSTRAINT edf_edif_ensino_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_ensino_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_posto_combustivel_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -8160,103 +8296,105 @@ CREATE TABLE edgv.edf_posto_combustivel_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_posto_combustivel_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_posto_combustivel_p_geom ON edgv.edf_posto_combustivel_p USING gist (geom); +)# +CREATE INDEX edf_posto_combustivel_p_geom ON edgv.edf_posto_combustivel_p USING gist (geom)# -ALTER TABLE edgv.edf_posto_combustivel_p OWNER TO postgres; +ALTER TABLE edgv.edf_posto_combustivel_p OWNER TO postgres# ALTER TABLE edgv.edf_posto_combustivel_p ADD CONSTRAINT edf_posto_combustivel_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_p ADD CONSTRAINT edf_posto_combustivel_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_p ADD CONSTRAINT edf_posto_combustivel_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_p ADD CONSTRAINT edf_posto_combustivel_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_p ADD CONSTRAINT edf_posto_combustivel_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_p ADD CONSTRAINT edf_posto_combustivel_p_tipoedifcomercserv_fk FOREIGN KEY (tipoedifcomercserv) REFERENCES dominios.tipo_edif_comerc_serv (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_combustivel_p - ADD CONSTRAINT edf_posto_combustivel_p_tipoedifcomercserv_check - CHECK (tipoedifcomercserv = ANY(ARRAY[19 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN tipoedifcomercserv SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_combustivel_p_tipoedifcomercserv_check + CHECK (tipoedifcomercserv = ANY(ARRAY[19 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN tipoedifcomercserv SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_p ADD CONSTRAINT edf_posto_combustivel_p_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN finalidade SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN finalidade SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_p ADD CONSTRAINT edf_posto_combustivel_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_p ADD CONSTRAINT edf_posto_combustivel_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_p ADD CONSTRAINT edf_posto_combustivel_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_p ADD CONSTRAINT edf_posto_combustivel_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_p ADD CONSTRAINT edf_posto_combustivel_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_posto_combustivel_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -8272,103 +8410,105 @@ CREATE TABLE edgv.edf_posto_combustivel_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_posto_combustivel_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_posto_combustivel_a_geom ON edgv.edf_posto_combustivel_a USING gist (geom); +)# +CREATE INDEX edf_posto_combustivel_a_geom ON edgv.edf_posto_combustivel_a USING gist (geom)# -ALTER TABLE edgv.edf_posto_combustivel_a OWNER TO postgres; +ALTER TABLE edgv.edf_posto_combustivel_a OWNER TO postgres# ALTER TABLE edgv.edf_posto_combustivel_a ADD CONSTRAINT edf_posto_combustivel_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_a ADD CONSTRAINT edf_posto_combustivel_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_a ADD CONSTRAINT edf_posto_combustivel_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_a ADD CONSTRAINT edf_posto_combustivel_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_a ADD CONSTRAINT edf_posto_combustivel_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_a ADD CONSTRAINT edf_posto_combustivel_a_tipoedifcomercserv_fk FOREIGN KEY (tipoedifcomercserv) REFERENCES dominios.tipo_edif_comerc_serv (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_combustivel_a - ADD CONSTRAINT edf_posto_combustivel_a_tipoedifcomercserv_check - CHECK (tipoedifcomercserv = ANY(ARRAY[19 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN tipoedifcomercserv SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_combustivel_a_tipoedifcomercserv_check + CHECK (tipoedifcomercserv = ANY(ARRAY[19 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN tipoedifcomercserv SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_a ADD CONSTRAINT edf_posto_combustivel_a_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN finalidade SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN finalidade SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_a ADD CONSTRAINT edf_posto_combustivel_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_a ADD CONSTRAINT edf_posto_combustivel_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_a ADD CONSTRAINT edf_posto_combustivel_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_a ADD CONSTRAINT edf_posto_combustivel_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_combustivel_a ADD CONSTRAINT edf_posto_combustivel_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_combustivel_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_posto_policia_militar_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -8385,116 +8525,120 @@ CREATE TABLE edgv.edf_posto_policia_militar_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_posto_policia_militar_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_posto_policia_militar_p_geom ON edgv.edf_posto_policia_militar_p USING gist (geom); +)# +CREATE INDEX edf_posto_policia_militar_p_geom ON edgv.edf_posto_policia_militar_p USING gist (geom)# -ALTER TABLE edgv.edf_posto_policia_militar_p OWNER TO postgres; +ALTER TABLE edgv.edf_posto_policia_militar_p OWNER TO postgres# ALTER TABLE edgv.edf_posto_policia_militar_p ADD CONSTRAINT edf_posto_policia_militar_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_p ADD CONSTRAINT edf_posto_policia_militar_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_p ADD CONSTRAINT edf_posto_policia_militar_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_p ADD CONSTRAINT edf_posto_policia_militar_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_p ADD CONSTRAINT edf_posto_policia_militar_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_p ADD CONSTRAINT edf_posto_policia_militar_p_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_policia_militar_p - ADD CONSTRAINT edf_posto_policia_militar_p_tipousoedif_check - CHECK (tipousoedif = ANY(ARRAY[6 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN tipousoedif SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_policia_militar_p_tipousoedif_check + CHECK (tipousoedif = ANY(ARRAY[6 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_p ADD CONSTRAINT edf_posto_policia_militar_p_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_policia_militar_p - ADD CONSTRAINT edf_posto_policia_militar_p_jurisdicao_check - CHECK (jurisdicao = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN jurisdicao SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_policia_militar_p_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_p ADD CONSTRAINT edf_posto_policia_militar_p_tipoinstalmilitar_fk FOREIGN KEY (tipoinstalmilitar) REFERENCES dominios.tipo_instal_militar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_policia_militar_p - ADD CONSTRAINT edf_posto_policia_militar_p_tipoinstalmilitar_check - CHECK (tipoinstalmilitar = ANY(ARRAY[22 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN tipoinstalmilitar SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_policia_militar_p_tipoinstalmilitar_check + CHECK (tipoinstalmilitar = ANY(ARRAY[22 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN tipoinstalmilitar SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_p ADD CONSTRAINT edf_posto_policia_militar_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_p ADD CONSTRAINT edf_posto_policia_militar_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_p ADD CONSTRAINT edf_posto_policia_militar_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_p ADD CONSTRAINT edf_posto_policia_militar_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_p ADD CONSTRAINT edf_posto_policia_militar_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_posto_policia_militar_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -8511,116 +8655,120 @@ CREATE TABLE edgv.edf_posto_policia_militar_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_posto_policia_militar_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_posto_policia_militar_a_geom ON edgv.edf_posto_policia_militar_a USING gist (geom); +)# +CREATE INDEX edf_posto_policia_militar_a_geom ON edgv.edf_posto_policia_militar_a USING gist (geom)# -ALTER TABLE edgv.edf_posto_policia_militar_a OWNER TO postgres; +ALTER TABLE edgv.edf_posto_policia_militar_a OWNER TO postgres# ALTER TABLE edgv.edf_posto_policia_militar_a ADD CONSTRAINT edf_posto_policia_militar_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_a ADD CONSTRAINT edf_posto_policia_militar_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_a ADD CONSTRAINT edf_posto_policia_militar_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_a ADD CONSTRAINT edf_posto_policia_militar_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_a ADD CONSTRAINT edf_posto_policia_militar_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_a ADD CONSTRAINT edf_posto_policia_militar_a_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_policia_militar_a - ADD CONSTRAINT edf_posto_policia_militar_a_tipousoedif_check - CHECK (tipousoedif = ANY(ARRAY[6 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN tipousoedif SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_policia_militar_a_tipousoedif_check + CHECK (tipousoedif = ANY(ARRAY[6 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_a ADD CONSTRAINT edf_posto_policia_militar_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_policia_militar_a - ADD CONSTRAINT edf_posto_policia_militar_a_jurisdicao_check - CHECK (jurisdicao = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN jurisdicao SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_policia_militar_a_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_a ADD CONSTRAINT edf_posto_policia_militar_a_tipoinstalmilitar_fk FOREIGN KEY (tipoinstalmilitar) REFERENCES dominios.tipo_instal_militar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_policia_militar_a - ADD CONSTRAINT edf_posto_policia_militar_a_tipoinstalmilitar_check - CHECK (tipoinstalmilitar = ANY(ARRAY[22 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN tipoinstalmilitar SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_policia_militar_a_tipoinstalmilitar_check + CHECK (tipoinstalmilitar = ANY(ARRAY[22 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN tipoinstalmilitar SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_a ADD CONSTRAINT edf_posto_policia_militar_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_a ADD CONSTRAINT edf_posto_policia_militar_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_a ADD CONSTRAINT edf_posto_policia_militar_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_a ADD CONSTRAINT edf_posto_policia_militar_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_militar_a ADD CONSTRAINT edf_posto_policia_militar_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_militar_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_hab_indigena_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -8636,100 +8784,101 @@ CREATE TABLE edgv.edf_hab_indigena_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_hab_indigena_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_hab_indigena_p_geom ON edgv.edf_hab_indigena_p USING gist (geom); +)# +CREATE INDEX edf_hab_indigena_p_geom ON edgv.edf_hab_indigena_p USING gist (geom)# -ALTER TABLE edgv.edf_hab_indigena_p OWNER TO postgres; +ALTER TABLE edgv.edf_hab_indigena_p OWNER TO postgres# ALTER TABLE edgv.edf_hab_indigena_p ADD CONSTRAINT edf_hab_indigena_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_p ADD CONSTRAINT edf_hab_indigena_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_p ADD CONSTRAINT edf_hab_indigena_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_p ADD CONSTRAINT edf_hab_indigena_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_p ADD CONSTRAINT edf_hab_indigena_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_p ADD CONSTRAINT edf_hab_indigena_p_coletiva_fk FOREIGN KEY (coletiva) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN coletiva SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN coletiva SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_p ADD CONSTRAINT edf_hab_indigena_p_isolada_fk FOREIGN KEY (isolada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN isolada SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN isolada SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_p ADD CONSTRAINT edf_hab_indigena_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_p ADD CONSTRAINT edf_hab_indigena_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_p ADD CONSTRAINT edf_hab_indigena_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_p ADD CONSTRAINT edf_hab_indigena_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_p ADD CONSTRAINT edf_hab_indigena_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_hab_indigena_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -8745,100 +8894,101 @@ CREATE TABLE edgv.edf_hab_indigena_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_hab_indigena_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_hab_indigena_a_geom ON edgv.edf_hab_indigena_a USING gist (geom); +)# +CREATE INDEX edf_hab_indigena_a_geom ON edgv.edf_hab_indigena_a USING gist (geom)# -ALTER TABLE edgv.edf_hab_indigena_a OWNER TO postgres; +ALTER TABLE edgv.edf_hab_indigena_a OWNER TO postgres# ALTER TABLE edgv.edf_hab_indigena_a ADD CONSTRAINT edf_hab_indigena_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_a ADD CONSTRAINT edf_hab_indigena_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_a ADD CONSTRAINT edf_hab_indigena_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_a ADD CONSTRAINT edf_hab_indigena_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_a ADD CONSTRAINT edf_hab_indigena_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_a ADD CONSTRAINT edf_hab_indigena_a_coletiva_fk FOREIGN KEY (coletiva) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN coletiva SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN coletiva SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_a ADD CONSTRAINT edf_hab_indigena_a_isolada_fk FOREIGN KEY (isolada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN isolada SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN isolada SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_a ADD CONSTRAINT edf_hab_indigena_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_a ADD CONSTRAINT edf_hab_indigena_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_a ADD CONSTRAINT edf_hab_indigena_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_a ADD CONSTRAINT edf_hab_indigena_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_hab_indigena_a ADD CONSTRAINT edf_hab_indigena_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_hab_indigena_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_desenv_social_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -8847,8 +8997,8 @@ CREATE TABLE edgv.edf_edif_desenv_social_p( alturaaproximada real, turistica smallint NOT NULL, cultura smallint NOT NULL, - sigla varchar(80), - codequipdesenvsocial varchar(80), + sigla varchar(255), + codequipdesenvsocial varchar(255), localizacaoequipdesenvsocial smallint NOT NULL, tipoequipdesenvsocial smallint NOT NULL, administracao smallint NOT NULL, @@ -8856,100 +9006,101 @@ CREATE TABLE edgv.edf_edif_desenv_social_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_desenv_social_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_desenv_social_p_geom ON edgv.edf_edif_desenv_social_p USING gist (geom); +)# +CREATE INDEX edf_edif_desenv_social_p_geom ON edgv.edf_edif_desenv_social_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_desenv_social_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_desenv_social_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_desenv_social_p ADD CONSTRAINT edf_edif_desenv_social_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_p ADD CONSTRAINT edf_edif_desenv_social_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_p ADD CONSTRAINT edf_edif_desenv_social_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_p ADD CONSTRAINT edf_edif_desenv_social_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_p ADD CONSTRAINT edf_edif_desenv_social_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_p ADD CONSTRAINT edf_edif_desenv_social_p_localizacaoequipdesenvsocial_fk FOREIGN KEY (localizacaoequipdesenvsocial) REFERENCES dominios.local_equip_desenv_social (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN localizacaoequipdesenvsocial SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN localizacaoequipdesenvsocial SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_p ADD CONSTRAINT edf_edif_desenv_social_p_tipoequipdesenvsocial_fk FOREIGN KEY (tipoequipdesenvsocial) REFERENCES dominios.tipo_equip_desenv_social (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN tipoequipdesenvsocial SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN tipoequipdesenvsocial SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_p ADD CONSTRAINT edf_edif_desenv_social_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_p ADD CONSTRAINT edf_edif_desenv_social_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_p ADD CONSTRAINT edf_edif_desenv_social_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_p ADD CONSTRAINT edf_edif_desenv_social_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_p ADD CONSTRAINT edf_edif_desenv_social_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_desenv_social_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -8958,8 +9109,8 @@ CREATE TABLE edgv.edf_edif_desenv_social_a( alturaaproximada real, turistica smallint NOT NULL, cultura smallint NOT NULL, - sigla varchar(80), - codequipdesenvsocial varchar(80), + sigla varchar(255), + codequipdesenvsocial varchar(255), localizacaoequipdesenvsocial smallint NOT NULL, tipoequipdesenvsocial smallint NOT NULL, administracao smallint NOT NULL, @@ -8967,100 +9118,101 @@ CREATE TABLE edgv.edf_edif_desenv_social_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_desenv_social_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_desenv_social_a_geom ON edgv.edf_edif_desenv_social_a USING gist (geom); +)# +CREATE INDEX edf_edif_desenv_social_a_geom ON edgv.edf_edif_desenv_social_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_desenv_social_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_desenv_social_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_desenv_social_a ADD CONSTRAINT edf_edif_desenv_social_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_a ADD CONSTRAINT edf_edif_desenv_social_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_a ADD CONSTRAINT edf_edif_desenv_social_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_a ADD CONSTRAINT edf_edif_desenv_social_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_a ADD CONSTRAINT edf_edif_desenv_social_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_a ADD CONSTRAINT edf_edif_desenv_social_a_localizacaoequipdesenvsocial_fk FOREIGN KEY (localizacaoequipdesenvsocial) REFERENCES dominios.local_equip_desenv_social (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN localizacaoequipdesenvsocial SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN localizacaoequipdesenvsocial SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_a ADD CONSTRAINT edf_edif_desenv_social_a_tipoequipdesenvsocial_fk FOREIGN KEY (tipoequipdesenvsocial) REFERENCES dominios.tipo_equip_desenv_social (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN tipoequipdesenvsocial SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN tipoequipdesenvsocial SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_a ADD CONSTRAINT edf_edif_desenv_social_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_a ADD CONSTRAINT edf_edif_desenv_social_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_a ADD CONSTRAINT edf_edif_desenv_social_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_a ADD CONSTRAINT edf_edif_desenv_social_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_desenv_social_a ADD CONSTRAINT edf_edif_desenv_social_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_desenv_social_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_constr_lazer_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -9075,93 +9227,94 @@ CREATE TABLE edgv.edf_edif_constr_lazer_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_constr_lazer_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_constr_lazer_p_geom ON edgv.edf_edif_constr_lazer_p USING gist (geom); +)# +CREATE INDEX edf_edif_constr_lazer_p_geom ON edgv.edf_edif_constr_lazer_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_constr_lazer_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_constr_lazer_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_constr_lazer_p ADD CONSTRAINT edf_edif_constr_lazer_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_p ADD CONSTRAINT edf_edif_constr_lazer_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_p ADD CONSTRAINT edf_edif_constr_lazer_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_p ADD CONSTRAINT edf_edif_constr_lazer_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_p ADD CONSTRAINT edf_edif_constr_lazer_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_p ADD CONSTRAINT edf_edif_constr_lazer_p_tipoediflazer_fk FOREIGN KEY (tipoediflazer) REFERENCES dominios.tipo_edif_lazer (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN tipoediflazer SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN tipoediflazer SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_p ADD CONSTRAINT edf_edif_constr_lazer_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_p ADD CONSTRAINT edf_edif_constr_lazer_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_p ADD CONSTRAINT edf_edif_constr_lazer_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_p ADD CONSTRAINT edf_edif_constr_lazer_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_p ADD CONSTRAINT edf_edif_constr_lazer_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_constr_lazer_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -9176,93 +9329,94 @@ CREATE TABLE edgv.edf_edif_constr_lazer_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_constr_lazer_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_constr_lazer_a_geom ON edgv.edf_edif_constr_lazer_a USING gist (geom); +)# +CREATE INDEX edf_edif_constr_lazer_a_geom ON edgv.edf_edif_constr_lazer_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_constr_lazer_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_constr_lazer_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_constr_lazer_a ADD CONSTRAINT edf_edif_constr_lazer_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_a ADD CONSTRAINT edf_edif_constr_lazer_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_a ADD CONSTRAINT edf_edif_constr_lazer_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_a ADD CONSTRAINT edf_edif_constr_lazer_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_a ADD CONSTRAINT edf_edif_constr_lazer_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_a ADD CONSTRAINT edf_edif_constr_lazer_a_tipoediflazer_fk FOREIGN KEY (tipoediflazer) REFERENCES dominios.tipo_edif_lazer (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN tipoediflazer SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN tipoediflazer SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_a ADD CONSTRAINT edf_edif_constr_lazer_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_a ADD CONSTRAINT edf_edif_constr_lazer_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_a ADD CONSTRAINT edf_edif_constr_lazer_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_a ADD CONSTRAINT edf_edif_constr_lazer_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_lazer_a ADD CONSTRAINT edf_edif_constr_lazer_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_lazer_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_energia_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -9277,93 +9431,94 @@ CREATE TABLE edgv.edf_edif_energia_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_energia_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_energia_p_geom ON edgv.edf_edif_energia_p USING gist (geom); +)# +CREATE INDEX edf_edif_energia_p_geom ON edgv.edf_edif_energia_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_energia_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_energia_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_energia_p ADD CONSTRAINT edf_edif_energia_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_p ADD CONSTRAINT edf_edif_energia_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_p ADD CONSTRAINT edf_edif_energia_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_p ADD CONSTRAINT edf_edif_energia_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_p ADD CONSTRAINT edf_edif_energia_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_p ADD CONSTRAINT edf_edif_energia_p_tipoedifenergia_fk FOREIGN KEY (tipoedifenergia) REFERENCES dominios.tipo_edif_energia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN tipoedifenergia SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN tipoedifenergia SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_p ADD CONSTRAINT edf_edif_energia_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_p ADD CONSTRAINT edf_edif_energia_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_p ADD CONSTRAINT edf_edif_energia_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_p ADD CONSTRAINT edf_edif_energia_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_p ADD CONSTRAINT edf_edif_energia_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_energia_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -9378,93 +9533,94 @@ CREATE TABLE edgv.edf_edif_energia_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_energia_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_energia_a_geom ON edgv.edf_edif_energia_a USING gist (geom); +)# +CREATE INDEX edf_edif_energia_a_geom ON edgv.edf_edif_energia_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_energia_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_energia_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_energia_a ADD CONSTRAINT edf_edif_energia_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_a ADD CONSTRAINT edf_edif_energia_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_a ADD CONSTRAINT edf_edif_energia_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_a ADD CONSTRAINT edf_edif_energia_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_a ADD CONSTRAINT edf_edif_energia_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_a ADD CONSTRAINT edf_edif_energia_a_tipoedifenergia_fk FOREIGN KEY (tipoedifenergia) REFERENCES dominios.tipo_edif_energia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN tipoedifenergia SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN tipoedifenergia SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_a ADD CONSTRAINT edf_edif_energia_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_a ADD CONSTRAINT edf_edif_energia_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_a ADD CONSTRAINT edf_edif_energia_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_a ADD CONSTRAINT edf_edif_energia_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_energia_a ADD CONSTRAINT edf_edif_energia_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_energia_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_industrial_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -9479,93 +9635,94 @@ CREATE TABLE edgv.edf_edif_industrial_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_industrial_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_industrial_p_geom ON edgv.edf_edif_industrial_p USING gist (geom); +)# +CREATE INDEX edf_edif_industrial_p_geom ON edgv.edf_edif_industrial_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_industrial_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_industrial_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_industrial_p ADD CONSTRAINT edf_edif_industrial_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_p ADD CONSTRAINT edf_edif_industrial_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_p ADD CONSTRAINT edf_edif_industrial_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_p ADD CONSTRAINT edf_edif_industrial_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_p ADD CONSTRAINT edf_edif_industrial_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_p ADD CONSTRAINT edf_edif_industrial_p_chamine_fk FOREIGN KEY (chamine) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN chamine SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN chamine SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_p ADD CONSTRAINT edf_edif_industrial_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_p ADD CONSTRAINT edf_edif_industrial_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_p ADD CONSTRAINT edf_edif_industrial_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_p ADD CONSTRAINT edf_edif_industrial_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_p ADD CONSTRAINT edf_edif_industrial_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_industrial_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -9580,93 +9737,94 @@ CREATE TABLE edgv.edf_edif_industrial_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_industrial_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_industrial_a_geom ON edgv.edf_edif_industrial_a USING gist (geom); +)# +CREATE INDEX edf_edif_industrial_a_geom ON edgv.edf_edif_industrial_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_industrial_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_industrial_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_industrial_a ADD CONSTRAINT edf_edif_industrial_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_a ADD CONSTRAINT edf_edif_industrial_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_a ADD CONSTRAINT edf_edif_industrial_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_a ADD CONSTRAINT edf_edif_industrial_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_a ADD CONSTRAINT edf_edif_industrial_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_a ADD CONSTRAINT edf_edif_industrial_a_chamine_fk FOREIGN KEY (chamine) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN chamine SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN chamine SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_a ADD CONSTRAINT edf_edif_industrial_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_a ADD CONSTRAINT edf_edif_industrial_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_a ADD CONSTRAINT edf_edif_industrial_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_a ADD CONSTRAINT edf_edif_industrial_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_industrial_a ADD CONSTRAINT edf_edif_industrial_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_industrial_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_constr_portuaria_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -9677,106 +9835,107 @@ CREATE TABLE edgv.edf_edif_constr_portuaria_p( cultura smallint NOT NULL, tipoedifport smallint NOT NULL, jurisdicao smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), administracao smallint NOT NULL, classeativecon smallint NOT NULL, divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_constr_portuaria_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_constr_portuaria_p_geom ON edgv.edf_edif_constr_portuaria_p USING gist (geom); +)# +CREATE INDEX edf_edif_constr_portuaria_p_geom ON edgv.edf_edif_constr_portuaria_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_constr_portuaria_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_constr_portuaria_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_constr_portuaria_p ADD CONSTRAINT edf_edif_constr_portuaria_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_p ADD CONSTRAINT edf_edif_constr_portuaria_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_p ADD CONSTRAINT edf_edif_constr_portuaria_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_p ADD CONSTRAINT edf_edif_constr_portuaria_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_p ADD CONSTRAINT edf_edif_constr_portuaria_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_p ADD CONSTRAINT edf_edif_constr_portuaria_p_tipoedifport_fk FOREIGN KEY (tipoedifport) REFERENCES dominios.tipo_edif_port (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN tipoedifport SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN tipoedifport SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_p ADD CONSTRAINT edf_edif_constr_portuaria_p_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_p ADD CONSTRAINT edf_edif_constr_portuaria_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_p ADD CONSTRAINT edf_edif_constr_portuaria_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_p ADD CONSTRAINT edf_edif_constr_portuaria_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_p ADD CONSTRAINT edf_edif_constr_portuaria_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_p ADD CONSTRAINT edf_edif_constr_portuaria_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_constr_portuaria_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -9787,106 +9946,107 @@ CREATE TABLE edgv.edf_edif_constr_portuaria_a( cultura smallint NOT NULL, tipoedifport smallint NOT NULL, jurisdicao smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), administracao smallint NOT NULL, classeativecon smallint NOT NULL, divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_constr_portuaria_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_constr_portuaria_a_geom ON edgv.edf_edif_constr_portuaria_a USING gist (geom); +)# +CREATE INDEX edf_edif_constr_portuaria_a_geom ON edgv.edf_edif_constr_portuaria_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_constr_portuaria_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_constr_portuaria_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_constr_portuaria_a ADD CONSTRAINT edf_edif_constr_portuaria_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_a ADD CONSTRAINT edf_edif_constr_portuaria_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_a ADD CONSTRAINT edf_edif_constr_portuaria_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_a ADD CONSTRAINT edf_edif_constr_portuaria_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_a ADD CONSTRAINT edf_edif_constr_portuaria_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_a ADD CONSTRAINT edf_edif_constr_portuaria_a_tipoedifport_fk FOREIGN KEY (tipoedifport) REFERENCES dominios.tipo_edif_port (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN tipoedifport SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN tipoedifport SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_a ADD CONSTRAINT edf_edif_constr_portuaria_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_a ADD CONSTRAINT edf_edif_constr_portuaria_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_a ADD CONSTRAINT edf_edif_constr_portuaria_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_a ADD CONSTRAINT edf_edif_constr_portuaria_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_a ADD CONSTRAINT edf_edif_constr_portuaria_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_constr_portuaria_a ADD CONSTRAINT edf_edif_constr_portuaria_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_constr_portuaria_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_comunic_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -9902,100 +10062,101 @@ CREATE TABLE edgv.edf_edif_comunic_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_comunic_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_comunic_p_geom ON edgv.edf_edif_comunic_p USING gist (geom); +)# +CREATE INDEX edf_edif_comunic_p_geom ON edgv.edf_edif_comunic_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_comunic_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_comunic_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_comunic_p ADD CONSTRAINT edf_edif_comunic_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_p ADD CONSTRAINT edf_edif_comunic_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_p ADD CONSTRAINT edf_edif_comunic_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_p ADD CONSTRAINT edf_edif_comunic_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_p ADD CONSTRAINT edf_edif_comunic_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_p ADD CONSTRAINT edf_edif_comunic_p_tipoedifcomunic_fk FOREIGN KEY (tipoedifcomunic) REFERENCES dominios.tipo_edif_comunic (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN tipoedifcomunic SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN tipoedifcomunic SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_p ADD CONSTRAINT edf_edif_comunic_p_modalidade_fk FOREIGN KEY (modalidade) REFERENCES dominios.modalidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN modalidade SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN modalidade SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_p ADD CONSTRAINT edf_edif_comunic_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_p ADD CONSTRAINT edf_edif_comunic_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_p ADD CONSTRAINT edf_edif_comunic_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_p ADD CONSTRAINT edf_edif_comunic_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_p ADD CONSTRAINT edf_edif_comunic_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_comunic_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -10011,100 +10172,101 @@ CREATE TABLE edgv.edf_edif_comunic_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_comunic_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_comunic_a_geom ON edgv.edf_edif_comunic_a USING gist (geom); +)# +CREATE INDEX edf_edif_comunic_a_geom ON edgv.edf_edif_comunic_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_comunic_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_comunic_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_comunic_a ADD CONSTRAINT edf_edif_comunic_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_a ADD CONSTRAINT edf_edif_comunic_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_a ADD CONSTRAINT edf_edif_comunic_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_a ADD CONSTRAINT edf_edif_comunic_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_a ADD CONSTRAINT edf_edif_comunic_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_a ADD CONSTRAINT edf_edif_comunic_a_tipoedifcomunic_fk FOREIGN KEY (tipoedifcomunic) REFERENCES dominios.tipo_edif_comunic (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN tipoedifcomunic SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN tipoedifcomunic SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_a ADD CONSTRAINT edf_edif_comunic_a_modalidade_fk FOREIGN KEY (modalidade) REFERENCES dominios.modalidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN modalidade SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN modalidade SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_a ADD CONSTRAINT edf_edif_comunic_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_a ADD CONSTRAINT edf_edif_comunic_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_a ADD CONSTRAINT edf_edif_comunic_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_a ADD CONSTRAINT edf_edif_comunic_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_comunic_a ADD CONSTRAINT edf_edif_comunic_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_comunic_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_posto_policia_rod_federal_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -10121,116 +10283,120 @@ CREATE TABLE edgv.edf_posto_policia_rod_federal_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_posto_policia_rod_federal_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_posto_policia_rod_federal_p_geom ON edgv.edf_posto_policia_rod_federal_p USING gist (geom); +)# +CREATE INDEX edf_posto_policia_rod_federal_p_geom ON edgv.edf_posto_policia_rod_federal_p USING gist (geom)# -ALTER TABLE edgv.edf_posto_policia_rod_federal_p OWNER TO postgres; +ALTER TABLE edgv.edf_posto_policia_rod_federal_p OWNER TO postgres# ALTER TABLE edgv.edf_posto_policia_rod_federal_p ADD CONSTRAINT edf_posto_policia_rod_federal_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_p ADD CONSTRAINT edf_posto_policia_rod_federal_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_p ADD CONSTRAINT edf_posto_policia_rod_federal_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_p ADD CONSTRAINT edf_posto_policia_rod_federal_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_p ADD CONSTRAINT edf_posto_policia_rod_federal_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_p ADD CONSTRAINT edf_posto_policia_rod_federal_p_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_policia_rod_federal_p - ADD CONSTRAINT edf_posto_policia_rod_federal_p_tipousoedif_check - CHECK (tipousoedif = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN tipousoedif SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_policia_rod_federal_p_tipousoedif_check + CHECK (tipousoedif = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_p ADD CONSTRAINT edf_posto_policia_rod_federal_p_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_policia_rod_federal_p - ADD CONSTRAINT edf_posto_policia_rod_federal_p_jurisdicao_check - CHECK (jurisdicao = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN jurisdicao SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_policia_rod_federal_p_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_p ADD CONSTRAINT edf_posto_policia_rod_federal_p_tipoedifpubcivil_fk FOREIGN KEY (tipoedifpubcivil) REFERENCES dominios.tipo_org_civil (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_policia_rod_federal_p - ADD CONSTRAINT edf_posto_policia_rod_federal_p_tipoedifpubcivil_check - CHECK (tipoedifpubcivil = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_policia_rod_federal_p_tipoedifpubcivil_check + CHECK (tipoedifpubcivil = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_p ADD CONSTRAINT edf_posto_policia_rod_federal_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_p ADD CONSTRAINT edf_posto_policia_rod_federal_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_p ADD CONSTRAINT edf_posto_policia_rod_federal_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_p ADD CONSTRAINT edf_posto_policia_rod_federal_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_p ADD CONSTRAINT edf_posto_policia_rod_federal_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_posto_policia_rod_federal_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -10247,116 +10413,120 @@ CREATE TABLE edgv.edf_posto_policia_rod_federal_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_posto_policia_rod_federal_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_posto_policia_rod_federal_a_geom ON edgv.edf_posto_policia_rod_federal_a USING gist (geom); +)# +CREATE INDEX edf_posto_policia_rod_federal_a_geom ON edgv.edf_posto_policia_rod_federal_a USING gist (geom)# -ALTER TABLE edgv.edf_posto_policia_rod_federal_a OWNER TO postgres; +ALTER TABLE edgv.edf_posto_policia_rod_federal_a OWNER TO postgres# ALTER TABLE edgv.edf_posto_policia_rod_federal_a ADD CONSTRAINT edf_posto_policia_rod_federal_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_a ADD CONSTRAINT edf_posto_policia_rod_federal_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_a ADD CONSTRAINT edf_posto_policia_rod_federal_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_a ADD CONSTRAINT edf_posto_policia_rod_federal_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_a ADD CONSTRAINT edf_posto_policia_rod_federal_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_a ADD CONSTRAINT edf_posto_policia_rod_federal_a_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_policia_rod_federal_a - ADD CONSTRAINT edf_posto_policia_rod_federal_a_tipousoedif_check - CHECK (tipousoedif = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN tipousoedif SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_policia_rod_federal_a_tipousoedif_check + CHECK (tipousoedif = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_a ADD CONSTRAINT edf_posto_policia_rod_federal_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_policia_rod_federal_a - ADD CONSTRAINT edf_posto_policia_rod_federal_a_jurisdicao_check - CHECK (jurisdicao = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN jurisdicao SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_policia_rod_federal_a_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_a ADD CONSTRAINT edf_posto_policia_rod_federal_a_tipoedifpubcivil_fk FOREIGN KEY (tipoedifpubcivil) REFERENCES dominios.tipo_org_civil (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_posto_policia_rod_federal_a - ADD CONSTRAINT edf_posto_policia_rod_federal_a_tipoedifpubcivil_check - CHECK (tipoedifpubcivil = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999; + ADD CONSTRAINT edf_posto_policia_rod_federal_a_tipoedifpubcivil_check + CHECK (tipoedifpubcivil = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_a ADD CONSTRAINT edf_posto_policia_rod_federal_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_a ADD CONSTRAINT edf_posto_policia_rod_federal_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_a ADD CONSTRAINT edf_posto_policia_rod_federal_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_a ADD CONSTRAINT edf_posto_policia_rod_federal_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_posto_policia_rod_federal_a ADD CONSTRAINT edf_posto_policia_rod_federal_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_posto_policia_rod_federal_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_pub_civil_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -10373,110 +10543,112 @@ CREATE TABLE edgv.edf_edif_pub_civil_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_pub_civil_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_pub_civil_p_geom ON edgv.edf_edif_pub_civil_p USING gist (geom); +)# +CREATE INDEX edf_edif_pub_civil_p_geom ON edgv.edf_edif_pub_civil_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_pub_civil_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_pub_civil_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_pub_civil_p ADD CONSTRAINT edf_edif_pub_civil_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_p ADD CONSTRAINT edf_edif_pub_civil_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_p ADD CONSTRAINT edf_edif_pub_civil_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_p ADD CONSTRAINT edf_edif_pub_civil_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_p ADD CONSTRAINT edf_edif_pub_civil_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_p ADD CONSTRAINT edf_edif_pub_civil_p_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN tipousoedif SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_p ADD CONSTRAINT edf_edif_pub_civil_p_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_p ADD CONSTRAINT edf_edif_pub_civil_p_tipoedifpubcivil_fk FOREIGN KEY (tipoedifpubcivil) REFERENCES dominios.tipo_org_civil (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_pub_civil_p - ADD CONSTRAINT edf_edif_pub_civil_p_tipoedifpubcivil_check - CHECK (tipoedifpubcivil = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 15 :: SMALLINT, 16 :: SMALLINT, 22 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_pub_civil_p_tipoedifpubcivil_check + CHECK (tipoedifpubcivil = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 15 :: SMALLINT, 16 :: SMALLINT, 22 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_p ADD CONSTRAINT edf_edif_pub_civil_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_p ADD CONSTRAINT edf_edif_pub_civil_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_p ADD CONSTRAINT edf_edif_pub_civil_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_p ADD CONSTRAINT edf_edif_pub_civil_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_p ADD CONSTRAINT edf_edif_pub_civil_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_pub_civil_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -10493,110 +10665,112 @@ CREATE TABLE edgv.edf_edif_pub_civil_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_pub_civil_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_pub_civil_a_geom ON edgv.edf_edif_pub_civil_a USING gist (geom); +)# +CREATE INDEX edf_edif_pub_civil_a_geom ON edgv.edf_edif_pub_civil_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_pub_civil_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_pub_civil_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_pub_civil_a ADD CONSTRAINT edf_edif_pub_civil_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_a ADD CONSTRAINT edf_edif_pub_civil_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_a ADD CONSTRAINT edf_edif_pub_civil_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_a ADD CONSTRAINT edf_edif_pub_civil_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_a ADD CONSTRAINT edf_edif_pub_civil_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_a ADD CONSTRAINT edf_edif_pub_civil_a_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN tipousoedif SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_a ADD CONSTRAINT edf_edif_pub_civil_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_a ADD CONSTRAINT edf_edif_pub_civil_a_tipoedifpubcivil_fk FOREIGN KEY (tipoedifpubcivil) REFERENCES dominios.tipo_org_civil (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_pub_civil_a - ADD CONSTRAINT edf_edif_pub_civil_a_tipoedifpubcivil_check - CHECK (tipoedifpubcivil = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 15 :: SMALLINT, 16 :: SMALLINT, 22 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_pub_civil_a_tipoedifpubcivil_check + CHECK (tipoedifpubcivil = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 15 :: SMALLINT, 16 :: SMALLINT, 22 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_a ADD CONSTRAINT edf_edif_pub_civil_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_a ADD CONSTRAINT edf_edif_pub_civil_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_a ADD CONSTRAINT edf_edif_pub_civil_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_a ADD CONSTRAINT edf_edif_pub_civil_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_civil_a ADD CONSTRAINT edf_edif_pub_civil_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_civil_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_saneamento_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -10611,93 +10785,94 @@ CREATE TABLE edgv.edf_edif_saneamento_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_saneamento_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_saneamento_p_geom ON edgv.edf_edif_saneamento_p USING gist (geom); +)# +CREATE INDEX edf_edif_saneamento_p_geom ON edgv.edf_edif_saneamento_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_saneamento_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_saneamento_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_saneamento_p ADD CONSTRAINT edf_edif_saneamento_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_p ADD CONSTRAINT edf_edif_saneamento_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_p ADD CONSTRAINT edf_edif_saneamento_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_p ADD CONSTRAINT edf_edif_saneamento_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_p ADD CONSTRAINT edf_edif_saneamento_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_p ADD CONSTRAINT edf_edif_saneamento_p_tipoedifsaneam_fk FOREIGN KEY (tipoedifsaneam) REFERENCES dominios.tipo_edif_saneam (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN tipoedifsaneam SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN tipoedifsaneam SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_p ADD CONSTRAINT edf_edif_saneamento_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_p ADD CONSTRAINT edf_edif_saneamento_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_p ADD CONSTRAINT edf_edif_saneamento_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_p ADD CONSTRAINT edf_edif_saneamento_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_p ADD CONSTRAINT edf_edif_saneamento_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_saneamento_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -10712,93 +10887,94 @@ CREATE TABLE edgv.edf_edif_saneamento_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_saneamento_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_saneamento_a_geom ON edgv.edf_edif_saneamento_a USING gist (geom); +)# +CREATE INDEX edf_edif_saneamento_a_geom ON edgv.edf_edif_saneamento_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_saneamento_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_saneamento_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_saneamento_a ADD CONSTRAINT edf_edif_saneamento_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_a ADD CONSTRAINT edf_edif_saneamento_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_a ADD CONSTRAINT edf_edif_saneamento_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_a ADD CONSTRAINT edf_edif_saneamento_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_a ADD CONSTRAINT edf_edif_saneamento_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_a ADD CONSTRAINT edf_edif_saneamento_a_tipoedifsaneam_fk FOREIGN KEY (tipoedifsaneam) REFERENCES dominios.tipo_edif_saneam (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN tipoedifsaneam SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN tipoedifsaneam SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_a ADD CONSTRAINT edf_edif_saneamento_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_a ADD CONSTRAINT edf_edif_saneamento_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_a ADD CONSTRAINT edf_edif_saneamento_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_a ADD CONSTRAINT edf_edif_saneamento_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_saneamento_a ADD CONSTRAINT edf_edif_saneamento_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_saneamento_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_policia_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -10815,116 +10991,120 @@ CREATE TABLE edgv.edf_edif_policia_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_policia_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_policia_p_geom ON edgv.edf_edif_policia_p USING gist (geom); +)# +CREATE INDEX edf_edif_policia_p_geom ON edgv.edf_edif_policia_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_policia_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_policia_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_policia_p ADD CONSTRAINT edf_edif_policia_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_p ADD CONSTRAINT edf_edif_policia_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_p ADD CONSTRAINT edf_edif_policia_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_p ADD CONSTRAINT edf_edif_policia_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_p ADD CONSTRAINT edf_edif_policia_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_p ADD CONSTRAINT edf_edif_policia_p_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_policia_p - ADD CONSTRAINT edf_edif_policia_p_tipousoedif_check - CHECK (tipousoedif = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN tipousoedif SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_policia_p_tipousoedif_check + CHECK (tipousoedif = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_p ADD CONSTRAINT edf_edif_policia_p_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_policia_p - ADD CONSTRAINT edf_edif_policia_p_jurisdicao_check - CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN jurisdicao SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_policia_p_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_p ADD CONSTRAINT edf_edif_policia_p_tipoedifpubcivil_fk FOREIGN KEY (tipoedifpubcivil) REFERENCES dominios.tipo_org_civil (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_policia_p - ADD CONSTRAINT edf_edif_policia_p_tipoedifpubcivil_check - CHECK (tipoedifpubcivil = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 11 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_policia_p_tipoedifpubcivil_check + CHECK (tipoedifpubcivil = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 11 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_p ADD CONSTRAINT edf_edif_policia_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_p ADD CONSTRAINT edf_edif_policia_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_p ADD CONSTRAINT edf_edif_policia_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_p ADD CONSTRAINT edf_edif_policia_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_p ADD CONSTRAINT edf_edif_policia_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_policia_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -10941,116 +11121,120 @@ CREATE TABLE edgv.edf_edif_policia_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_policia_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_policia_a_geom ON edgv.edf_edif_policia_a USING gist (geom); +)# +CREATE INDEX edf_edif_policia_a_geom ON edgv.edf_edif_policia_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_policia_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_policia_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_policia_a ADD CONSTRAINT edf_edif_policia_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_a ADD CONSTRAINT edf_edif_policia_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_a ADD CONSTRAINT edf_edif_policia_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_a ADD CONSTRAINT edf_edif_policia_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_a ADD CONSTRAINT edf_edif_policia_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_a ADD CONSTRAINT edf_edif_policia_a_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_policia_a - ADD CONSTRAINT edf_edif_policia_a_tipousoedif_check - CHECK (tipousoedif = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN tipousoedif SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_policia_a_tipousoedif_check + CHECK (tipousoedif = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_a ADD CONSTRAINT edf_edif_policia_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_policia_a - ADD CONSTRAINT edf_edif_policia_a_jurisdicao_check - CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN jurisdicao SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_policia_a_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_a ADD CONSTRAINT edf_edif_policia_a_tipoedifpubcivil_fk FOREIGN KEY (tipoedifpubcivil) REFERENCES dominios.tipo_org_civil (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_policia_a - ADD CONSTRAINT edf_edif_policia_a_tipoedifpubcivil_check - CHECK (tipoedifpubcivil = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 11 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_policia_a_tipoedifpubcivil_check + CHECK (tipoedifpubcivil = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 11 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN tipoedifpubcivil SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_a ADD CONSTRAINT edf_edif_policia_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_a ADD CONSTRAINT edf_edif_policia_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_a ADD CONSTRAINT edf_edif_policia_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_a ADD CONSTRAINT edf_edif_policia_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_policia_a ADD CONSTRAINT edf_edif_policia_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_policia_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_pub_militar_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -11067,113 +11251,116 @@ CREATE TABLE edgv.edf_edif_pub_militar_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_pub_militar_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_pub_militar_p_geom ON edgv.edf_edif_pub_militar_p USING gist (geom); +)# +CREATE INDEX edf_edif_pub_militar_p_geom ON edgv.edf_edif_pub_militar_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_pub_militar_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_pub_militar_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_pub_militar_p ADD CONSTRAINT edf_edif_pub_militar_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_p ADD CONSTRAINT edf_edif_pub_militar_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_p ADD CONSTRAINT edf_edif_pub_militar_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_p ADD CONSTRAINT edf_edif_pub_militar_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_p ADD CONSTRAINT edf_edif_pub_militar_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_p ADD CONSTRAINT edf_edif_pub_militar_p_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_pub_militar_p - ADD CONSTRAINT edf_edif_pub_militar_p_tipousoedif_check - CHECK (tipousoedif = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN tipousoedif SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_pub_militar_p_tipousoedif_check + CHECK (tipousoedif = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_p ADD CONSTRAINT edf_edif_pub_militar_p_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_pub_militar_p - ADD CONSTRAINT edf_edif_pub_militar_p_jurisdicao_check - CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN jurisdicao SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_pub_militar_p_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_p ADD CONSTRAINT edf_edif_pub_militar_p_tipoinstalmilitar_fk FOREIGN KEY (tipoinstalmilitar) REFERENCES dominios.tipo_instal_militar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN tipoinstalmilitar SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN tipoinstalmilitar SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_p ADD CONSTRAINT edf_edif_pub_militar_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_p ADD CONSTRAINT edf_edif_pub_militar_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_p ADD CONSTRAINT edf_edif_pub_militar_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_p ADD CONSTRAINT edf_edif_pub_militar_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_p ADD CONSTRAINT edf_edif_pub_militar_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_pub_militar_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -11190,113 +11377,116 @@ CREATE TABLE edgv.edf_edif_pub_militar_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_pub_militar_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_pub_militar_a_geom ON edgv.edf_edif_pub_militar_a USING gist (geom); +)# +CREATE INDEX edf_edif_pub_militar_a_geom ON edgv.edf_edif_pub_militar_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_pub_militar_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_pub_militar_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_pub_militar_a ADD CONSTRAINT edf_edif_pub_militar_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_a ADD CONSTRAINT edf_edif_pub_militar_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_a ADD CONSTRAINT edf_edif_pub_militar_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_a ADD CONSTRAINT edf_edif_pub_militar_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_a ADD CONSTRAINT edf_edif_pub_militar_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_a ADD CONSTRAINT edf_edif_pub_militar_a_tipousoedif_fk FOREIGN KEY (tipousoedif) REFERENCES dominios.tipo_uso_edif (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_pub_militar_a - ADD CONSTRAINT edf_edif_pub_militar_a_tipousoedif_check - CHECK (tipousoedif = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN tipousoedif SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_pub_militar_a_tipousoedif_check + CHECK (tipousoedif = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN tipousoedif SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_a ADD CONSTRAINT edf_edif_pub_militar_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.edf_edif_pub_militar_a - ADD CONSTRAINT edf_edif_pub_militar_a_jurisdicao_check - CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN jurisdicao SET DEFAULT 9999; + ADD CONSTRAINT edf_edif_pub_militar_a_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_a ADD CONSTRAINT edf_edif_pub_militar_a_tipoinstalmilitar_fk FOREIGN KEY (tipoinstalmilitar) REFERENCES dominios.tipo_instal_militar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN tipoinstalmilitar SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN tipoinstalmilitar SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_a ADD CONSTRAINT edf_edif_pub_militar_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_a ADD CONSTRAINT edf_edif_pub_militar_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_a ADD CONSTRAINT edf_edif_pub_militar_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_a ADD CONSTRAINT edf_edif_pub_militar_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_pub_militar_a ADD CONSTRAINT edf_edif_pub_militar_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_pub_militar_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_residencial_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -11310,86 +11500,87 @@ CREATE TABLE edgv.edf_edif_residencial_p( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edf_edif_residencial_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_residencial_p_geom ON edgv.edf_edif_residencial_p USING gist (geom); +)# +CREATE INDEX edf_edif_residencial_p_geom ON edgv.edf_edif_residencial_p USING gist (geom)# -ALTER TABLE edgv.edf_edif_residencial_p OWNER TO postgres; +ALTER TABLE edgv.edf_edif_residencial_p OWNER TO postgres# ALTER TABLE edgv.edf_edif_residencial_p ADD CONSTRAINT edf_edif_residencial_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_p ADD CONSTRAINT edf_edif_residencial_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_p ADD CONSTRAINT edf_edif_residencial_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_p ADD CONSTRAINT edf_edif_residencial_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_p ADD CONSTRAINT edf_edif_residencial_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_p ADD CONSTRAINT edf_edif_residencial_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_p ADD CONSTRAINT edf_edif_residencial_p_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_p ADD CONSTRAINT edf_edif_residencial_p_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_p ADD CONSTRAINT edf_edif_residencial_p_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_p ADD CONSTRAINT edf_edif_residencial_p_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_p ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.edf_edif_residencial_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -11403,386 +11594,394 @@ CREATE TABLE edgv.edf_edif_residencial_a( divisaoativecon smallint NOT NULL, grupoativecon smallint NOT NULL, proprioadm smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT edf_edif_residencial_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX edf_edif_residencial_a_geom ON edgv.edf_edif_residencial_a USING gist (geom); +)# +CREATE INDEX edf_edif_residencial_a_geom ON edgv.edf_edif_residencial_a USING gist (geom)# -ALTER TABLE edgv.edf_edif_residencial_a OWNER TO postgres; +ALTER TABLE edgv.edf_edif_residencial_a OWNER TO postgres# ALTER TABLE edgv.edf_edif_residencial_a ADD CONSTRAINT edf_edif_residencial_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_a ADD CONSTRAINT edf_edif_residencial_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_a ADD CONSTRAINT edf_edif_residencial_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_a ADD CONSTRAINT edf_edif_residencial_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_a ADD CONSTRAINT edf_edif_residencial_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN cultura SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN cultura SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_a ADD CONSTRAINT edf_edif_residencial_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_a ADD CONSTRAINT edf_edif_residencial_a_classeativecon_fk FOREIGN KEY (classeativecon) REFERENCES dominios.classe_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN classeativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN classeativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_a ADD CONSTRAINT edf_edif_residencial_a_divisaoativecon_fk FOREIGN KEY (divisaoativecon) REFERENCES dominios.divisao_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN divisaoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN divisaoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_a ADD CONSTRAINT edf_edif_residencial_a_grupoativecon_fk FOREIGN KEY (grupoativecon) REFERENCES dominios.grupo_ativ_econ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN grupoativecon SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN grupoativecon SET DEFAULT 9999# ALTER TABLE edgv.edf_edif_residencial_a ADD CONSTRAINT edf_edif_residencial_a_proprioadm_fk FOREIGN KEY (proprioadm) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN proprioadm SET DEFAULT 9999; +ALTER TABLE edgv.edf_edif_residencial_a ALTER COLUMN proprioadm SET DEFAULT 9999# CREATE TABLE edgv.emu_acesso_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, matconstr smallint NOT NULL, situacaoespacial smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT emu_acesso_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_acesso_l_geom ON edgv.emu_acesso_l USING gist (geom); +)# +CREATE INDEX emu_acesso_l_geom ON edgv.emu_acesso_l USING gist (geom)# -ALTER TABLE edgv.emu_acesso_l OWNER TO postgres; +ALTER TABLE edgv.emu_acesso_l OWNER TO postgres# ALTER TABLE edgv.emu_acesso_l ADD CONSTRAINT emu_acesso_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_acesso_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.emu_acesso_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.emu_acesso_l ADD CONSTRAINT emu_acesso_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_acesso_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.emu_acesso_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.emu_acesso_l ADD CONSTRAINT emu_acesso_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_acesso_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.emu_acesso_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.emu_acesso_l ADD CONSTRAINT emu_acesso_l_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_acesso_l ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.emu_acesso_l ALTER COLUMN situacaoespacial SET DEFAULT 9999# CREATE TABLE edgv.emu_acesso_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, matconstr smallint NOT NULL, situacaoespacial smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT emu_acesso_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_acesso_p_geom ON edgv.emu_acesso_p USING gist (geom); +)# +CREATE INDEX emu_acesso_p_geom ON edgv.emu_acesso_p USING gist (geom)# -ALTER TABLE edgv.emu_acesso_p OWNER TO postgres; +ALTER TABLE edgv.emu_acesso_p OWNER TO postgres# ALTER TABLE edgv.emu_acesso_p ADD CONSTRAINT emu_acesso_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_acesso_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.emu_acesso_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.emu_acesso_p ADD CONSTRAINT emu_acesso_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_acesso_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.emu_acesso_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.emu_acesso_p ADD CONSTRAINT emu_acesso_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_acesso_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.emu_acesso_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.emu_acesso_p ADD CONSTRAINT emu_acesso_p_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_acesso_p ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.emu_acesso_p ALTER COLUMN situacaoespacial SET DEFAULT 9999# CREATE TABLE edgv.emu_acesso_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, matconstr smallint NOT NULL, situacaoespacial smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT emu_acesso_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_acesso_a_geom ON edgv.emu_acesso_a USING gist (geom); +)# +CREATE INDEX emu_acesso_a_geom ON edgv.emu_acesso_a USING gist (geom)# -ALTER TABLE edgv.emu_acesso_a OWNER TO postgres; +ALTER TABLE edgv.emu_acesso_a OWNER TO postgres# ALTER TABLE edgv.emu_acesso_a ADD CONSTRAINT emu_acesso_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_acesso_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.emu_acesso_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.emu_acesso_a ADD CONSTRAINT emu_acesso_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_acesso_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.emu_acesso_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.emu_acesso_a ADD CONSTRAINT emu_acesso_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_acesso_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.emu_acesso_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.emu_acesso_a ADD CONSTRAINT emu_acesso_a_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_acesso_a ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.emu_acesso_a ALTER COLUMN situacaoespacial SET DEFAULT 9999# CREATE TABLE edgv.emu_rampa_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, matconstr smallint NOT NULL, situacaoespacial smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT emu_rampa_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_rampa_l_geom ON edgv.emu_rampa_l USING gist (geom); +)# +CREATE INDEX emu_rampa_l_geom ON edgv.emu_rampa_l USING gist (geom)# -ALTER TABLE edgv.emu_rampa_l OWNER TO postgres; +ALTER TABLE edgv.emu_rampa_l OWNER TO postgres# ALTER TABLE edgv.emu_rampa_l ADD CONSTRAINT emu_rampa_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_rampa_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.emu_rampa_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.emu_rampa_l ADD CONSTRAINT emu_rampa_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_rampa_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.emu_rampa_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.emu_rampa_l ADD CONSTRAINT emu_rampa_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_rampa_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.emu_rampa_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.emu_rampa_l ADD CONSTRAINT emu_rampa_l_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_rampa_l ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.emu_rampa_l ALTER COLUMN situacaoespacial SET DEFAULT 9999# CREATE TABLE edgv.emu_rampa_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, matconstr smallint NOT NULL, situacaoespacial smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT emu_rampa_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_rampa_p_geom ON edgv.emu_rampa_p USING gist (geom); +)# +CREATE INDEX emu_rampa_p_geom ON edgv.emu_rampa_p USING gist (geom)# -ALTER TABLE edgv.emu_rampa_p OWNER TO postgres; +ALTER TABLE edgv.emu_rampa_p OWNER TO postgres# ALTER TABLE edgv.emu_rampa_p ADD CONSTRAINT emu_rampa_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_rampa_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.emu_rampa_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.emu_rampa_p ADD CONSTRAINT emu_rampa_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_rampa_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.emu_rampa_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.emu_rampa_p ADD CONSTRAINT emu_rampa_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_rampa_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.emu_rampa_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.emu_rampa_p ADD CONSTRAINT emu_rampa_p_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_rampa_p ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.emu_rampa_p ALTER COLUMN situacaoespacial SET DEFAULT 9999# CREATE TABLE edgv.emu_rampa_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, matconstr smallint NOT NULL, situacaoespacial smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT emu_rampa_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_rampa_a_geom ON edgv.emu_rampa_a USING gist (geom); +)# +CREATE INDEX emu_rampa_a_geom ON edgv.emu_rampa_a USING gist (geom)# -ALTER TABLE edgv.emu_rampa_a OWNER TO postgres; +ALTER TABLE edgv.emu_rampa_a OWNER TO postgres# ALTER TABLE edgv.emu_rampa_a ADD CONSTRAINT emu_rampa_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_rampa_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.emu_rampa_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.emu_rampa_a ADD CONSTRAINT emu_rampa_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_rampa_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.emu_rampa_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.emu_rampa_a ADD CONSTRAINT emu_rampa_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_rampa_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.emu_rampa_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.emu_rampa_a ADD CONSTRAINT emu_rampa_a_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_rampa_a ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.emu_rampa_a ALTER COLUMN situacaoespacial SET DEFAULT 9999# CREATE TABLE edgv.emu_ciclovia_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, revestimento smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT emu_ciclovia_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_ciclovia_l_geom ON edgv.emu_ciclovia_l USING gist (geom); +)# +CREATE INDEX emu_ciclovia_l_geom ON edgv.emu_ciclovia_l USING gist (geom)# -ALTER TABLE edgv.emu_ciclovia_l OWNER TO postgres; +ALTER TABLE edgv.emu_ciclovia_l OWNER TO postgres# ALTER TABLE edgv.emu_ciclovia_l ADD CONSTRAINT emu_ciclovia_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_ciclovia_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.emu_ciclovia_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.emu_ciclovia_l ADD CONSTRAINT emu_ciclovia_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_ciclovia_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.emu_ciclovia_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.emu_ciclovia_l ADD CONSTRAINT emu_ciclovia_l_revestimento_fk FOREIGN KEY (revestimento) REFERENCES dominios.revestimento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_ciclovia_l ALTER COLUMN revestimento SET DEFAULT 9999; +ALTER TABLE edgv.emu_ciclovia_l ALTER COLUMN revestimento SET DEFAULT 9999# CREATE TABLE edgv.emu_elevador_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -11790,51 +11989,52 @@ CREATE TABLE edgv.emu_elevador_l( matconstr smallint NOT NULL, situacaoespacial smallint NOT NULL, tipoelevador smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT emu_elevador_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_elevador_l_geom ON edgv.emu_elevador_l USING gist (geom); +)# +CREATE INDEX emu_elevador_l_geom ON edgv.emu_elevador_l USING gist (geom)# -ALTER TABLE edgv.emu_elevador_l OWNER TO postgres; +ALTER TABLE edgv.emu_elevador_l OWNER TO postgres# ALTER TABLE edgv.emu_elevador_l ADD CONSTRAINT emu_elevador_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.emu_elevador_l ADD CONSTRAINT emu_elevador_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.emu_elevador_l ADD CONSTRAINT emu_elevador_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.emu_elevador_l ADD CONSTRAINT emu_elevador_l_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_l ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_l ALTER COLUMN situacaoespacial SET DEFAULT 9999# ALTER TABLE edgv.emu_elevador_l ADD CONSTRAINT emu_elevador_l_tipoelevador_fk FOREIGN KEY (tipoelevador) REFERENCES dominios.tipo_elevador (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_l ALTER COLUMN tipoelevador SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_l ALTER COLUMN tipoelevador SET DEFAULT 9999# CREATE TABLE edgv.emu_elevador_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -11842,51 +12042,52 @@ CREATE TABLE edgv.emu_elevador_p( matconstr smallint NOT NULL, situacaoespacial smallint NOT NULL, tipoelevador smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT emu_elevador_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_elevador_p_geom ON edgv.emu_elevador_p USING gist (geom); +)# +CREATE INDEX emu_elevador_p_geom ON edgv.emu_elevador_p USING gist (geom)# -ALTER TABLE edgv.emu_elevador_p OWNER TO postgres; +ALTER TABLE edgv.emu_elevador_p OWNER TO postgres# ALTER TABLE edgv.emu_elevador_p ADD CONSTRAINT emu_elevador_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.emu_elevador_p ADD CONSTRAINT emu_elevador_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.emu_elevador_p ADD CONSTRAINT emu_elevador_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.emu_elevador_p ADD CONSTRAINT emu_elevador_p_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_p ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_p ALTER COLUMN situacaoespacial SET DEFAULT 9999# ALTER TABLE edgv.emu_elevador_p ADD CONSTRAINT emu_elevador_p_tipoelevador_fk FOREIGN KEY (tipoelevador) REFERENCES dominios.tipo_elevador (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_p ALTER COLUMN tipoelevador SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_p ALTER COLUMN tipoelevador SET DEFAULT 9999# CREATE TABLE edgv.emu_elevador_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -11894,262 +12095,270 @@ CREATE TABLE edgv.emu_elevador_a( matconstr smallint NOT NULL, situacaoespacial smallint NOT NULL, tipoelevador smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT emu_elevador_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_elevador_a_geom ON edgv.emu_elevador_a USING gist (geom); +)# +CREATE INDEX emu_elevador_a_geom ON edgv.emu_elevador_a USING gist (geom)# -ALTER TABLE edgv.emu_elevador_a OWNER TO postgres; +ALTER TABLE edgv.emu_elevador_a OWNER TO postgres# ALTER TABLE edgv.emu_elevador_a ADD CONSTRAINT emu_elevador_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.emu_elevador_a ADD CONSTRAINT emu_elevador_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.emu_elevador_a ADD CONSTRAINT emu_elevador_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.emu_elevador_a ADD CONSTRAINT emu_elevador_a_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_a ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_a ALTER COLUMN situacaoespacial SET DEFAULT 9999# ALTER TABLE edgv.emu_elevador_a ADD CONSTRAINT emu_elevador_a_tipoelevador_fk FOREIGN KEY (tipoelevador) REFERENCES dominios.tipo_elevador (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_elevador_a ALTER COLUMN tipoelevador SET DEFAULT 9999; +ALTER TABLE edgv.emu_elevador_a ALTER COLUMN tipoelevador SET DEFAULT 9999# CREATE TABLE edgv.emu_escadaria_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, matconstr smallint NOT NULL, situacaoespacial smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT emu_escadaria_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_escadaria_l_geom ON edgv.emu_escadaria_l USING gist (geom); +)# +CREATE INDEX emu_escadaria_l_geom ON edgv.emu_escadaria_l USING gist (geom)# -ALTER TABLE edgv.emu_escadaria_l OWNER TO postgres; +ALTER TABLE edgv.emu_escadaria_l OWNER TO postgres# ALTER TABLE edgv.emu_escadaria_l ADD CONSTRAINT emu_escadaria_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_escadaria_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.emu_escadaria_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.emu_escadaria_l ADD CONSTRAINT emu_escadaria_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_escadaria_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.emu_escadaria_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.emu_escadaria_l ADD CONSTRAINT emu_escadaria_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_escadaria_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.emu_escadaria_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.emu_escadaria_l ADD CONSTRAINT emu_escadaria_l_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_escadaria_l ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.emu_escadaria_l ALTER COLUMN situacaoespacial SET DEFAULT 9999# CREATE TABLE edgv.emu_escadaria_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, matconstr smallint NOT NULL, situacaoespacial smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT emu_escadaria_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_escadaria_p_geom ON edgv.emu_escadaria_p USING gist (geom); +)# +CREATE INDEX emu_escadaria_p_geom ON edgv.emu_escadaria_p USING gist (geom)# -ALTER TABLE edgv.emu_escadaria_p OWNER TO postgres; +ALTER TABLE edgv.emu_escadaria_p OWNER TO postgres# ALTER TABLE edgv.emu_escadaria_p ADD CONSTRAINT emu_escadaria_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_escadaria_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.emu_escadaria_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.emu_escadaria_p ADD CONSTRAINT emu_escadaria_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_escadaria_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.emu_escadaria_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.emu_escadaria_p ADD CONSTRAINT emu_escadaria_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_escadaria_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.emu_escadaria_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.emu_escadaria_p ADD CONSTRAINT emu_escadaria_p_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_escadaria_p ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.emu_escadaria_p ALTER COLUMN situacaoespacial SET DEFAULT 9999# CREATE TABLE edgv.emu_escadaria_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, matconstr smallint NOT NULL, situacaoespacial smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT emu_escadaria_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_escadaria_a_geom ON edgv.emu_escadaria_a USING gist (geom); +)# +CREATE INDEX emu_escadaria_a_geom ON edgv.emu_escadaria_a USING gist (geom)# -ALTER TABLE edgv.emu_escadaria_a OWNER TO postgres; +ALTER TABLE edgv.emu_escadaria_a OWNER TO postgres# ALTER TABLE edgv.emu_escadaria_a ADD CONSTRAINT emu_escadaria_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_escadaria_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.emu_escadaria_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.emu_escadaria_a ADD CONSTRAINT emu_escadaria_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_escadaria_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.emu_escadaria_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.emu_escadaria_a ADD CONSTRAINT emu_escadaria_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_escadaria_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.emu_escadaria_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.emu_escadaria_a ADD CONSTRAINT emu_escadaria_a_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_escadaria_a ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.emu_escadaria_a ALTER COLUMN situacaoespacial SET DEFAULT 9999# CREATE TABLE edgv.emu_poste_sinalizacao_p( - id serial NOT NULL, - codident varchar(80), + id uuid NOT NULL DEFAULT uuid_generate_v4(), + codident varchar(255), geometriaaproximada boolean NOT NULL, matconstr smallint NOT NULL, tipoposte smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT emu_poste_sinalizacao_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX emu_poste_sinalizacao_p_geom ON edgv.emu_poste_sinalizacao_p USING gist (geom); +)# +CREATE INDEX emu_poste_sinalizacao_p_geom ON edgv.emu_poste_sinalizacao_p USING gist (geom)# -ALTER TABLE edgv.emu_poste_sinalizacao_p OWNER TO postgres; +ALTER TABLE edgv.emu_poste_sinalizacao_p OWNER TO postgres# ALTER TABLE edgv.emu_poste_sinalizacao_p ADD CONSTRAINT emu_poste_sinalizacao_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.emu_poste_sinalizacao_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.emu_poste_sinalizacao_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.emu_poste_sinalizacao_p ADD CONSTRAINT emu_poste_sinalizacao_p_tipoposte_fk FOREIGN KEY (tipoposte) REFERENCES dominios.tipo_poste (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.emu_poste_sinalizacao_p - ADD CONSTRAINT emu_poste_sinalizacao_p_tipoposte_check - CHECK (tipoposte = ANY(ARRAY[5 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.emu_poste_sinalizacao_p ALTER COLUMN tipoposte SET DEFAULT 9999; + ADD CONSTRAINT emu_poste_sinalizacao_p_tipoposte_check + CHECK (tipoposte = ANY(ARRAY[5 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.emu_poste_sinalizacao_p ALTER COLUMN tipoposte SET DEFAULT 9999# CREATE TABLE edgv.enc_casa_de_forca_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT enc_casa_de_forca_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_casa_de_forca_p_geom ON edgv.enc_casa_de_forca_p USING gist (geom); +)# +CREATE INDEX enc_casa_de_forca_p_geom ON edgv.enc_casa_de_forca_p USING gist (geom)# -ALTER TABLE edgv.enc_casa_de_forca_p OWNER TO postgres; +ALTER TABLE edgv.enc_casa_de_forca_p OWNER TO postgres# CREATE TABLE edgv.enc_torre_energia_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, ovgd smallint NOT NULL, alturaestimada real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT enc_torre_energia_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_torre_energia_p_geom ON edgv.enc_torre_energia_p USING gist (geom); +)# +CREATE INDEX enc_torre_energia_p_geom ON edgv.enc_torre_energia_p USING gist (geom)# -ALTER TABLE edgv.enc_torre_energia_p OWNER TO postgres; +ALTER TABLE edgv.enc_torre_energia_p OWNER TO postgres# ALTER TABLE edgv.enc_torre_energia_p ADD CONSTRAINT enc_torre_energia_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_torre_energia_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_torre_energia_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.enc_torre_energia_p ADD CONSTRAINT enc_torre_energia_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_torre_energia_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.enc_torre_energia_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.enc_torre_energia_p ADD CONSTRAINT enc_torre_energia_p_ovgd_fk FOREIGN KEY (ovgd) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_torre_energia_p ALTER COLUMN ovgd SET DEFAULT 9999; +ALTER TABLE edgv.enc_torre_energia_p ALTER COLUMN ovgd SET DEFAULT 9999# CREATE TABLE edgv.enc_trecho_energia_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, especie smallint NOT NULL, @@ -12158,75 +12367,78 @@ CREATE TABLE edgv.enc_trecho_energia_l( situacaofisica smallint NOT NULL, largurafaixaservidao real, sin smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT enc_trecho_energia_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_trecho_energia_l_geom ON edgv.enc_trecho_energia_l USING gist (geom); +)# +CREATE INDEX enc_trecho_energia_l_geom ON edgv.enc_trecho_energia_l USING gist (geom)# -ALTER TABLE edgv.enc_trecho_energia_l OWNER TO postgres; +ALTER TABLE edgv.enc_trecho_energia_l OWNER TO postgres# ALTER TABLE edgv.enc_trecho_energia_l ADD CONSTRAINT enc_trecho_energia_l_especie_fk FOREIGN KEY (especie) REFERENCES dominios.especie_trecho_energia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_trecho_energia_l ALTER COLUMN especie SET DEFAULT 9999; +ALTER TABLE edgv.enc_trecho_energia_l ALTER COLUMN especie SET DEFAULT 9999# ALTER TABLE edgv.enc_trecho_energia_l ADD CONSTRAINT enc_trecho_energia_l_posicaorelativa_fk FOREIGN KEY (posicaorelativa) REFERENCES dominios.posicao_relativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_trecho_energia_l ALTER COLUMN posicaorelativa SET DEFAULT 9999; +ALTER TABLE edgv.enc_trecho_energia_l ALTER COLUMN posicaorelativa SET DEFAULT 9999# ALTER TABLE edgv.enc_trecho_energia_l ADD CONSTRAINT enc_trecho_energia_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_trecho_energia_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_trecho_energia_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.enc_trecho_energia_l ADD CONSTRAINT enc_trecho_energia_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_trecho_energia_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.enc_trecho_energia_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.enc_trecho_energia_l ADD CONSTRAINT enc_trecho_energia_l_sin_fk FOREIGN KEY (sin) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_trecho_energia_l ALTER COLUMN sin SET DEFAULT 9999; +ALTER TABLE edgv.enc_trecho_energia_l ALTER COLUMN sin SET DEFAULT 9999# CREATE TABLE edgv.enc_grupo_transformadores_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT enc_grupo_transformadores_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_grupo_transformadores_p_geom ON edgv.enc_grupo_transformadores_p USING gist (geom); +)# +CREATE INDEX enc_grupo_transformadores_p_geom ON edgv.enc_grupo_transformadores_p USING gist (geom)# -ALTER TABLE edgv.enc_grupo_transformadores_p OWNER TO postgres; +ALTER TABLE edgv.enc_grupo_transformadores_p OWNER TO postgres# CREATE TABLE edgv.enc_grupo_transformadores_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT enc_grupo_transformadores_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_grupo_transformadores_a_geom ON edgv.enc_grupo_transformadores_a USING gist (geom); +)# +CREATE INDEX enc_grupo_transformadores_a_geom ON edgv.enc_grupo_transformadores_a USING gist (geom)# -ALTER TABLE edgv.enc_grupo_transformadores_a OWNER TO postgres; +ALTER TABLE edgv.enc_grupo_transformadores_a OWNER TO postgres# CREATE TABLE edgv.enc_est_gerad_energia_eletrica_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, ceg varchar(16), @@ -12234,40 +12446,42 @@ CREATE TABLE edgv.enc_est_gerad_energia_eletrica_p( operacional smallint NOT NULL, situacaofisica smallint NOT NULL, potenciaout real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT enc_est_gerad_energia_eletrica_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_est_gerad_energia_eletrica_p_geom ON edgv.enc_est_gerad_energia_eletrica_p USING gist (geom); +)# +CREATE INDEX enc_est_gerad_energia_eletrica_p_geom ON edgv.enc_est_gerad_energia_eletrica_p USING gist (geom)# -ALTER TABLE edgv.enc_est_gerad_energia_eletrica_p OWNER TO postgres; +ALTER TABLE edgv.enc_est_gerad_energia_eletrica_p OWNER TO postgres# ALTER TABLE edgv.enc_est_gerad_energia_eletrica_p ADD CONSTRAINT enc_est_gerad_energia_eletrica_p_tipoestgerad_fk FOREIGN KEY (tipoestgerad) REFERENCES dominios.tipo_est_gerad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.enc_est_gerad_energia_eletrica_p - ADD CONSTRAINT enc_est_gerad_energia_eletrica_p_tipoestgerad_check - CHECK (tipoestgerad = ANY(ARRAY[0 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.enc_est_gerad_energia_eletrica_p ALTER COLUMN tipoestgerad SET DEFAULT 9999; + ADD CONSTRAINT enc_est_gerad_energia_eletrica_p_tipoestgerad_check + CHECK (tipoestgerad = ANY(ARRAY[0 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.enc_est_gerad_energia_eletrica_p ALTER COLUMN tipoestgerad SET DEFAULT 9999# ALTER TABLE edgv.enc_est_gerad_energia_eletrica_p ADD CONSTRAINT enc_est_gerad_energia_eletrica_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_est_gerad_energia_eletrica_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_est_gerad_energia_eletrica_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.enc_est_gerad_energia_eletrica_p ADD CONSTRAINT enc_est_gerad_energia_eletrica_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_est_gerad_energia_eletrica_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.enc_est_gerad_energia_eletrica_p ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.enc_est_gerad_energia_eletrica_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, ceg varchar(16), @@ -12275,40 +12489,42 @@ CREATE TABLE edgv.enc_est_gerad_energia_eletrica_a( operacional smallint NOT NULL, situacaofisica smallint NOT NULL, potenciaout real, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT enc_est_gerad_energia_eletrica_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_est_gerad_energia_eletrica_a_geom ON edgv.enc_est_gerad_energia_eletrica_a USING gist (geom); +)# +CREATE INDEX enc_est_gerad_energia_eletrica_a_geom ON edgv.enc_est_gerad_energia_eletrica_a USING gist (geom)# -ALTER TABLE edgv.enc_est_gerad_energia_eletrica_a OWNER TO postgres; +ALTER TABLE edgv.enc_est_gerad_energia_eletrica_a OWNER TO postgres# ALTER TABLE edgv.enc_est_gerad_energia_eletrica_a ADD CONSTRAINT enc_est_gerad_energia_eletrica_a_tipoestgerad_fk FOREIGN KEY (tipoestgerad) REFERENCES dominios.tipo_est_gerad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.enc_est_gerad_energia_eletrica_a - ADD CONSTRAINT enc_est_gerad_energia_eletrica_a_tipoestgerad_check - CHECK (tipoestgerad = ANY(ARRAY[0 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.enc_est_gerad_energia_eletrica_a ALTER COLUMN tipoestgerad SET DEFAULT 9999; + ADD CONSTRAINT enc_est_gerad_energia_eletrica_a_tipoestgerad_check + CHECK (tipoestgerad = ANY(ARRAY[0 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.enc_est_gerad_energia_eletrica_a ALTER COLUMN tipoestgerad SET DEFAULT 9999# ALTER TABLE edgv.enc_est_gerad_energia_eletrica_a ADD CONSTRAINT enc_est_gerad_energia_eletrica_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_est_gerad_energia_eletrica_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_est_gerad_energia_eletrica_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.enc_est_gerad_energia_eletrica_a ADD CONSTRAINT enc_est_gerad_energia_eletrica_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_est_gerad_energia_eletrica_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.enc_est_gerad_energia_eletrica_a ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.enc_central_geradora_eolica_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, ceg varchar(16), @@ -12316,40 +12532,42 @@ CREATE TABLE edgv.enc_central_geradora_eolica_p( operacional smallint NOT NULL, situacaofisica smallint NOT NULL, potenciaout real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT enc_central_geradora_eolica_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_central_geradora_eolica_p_geom ON edgv.enc_central_geradora_eolica_p USING gist (geom); +)# +CREATE INDEX enc_central_geradora_eolica_p_geom ON edgv.enc_central_geradora_eolica_p USING gist (geom)# -ALTER TABLE edgv.enc_central_geradora_eolica_p OWNER TO postgres; +ALTER TABLE edgv.enc_central_geradora_eolica_p OWNER TO postgres# ALTER TABLE edgv.enc_central_geradora_eolica_p ADD CONSTRAINT enc_central_geradora_eolica_p_tipoestgerad_fk FOREIGN KEY (tipoestgerad) REFERENCES dominios.tipo_est_gerad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.enc_central_geradora_eolica_p - ADD CONSTRAINT enc_central_geradora_eolica_p_tipoestgerad_check - CHECK (tipoestgerad = ANY(ARRAY[5 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.enc_central_geradora_eolica_p ALTER COLUMN tipoestgerad SET DEFAULT 9999; + ADD CONSTRAINT enc_central_geradora_eolica_p_tipoestgerad_check + CHECK (tipoestgerad = ANY(ARRAY[5 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.enc_central_geradora_eolica_p ALTER COLUMN tipoestgerad SET DEFAULT 9999# ALTER TABLE edgv.enc_central_geradora_eolica_p ADD CONSTRAINT enc_central_geradora_eolica_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_central_geradora_eolica_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_central_geradora_eolica_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.enc_central_geradora_eolica_p ADD CONSTRAINT enc_central_geradora_eolica_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_central_geradora_eolica_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.enc_central_geradora_eolica_p ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.enc_central_geradora_eolica_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, ceg varchar(16), @@ -12357,52 +12575,55 @@ CREATE TABLE edgv.enc_central_geradora_eolica_a( operacional smallint NOT NULL, situacaofisica smallint NOT NULL, potenciaout real, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT enc_central_geradora_eolica_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_central_geradora_eolica_a_geom ON edgv.enc_central_geradora_eolica_a USING gist (geom); +)# +CREATE INDEX enc_central_geradora_eolica_a_geom ON edgv.enc_central_geradora_eolica_a USING gist (geom)# -ALTER TABLE edgv.enc_central_geradora_eolica_a OWNER TO postgres; +ALTER TABLE edgv.enc_central_geradora_eolica_a OWNER TO postgres# ALTER TABLE edgv.enc_central_geradora_eolica_a ADD CONSTRAINT enc_central_geradora_eolica_a_tipoestgerad_fk FOREIGN KEY (tipoestgerad) REFERENCES dominios.tipo_est_gerad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.enc_central_geradora_eolica_a - ADD CONSTRAINT enc_central_geradora_eolica_a_tipoestgerad_check - CHECK (tipoestgerad = ANY(ARRAY[5 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.enc_central_geradora_eolica_a ALTER COLUMN tipoestgerad SET DEFAULT 9999; + ADD CONSTRAINT enc_central_geradora_eolica_a_tipoestgerad_check + CHECK (tipoestgerad = ANY(ARRAY[5 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.enc_central_geradora_eolica_a ALTER COLUMN tipoestgerad SET DEFAULT 9999# ALTER TABLE edgv.enc_central_geradora_eolica_a ADD CONSTRAINT enc_central_geradora_eolica_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_central_geradora_eolica_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_central_geradora_eolica_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.enc_central_geradora_eolica_a ADD CONSTRAINT enc_central_geradora_eolica_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_central_geradora_eolica_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.enc_central_geradora_eolica_a ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.enc_aerogerador_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, alturatorreaer real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT enc_aerogerador_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_aerogerador_p_geom ON edgv.enc_aerogerador_p USING gist (geom); +)# +CREATE INDEX enc_aerogerador_p_geom ON edgv.enc_aerogerador_p USING gist (geom)# -ALTER TABLE edgv.enc_aerogerador_p OWNER TO postgres; +ALTER TABLE edgv.enc_aerogerador_p OWNER TO postgres# CREATE TABLE edgv.enc_hidreletrica_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, ceg varchar(16), @@ -12411,47 +12632,49 @@ CREATE TABLE edgv.enc_hidreletrica_l( situacaofisica smallint NOT NULL, potenciaout real, tipoahe smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT enc_hidreletrica_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_hidreletrica_l_geom ON edgv.enc_hidreletrica_l USING gist (geom); +)# +CREATE INDEX enc_hidreletrica_l_geom ON edgv.enc_hidreletrica_l USING gist (geom)# -ALTER TABLE edgv.enc_hidreletrica_l OWNER TO postgres; +ALTER TABLE edgv.enc_hidreletrica_l OWNER TO postgres# ALTER TABLE edgv.enc_hidreletrica_l ADD CONSTRAINT enc_hidreletrica_l_tipoestgerad_fk FOREIGN KEY (tipoestgerad) REFERENCES dominios.tipo_est_gerad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.enc_hidreletrica_l - ADD CONSTRAINT enc_hidreletrica_l_tipoestgerad_check - CHECK (tipoestgerad = ANY(ARRAY[8 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.enc_hidreletrica_l ALTER COLUMN tipoestgerad SET DEFAULT 9999; + ADD CONSTRAINT enc_hidreletrica_l_tipoestgerad_check + CHECK (tipoestgerad = ANY(ARRAY[8 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.enc_hidreletrica_l ALTER COLUMN tipoestgerad SET DEFAULT 9999# ALTER TABLE edgv.enc_hidreletrica_l ADD CONSTRAINT enc_hidreletrica_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_hidreletrica_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_hidreletrica_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.enc_hidreletrica_l ADD CONSTRAINT enc_hidreletrica_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_hidreletrica_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.enc_hidreletrica_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.enc_hidreletrica_l ADD CONSTRAINT enc_hidreletrica_l_tipoahe_fk FOREIGN KEY (tipoahe) REFERENCES dominios.tipo_ahe (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_hidreletrica_l ALTER COLUMN tipoahe SET DEFAULT 9999; +ALTER TABLE edgv.enc_hidreletrica_l ALTER COLUMN tipoahe SET DEFAULT 9999# CREATE TABLE edgv.enc_hidreletrica_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, ceg varchar(16), @@ -12460,47 +12683,49 @@ CREATE TABLE edgv.enc_hidreletrica_p( situacaofisica smallint NOT NULL, potenciaout real, tipoahe smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT enc_hidreletrica_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_hidreletrica_p_geom ON edgv.enc_hidreletrica_p USING gist (geom); +)# +CREATE INDEX enc_hidreletrica_p_geom ON edgv.enc_hidreletrica_p USING gist (geom)# -ALTER TABLE edgv.enc_hidreletrica_p OWNER TO postgres; +ALTER TABLE edgv.enc_hidreletrica_p OWNER TO postgres# ALTER TABLE edgv.enc_hidreletrica_p ADD CONSTRAINT enc_hidreletrica_p_tipoestgerad_fk FOREIGN KEY (tipoestgerad) REFERENCES dominios.tipo_est_gerad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.enc_hidreletrica_p - ADD CONSTRAINT enc_hidreletrica_p_tipoestgerad_check - CHECK (tipoestgerad = ANY(ARRAY[8 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.enc_hidreletrica_p ALTER COLUMN tipoestgerad SET DEFAULT 9999; + ADD CONSTRAINT enc_hidreletrica_p_tipoestgerad_check + CHECK (tipoestgerad = ANY(ARRAY[8 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.enc_hidreletrica_p ALTER COLUMN tipoestgerad SET DEFAULT 9999# ALTER TABLE edgv.enc_hidreletrica_p ADD CONSTRAINT enc_hidreletrica_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_hidreletrica_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_hidreletrica_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.enc_hidreletrica_p ADD CONSTRAINT enc_hidreletrica_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_hidreletrica_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.enc_hidreletrica_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.enc_hidreletrica_p ADD CONSTRAINT enc_hidreletrica_p_tipoahe_fk FOREIGN KEY (tipoahe) REFERENCES dominios.tipo_ahe (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_hidreletrica_p ALTER COLUMN tipoahe SET DEFAULT 9999; +ALTER TABLE edgv.enc_hidreletrica_p ALTER COLUMN tipoahe SET DEFAULT 9999# CREATE TABLE edgv.enc_hidreletrica_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, ceg varchar(16), @@ -12509,67 +12734,70 @@ CREATE TABLE edgv.enc_hidreletrica_a( situacaofisica smallint NOT NULL, potenciaout real, tipoahe smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT enc_hidreletrica_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_hidreletrica_a_geom ON edgv.enc_hidreletrica_a USING gist (geom); +)# +CREATE INDEX enc_hidreletrica_a_geom ON edgv.enc_hidreletrica_a USING gist (geom)# -ALTER TABLE edgv.enc_hidreletrica_a OWNER TO postgres; +ALTER TABLE edgv.enc_hidreletrica_a OWNER TO postgres# ALTER TABLE edgv.enc_hidreletrica_a ADD CONSTRAINT enc_hidreletrica_a_tipoestgerad_fk FOREIGN KEY (tipoestgerad) REFERENCES dominios.tipo_est_gerad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.enc_hidreletrica_a - ADD CONSTRAINT enc_hidreletrica_a_tipoestgerad_check - CHECK (tipoestgerad = ANY(ARRAY[8 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.enc_hidreletrica_a ALTER COLUMN tipoestgerad SET DEFAULT 9999; + ADD CONSTRAINT enc_hidreletrica_a_tipoestgerad_check + CHECK (tipoestgerad = ANY(ARRAY[8 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.enc_hidreletrica_a ALTER COLUMN tipoestgerad SET DEFAULT 9999# ALTER TABLE edgv.enc_hidreletrica_a ADD CONSTRAINT enc_hidreletrica_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_hidreletrica_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_hidreletrica_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.enc_hidreletrica_a ADD CONSTRAINT enc_hidreletrica_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_hidreletrica_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.enc_hidreletrica_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.enc_hidreletrica_a ADD CONSTRAINT enc_hidreletrica_a_tipoahe_fk FOREIGN KEY (tipoahe) REFERENCES dominios.tipo_ahe (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_hidreletrica_a ALTER COLUMN tipoahe SET DEFAULT 9999; +ALTER TABLE edgv.enc_hidreletrica_a ALTER COLUMN tipoahe SET DEFAULT 9999# CREATE TABLE edgv.enc_antena_comunic_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, posicaoreledific smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT enc_antena_comunic_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_antena_comunic_p_geom ON edgv.enc_antena_comunic_p USING gist (geom); +)# +CREATE INDEX enc_antena_comunic_p_geom ON edgv.enc_antena_comunic_p USING gist (geom)# -ALTER TABLE edgv.enc_antena_comunic_p OWNER TO postgres; +ALTER TABLE edgv.enc_antena_comunic_p OWNER TO postgres# ALTER TABLE edgv.enc_antena_comunic_p ADD CONSTRAINT enc_antena_comunic_p_posicaoreledific_fk FOREIGN KEY (posicaoreledific) REFERENCES dominios.posicao_rel_edific (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_antena_comunic_p ALTER COLUMN posicaoreledific SET DEFAULT 9999; +ALTER TABLE edgv.enc_antena_comunic_p ALTER COLUMN posicaoreledific SET DEFAULT 9999# CREATE TABLE edgv.enc_termeletrica_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, ceg varchar(16), @@ -12578,47 +12806,49 @@ CREATE TABLE edgv.enc_termeletrica_p( situacaofisica smallint NOT NULL, potenciaout real, tipocombustivel smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT enc_termeletrica_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_termeletrica_p_geom ON edgv.enc_termeletrica_p USING gist (geom); +)# +CREATE INDEX enc_termeletrica_p_geom ON edgv.enc_termeletrica_p USING gist (geom)# -ALTER TABLE edgv.enc_termeletrica_p OWNER TO postgres; +ALTER TABLE edgv.enc_termeletrica_p OWNER TO postgres# ALTER TABLE edgv.enc_termeletrica_p ADD CONSTRAINT enc_termeletrica_p_tipoestgerad_fk FOREIGN KEY (tipoestgerad) REFERENCES dominios.tipo_est_gerad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.enc_termeletrica_p - ADD CONSTRAINT enc_termeletrica_p_tipoestgerad_check - CHECK (tipoestgerad = ANY(ARRAY[9 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.enc_termeletrica_p ALTER COLUMN tipoestgerad SET DEFAULT 9999; + ADD CONSTRAINT enc_termeletrica_p_tipoestgerad_check + CHECK (tipoestgerad = ANY(ARRAY[9 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.enc_termeletrica_p ALTER COLUMN tipoestgerad SET DEFAULT 9999# ALTER TABLE edgv.enc_termeletrica_p ADD CONSTRAINT enc_termeletrica_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_termeletrica_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_termeletrica_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.enc_termeletrica_p ADD CONSTRAINT enc_termeletrica_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_termeletrica_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.enc_termeletrica_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.enc_termeletrica_p ADD CONSTRAINT enc_termeletrica_p_tipocombustivel_fk FOREIGN KEY (tipocombustivel) REFERENCES dominios.tipo_combustivel (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_termeletrica_p ALTER COLUMN tipocombustivel SET DEFAULT 9999; +ALTER TABLE edgv.enc_termeletrica_p ALTER COLUMN tipocombustivel SET DEFAULT 9999# CREATE TABLE edgv.enc_termeletrica_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, ceg varchar(16), @@ -12627,47 +12857,49 @@ CREATE TABLE edgv.enc_termeletrica_a( situacaofisica smallint NOT NULL, potenciaout real, tipocombustivel smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT enc_termeletrica_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_termeletrica_a_geom ON edgv.enc_termeletrica_a USING gist (geom); +)# +CREATE INDEX enc_termeletrica_a_geom ON edgv.enc_termeletrica_a USING gist (geom)# -ALTER TABLE edgv.enc_termeletrica_a OWNER TO postgres; +ALTER TABLE edgv.enc_termeletrica_a OWNER TO postgres# ALTER TABLE edgv.enc_termeletrica_a ADD CONSTRAINT enc_termeletrica_a_tipoestgerad_fk FOREIGN KEY (tipoestgerad) REFERENCES dominios.tipo_est_gerad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.enc_termeletrica_a - ADD CONSTRAINT enc_termeletrica_a_tipoestgerad_check - CHECK (tipoestgerad = ANY(ARRAY[9 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.enc_termeletrica_a ALTER COLUMN tipoestgerad SET DEFAULT 9999; + ADD CONSTRAINT enc_termeletrica_a_tipoestgerad_check + CHECK (tipoestgerad = ANY(ARRAY[9 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.enc_termeletrica_a ALTER COLUMN tipoestgerad SET DEFAULT 9999# ALTER TABLE edgv.enc_termeletrica_a ADD CONSTRAINT enc_termeletrica_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_termeletrica_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_termeletrica_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.enc_termeletrica_a ADD CONSTRAINT enc_termeletrica_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_termeletrica_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.enc_termeletrica_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.enc_termeletrica_a ADD CONSTRAINT enc_termeletrica_a_tipocombustivel_fk FOREIGN KEY (tipocombustivel) REFERENCES dominios.tipo_combustivel (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_termeletrica_a ALTER COLUMN tipocombustivel SET DEFAULT 9999; +ALTER TABLE edgv.enc_termeletrica_a ALTER COLUMN tipocombustivel SET DEFAULT 9999# CREATE TABLE edgv.enc_trecho_comunic_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipotrechocomunic smallint NOT NULL, @@ -12676,58 +12908,59 @@ CREATE TABLE edgv.enc_trecho_comunic_l( operacional smallint NOT NULL, situacaofisica smallint NOT NULL, emduto smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT enc_trecho_comunic_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_trecho_comunic_l_geom ON edgv.enc_trecho_comunic_l USING gist (geom); +)# +CREATE INDEX enc_trecho_comunic_l_geom ON edgv.enc_trecho_comunic_l USING gist (geom)# -ALTER TABLE edgv.enc_trecho_comunic_l OWNER TO postgres; +ALTER TABLE edgv.enc_trecho_comunic_l OWNER TO postgres# ALTER TABLE edgv.enc_trecho_comunic_l ADD CONSTRAINT enc_trecho_comunic_l_tipotrechocomunic_fk FOREIGN KEY (tipotrechocomunic) REFERENCES dominios.tipo_trecho_comunic (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_trecho_comunic_l ALTER COLUMN tipotrechocomunic SET DEFAULT 9999; +ALTER TABLE edgv.enc_trecho_comunic_l ALTER COLUMN tipotrechocomunic SET DEFAULT 9999# ALTER TABLE edgv.enc_trecho_comunic_l ADD CONSTRAINT enc_trecho_comunic_l_posicaorelativa_fk FOREIGN KEY (posicaorelativa) REFERENCES dominios.posicao_relativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_trecho_comunic_l ALTER COLUMN posicaorelativa SET DEFAULT 9999; +ALTER TABLE edgv.enc_trecho_comunic_l ALTER COLUMN posicaorelativa SET DEFAULT 9999# ALTER TABLE edgv.enc_trecho_comunic_l ADD CONSTRAINT enc_trecho_comunic_l_matcondutor_fk FOREIGN KEY (matcondutor) REFERENCES dominios.mat_condutor (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_trecho_comunic_l ALTER COLUMN matcondutor SET DEFAULT 9999; +ALTER TABLE edgv.enc_trecho_comunic_l ALTER COLUMN matcondutor SET DEFAULT 9999# ALTER TABLE edgv.enc_trecho_comunic_l ADD CONSTRAINT enc_trecho_comunic_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_trecho_comunic_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_trecho_comunic_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.enc_trecho_comunic_l ADD CONSTRAINT enc_trecho_comunic_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_trecho_comunic_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.enc_trecho_comunic_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.enc_trecho_comunic_l ADD CONSTRAINT enc_trecho_comunic_l_emduto_fk FOREIGN KEY (emduto) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_trecho_comunic_l ALTER COLUMN emduto SET DEFAULT 9999; +ALTER TABLE edgv.enc_trecho_comunic_l ALTER COLUMN emduto SET DEFAULT 9999# CREATE TABLE edgv.enc_torre_comunic_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -12736,99 +12969,102 @@ CREATE TABLE edgv.enc_torre_comunic_p( ovgd smallint NOT NULL, alturaestimada real, modalidade smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT enc_torre_comunic_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_torre_comunic_p_geom ON edgv.enc_torre_comunic_p USING gist (geom); +)# +CREATE INDEX enc_torre_comunic_p_geom ON edgv.enc_torre_comunic_p USING gist (geom)# -ALTER TABLE edgv.enc_torre_comunic_p OWNER TO postgres; +ALTER TABLE edgv.enc_torre_comunic_p OWNER TO postgres# ALTER TABLE edgv.enc_torre_comunic_p ADD CONSTRAINT enc_torre_comunic_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_torre_comunic_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.enc_torre_comunic_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.enc_torre_comunic_p ADD CONSTRAINT enc_torre_comunic_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_torre_comunic_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.enc_torre_comunic_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.enc_torre_comunic_p ADD CONSTRAINT enc_torre_comunic_p_posicaoreledific_fk FOREIGN KEY (posicaoreledific) REFERENCES dominios.posicao_rel_edific (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_torre_comunic_p ALTER COLUMN posicaoreledific SET DEFAULT 9999; +ALTER TABLE edgv.enc_torre_comunic_p ALTER COLUMN posicaoreledific SET DEFAULT 9999# ALTER TABLE edgv.enc_torre_comunic_p ADD CONSTRAINT enc_torre_comunic_p_ovgd_fk FOREIGN KEY (ovgd) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_torre_comunic_p ALTER COLUMN ovgd SET DEFAULT 9999; +ALTER TABLE edgv.enc_torre_comunic_p ALTER COLUMN ovgd SET DEFAULT 9999# ALTER TABLE edgv.enc_torre_comunic_p ADD CONSTRAINT enc_torre_comunic_p_modalidade_fk FOREIGN KEY (modalidade) REFERENCES dominios.modalidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.enc_torre_comunic_p ALTER COLUMN modalidade SET DEFAULT 9999; +ALTER TABLE edgv.enc_torre_comunic_p ALTER COLUMN modalidade SET DEFAULT 9999# CREATE TABLE edgv.enc_zona_linhas_energia_comunicacao_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT enc_zona_linhas_energia_comunicacao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX enc_zona_linhas_energia_comunicacao_a_geom ON edgv.enc_zona_linhas_energia_comunicacao_a USING gist (geom); +)# +CREATE INDEX enc_zona_linhas_energia_comunicacao_a_geom ON edgv.enc_zona_linhas_energia_comunicacao_a USING gist (geom)# -ALTER TABLE edgv.enc_zona_linhas_energia_comunicacao_a OWNER TO postgres; +ALTER TABLE edgv.enc_zona_linhas_energia_comunicacao_a OWNER TO postgres# CREATE TABLE edgv.fer_girador_ferroviario_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, administracao smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT fer_girador_ferroviario_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX fer_girador_ferroviario_p_geom ON edgv.fer_girador_ferroviario_p USING gist (geom); +)# +CREATE INDEX fer_girador_ferroviario_p_geom ON edgv.fer_girador_ferroviario_p USING gist (geom)# -ALTER TABLE edgv.fer_girador_ferroviario_p OWNER TO postgres; +ALTER TABLE edgv.fer_girador_ferroviario_p OWNER TO postgres# ALTER TABLE edgv.fer_girador_ferroviario_p ADD CONSTRAINT fer_girador_ferroviario_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_girador_ferroviario_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.fer_girador_ferroviario_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.fer_girador_ferroviario_p ADD CONSTRAINT fer_girador_ferroviario_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_girador_ferroviario_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.fer_girador_ferroviario_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.fer_girador_ferroviario_p ADD CONSTRAINT fer_girador_ferroviario_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_girador_ferroviario_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.fer_girador_ferroviario_p ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.fer_trecho_ferroviario_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, codtrechoferrov varchar(25), @@ -12844,135 +13080,138 @@ CREATE TABLE edgv.fer_trecho_ferroviario_l( situacaofisica smallint NOT NULL, cargasuportmaxima real, emarruamento boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT fer_trecho_ferroviario_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX fer_trecho_ferroviario_l_geom ON edgv.fer_trecho_ferroviario_l USING gist (geom); +)# +CREATE INDEX fer_trecho_ferroviario_l_geom ON edgv.fer_trecho_ferroviario_l USING gist (geom)# -ALTER TABLE edgv.fer_trecho_ferroviario_l OWNER TO postgres; +ALTER TABLE edgv.fer_trecho_ferroviario_l OWNER TO postgres# ALTER TABLE edgv.fer_trecho_ferroviario_l ADD CONSTRAINT fer_trecho_ferroviario_l_posicaorelativa_fk FOREIGN KEY (posicaorelativa) REFERENCES dominios.posicao_relativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN posicaorelativa SET DEFAULT 9999; +ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN posicaorelativa SET DEFAULT 9999# ALTER TABLE edgv.fer_trecho_ferroviario_l ADD CONSTRAINT fer_trecho_ferroviario_l_tipotrechoferrov_fk FOREIGN KEY (tipotrechoferrov) REFERENCES dominios.tipo_trecho_ferrov (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN tipotrechoferrov SET DEFAULT 9999; +ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN tipotrechoferrov SET DEFAULT 9999# ALTER TABLE edgv.fer_trecho_ferroviario_l ADD CONSTRAINT fer_trecho_ferroviario_l_bitola_fk FOREIGN KEY (bitola) REFERENCES dominios.bitola (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN bitola SET DEFAULT 9999; +ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN bitola SET DEFAULT 9999# ALTER TABLE edgv.fer_trecho_ferroviario_l ADD CONSTRAINT fer_trecho_ferroviario_l_eletrificada_fk FOREIGN KEY (eletrificada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN eletrificada SET DEFAULT 9999; +ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN eletrificada SET DEFAULT 9999# ALTER TABLE edgv.fer_trecho_ferroviario_l ADD CONSTRAINT fer_trecho_ferroviario_l_nrlinhas_fk FOREIGN KEY (nrlinhas) REFERENCES dominios.nr_linhas (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN nrlinhas SET DEFAULT 9999; +ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN nrlinhas SET DEFAULT 9999# ALTER TABLE edgv.fer_trecho_ferroviario_l ADD CONSTRAINT fer_trecho_ferroviario_l_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.fer_trecho_ferroviario_l ADD CONSTRAINT fer_trecho_ferroviario_l_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.fer_trecho_ferroviario_l ADD CONSTRAINT fer_trecho_ferroviario_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.fer_trecho_ferroviario_l ADD CONSTRAINT fer_trecho_ferroviario_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.fer_trecho_ferroviario_l ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.fer_cremalheira_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT fer_cremalheira_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX fer_cremalheira_l_geom ON edgv.fer_cremalheira_l USING gist (geom); +)# +CREATE INDEX fer_cremalheira_l_geom ON edgv.fer_cremalheira_l USING gist (geom)# -ALTER TABLE edgv.fer_cremalheira_l OWNER TO postgres; +ALTER TABLE edgv.fer_cremalheira_l OWNER TO postgres# ALTER TABLE edgv.fer_cremalheira_l ADD CONSTRAINT fer_cremalheira_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_cremalheira_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.fer_cremalheira_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.fer_cremalheira_l ADD CONSTRAINT fer_cremalheira_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_cremalheira_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.fer_cremalheira_l ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.fer_cremalheira_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT fer_cremalheira_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX fer_cremalheira_p_geom ON edgv.fer_cremalheira_p USING gist (geom); +)# +CREATE INDEX fer_cremalheira_p_geom ON edgv.fer_cremalheira_p USING gist (geom)# -ALTER TABLE edgv.fer_cremalheira_p OWNER TO postgres; +ALTER TABLE edgv.fer_cremalheira_p OWNER TO postgres# ALTER TABLE edgv.fer_cremalheira_p ADD CONSTRAINT fer_cremalheira_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_cremalheira_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.fer_cremalheira_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.fer_cremalheira_p ADD CONSTRAINT fer_cremalheira_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.fer_cremalheira_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.fer_cremalheira_p ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.hdv_eclusa_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, desnivel real, @@ -12982,37 +13221,38 @@ CREATE TABLE edgv.hdv_eclusa_l( matconstr smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hdv_eclusa_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hdv_eclusa_l_geom ON edgv.hdv_eclusa_l USING gist (geom); +)# +CREATE INDEX hdv_eclusa_l_geom ON edgv.hdv_eclusa_l USING gist (geom)# -ALTER TABLE edgv.hdv_eclusa_l OWNER TO postgres; +ALTER TABLE edgv.hdv_eclusa_l OWNER TO postgres# ALTER TABLE edgv.hdv_eclusa_l ADD CONSTRAINT hdv_eclusa_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_eclusa_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hdv_eclusa_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hdv_eclusa_l ADD CONSTRAINT hdv_eclusa_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_eclusa_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hdv_eclusa_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hdv_eclusa_l ADD CONSTRAINT hdv_eclusa_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_eclusa_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hdv_eclusa_l ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.hdv_eclusa_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, desnivel real, @@ -13022,37 +13262,38 @@ CREATE TABLE edgv.hdv_eclusa_p( matconstr smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hdv_eclusa_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hdv_eclusa_p_geom ON edgv.hdv_eclusa_p USING gist (geom); +)# +CREATE INDEX hdv_eclusa_p_geom ON edgv.hdv_eclusa_p USING gist (geom)# -ALTER TABLE edgv.hdv_eclusa_p OWNER TO postgres; +ALTER TABLE edgv.hdv_eclusa_p OWNER TO postgres# ALTER TABLE edgv.hdv_eclusa_p ADD CONSTRAINT hdv_eclusa_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_eclusa_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hdv_eclusa_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hdv_eclusa_p ADD CONSTRAINT hdv_eclusa_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_eclusa_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hdv_eclusa_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hdv_eclusa_p ADD CONSTRAINT hdv_eclusa_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_eclusa_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hdv_eclusa_p ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.hdv_eclusa_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, desnivel real, @@ -13062,157 +13303,162 @@ CREATE TABLE edgv.hdv_eclusa_a( matconstr smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hdv_eclusa_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hdv_eclusa_a_geom ON edgv.hdv_eclusa_a USING gist (geom); +)# +CREATE INDEX hdv_eclusa_a_geom ON edgv.hdv_eclusa_a USING gist (geom)# -ALTER TABLE edgv.hdv_eclusa_a OWNER TO postgres; +ALTER TABLE edgv.hdv_eclusa_a OWNER TO postgres# ALTER TABLE edgv.hdv_eclusa_a ADD CONSTRAINT hdv_eclusa_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_eclusa_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hdv_eclusa_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hdv_eclusa_a ADD CONSTRAINT hdv_eclusa_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_eclusa_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hdv_eclusa_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hdv_eclusa_a ADD CONSTRAINT hdv_eclusa_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_eclusa_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hdv_eclusa_a ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.hdv_obstaculo_navegacao_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoobst smallint NOT NULL, situacaoemagua smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hdv_obstaculo_navegacao_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hdv_obstaculo_navegacao_l_geom ON edgv.hdv_obstaculo_navegacao_l USING gist (geom); +)# +CREATE INDEX hdv_obstaculo_navegacao_l_geom ON edgv.hdv_obstaculo_navegacao_l USING gist (geom)# -ALTER TABLE edgv.hdv_obstaculo_navegacao_l OWNER TO postgres; +ALTER TABLE edgv.hdv_obstaculo_navegacao_l OWNER TO postgres# ALTER TABLE edgv.hdv_obstaculo_navegacao_l ADD CONSTRAINT hdv_obstaculo_navegacao_l_tipoobst_fk FOREIGN KEY (tipoobst) REFERENCES dominios.tipo_obst (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_obstaculo_navegacao_l ALTER COLUMN tipoobst SET DEFAULT 9999; +ALTER TABLE edgv.hdv_obstaculo_navegacao_l ALTER COLUMN tipoobst SET DEFAULT 9999# ALTER TABLE edgv.hdv_obstaculo_navegacao_l ADD CONSTRAINT hdv_obstaculo_navegacao_l_situacaoemagua_fk FOREIGN KEY (situacaoemagua) REFERENCES dominios.situacao_em_agua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_obstaculo_navegacao_l ALTER COLUMN situacaoemagua SET DEFAULT 9999; +ALTER TABLE edgv.hdv_obstaculo_navegacao_l ALTER COLUMN situacaoemagua SET DEFAULT 9999# CREATE TABLE edgv.hdv_obstaculo_navegacao_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoobst smallint NOT NULL, situacaoemagua smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hdv_obstaculo_navegacao_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hdv_obstaculo_navegacao_p_geom ON edgv.hdv_obstaculo_navegacao_p USING gist (geom); +)# +CREATE INDEX hdv_obstaculo_navegacao_p_geom ON edgv.hdv_obstaculo_navegacao_p USING gist (geom)# -ALTER TABLE edgv.hdv_obstaculo_navegacao_p OWNER TO postgres; +ALTER TABLE edgv.hdv_obstaculo_navegacao_p OWNER TO postgres# ALTER TABLE edgv.hdv_obstaculo_navegacao_p ADD CONSTRAINT hdv_obstaculo_navegacao_p_tipoobst_fk FOREIGN KEY (tipoobst) REFERENCES dominios.tipo_obst (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_obstaculo_navegacao_p ALTER COLUMN tipoobst SET DEFAULT 9999; +ALTER TABLE edgv.hdv_obstaculo_navegacao_p ALTER COLUMN tipoobst SET DEFAULT 9999# ALTER TABLE edgv.hdv_obstaculo_navegacao_p ADD CONSTRAINT hdv_obstaculo_navegacao_p_situacaoemagua_fk FOREIGN KEY (situacaoemagua) REFERENCES dominios.situacao_em_agua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_obstaculo_navegacao_p ALTER COLUMN situacaoemagua SET DEFAULT 9999; +ALTER TABLE edgv.hdv_obstaculo_navegacao_p ALTER COLUMN situacaoemagua SET DEFAULT 9999# CREATE TABLE edgv.hdv_obstaculo_navegacao_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoobst smallint NOT NULL, situacaoemagua smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hdv_obstaculo_navegacao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hdv_obstaculo_navegacao_a_geom ON edgv.hdv_obstaculo_navegacao_a USING gist (geom); +)# +CREATE INDEX hdv_obstaculo_navegacao_a_geom ON edgv.hdv_obstaculo_navegacao_a USING gist (geom)# -ALTER TABLE edgv.hdv_obstaculo_navegacao_a OWNER TO postgres; +ALTER TABLE edgv.hdv_obstaculo_navegacao_a OWNER TO postgres# ALTER TABLE edgv.hdv_obstaculo_navegacao_a ADD CONSTRAINT hdv_obstaculo_navegacao_a_tipoobst_fk FOREIGN KEY (tipoobst) REFERENCES dominios.tipo_obst (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_obstaculo_navegacao_a ALTER COLUMN tipoobst SET DEFAULT 9999; +ALTER TABLE edgv.hdv_obstaculo_navegacao_a ALTER COLUMN tipoobst SET DEFAULT 9999# ALTER TABLE edgv.hdv_obstaculo_navegacao_a ADD CONSTRAINT hdv_obstaculo_navegacao_a_situacaoemagua_fk FOREIGN KEY (situacaoemagua) REFERENCES dominios.situacao_em_agua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_obstaculo_navegacao_a ALTER COLUMN situacaoemagua SET DEFAULT 9999; +ALTER TABLE edgv.hdv_obstaculo_navegacao_a ALTER COLUMN situacaoemagua SET DEFAULT 9999# CREATE TABLE edgv.hdv_sinalizacao_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tiposinal smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hdv_sinalizacao_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hdv_sinalizacao_p_geom ON edgv.hdv_sinalizacao_p USING gist (geom); +)# +CREATE INDEX hdv_sinalizacao_p_geom ON edgv.hdv_sinalizacao_p USING gist (geom)# -ALTER TABLE edgv.hdv_sinalizacao_p OWNER TO postgres; +ALTER TABLE edgv.hdv_sinalizacao_p OWNER TO postgres# ALTER TABLE edgv.hdv_sinalizacao_p ADD CONSTRAINT hdv_sinalizacao_p_tiposinal_fk FOREIGN KEY (tiposinal) REFERENCES dominios.tipo_sinal (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_sinalizacao_p ALTER COLUMN tiposinal SET DEFAULT 9999; +ALTER TABLE edgv.hdv_sinalizacao_p ALTER COLUMN tiposinal SET DEFAULT 9999# ALTER TABLE edgv.hdv_sinalizacao_p ADD CONSTRAINT hdv_sinalizacao_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_sinalizacao_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hdv_sinalizacao_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hdv_sinalizacao_p ADD CONSTRAINT hdv_sinalizacao_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_sinalizacao_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hdv_sinalizacao_p ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.hdv_atracadouro_terminal_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoatracad smallint NOT NULL, @@ -13221,58 +13467,59 @@ CREATE TABLE edgv.hdv_atracadouro_terminal_l( operacional smallint NOT NULL, situacaofisica smallint NOT NULL, aptidaooperacional smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hdv_atracadouro_terminal_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hdv_atracadouro_terminal_l_geom ON edgv.hdv_atracadouro_terminal_l USING gist (geom); +)# +CREATE INDEX hdv_atracadouro_terminal_l_geom ON edgv.hdv_atracadouro_terminal_l USING gist (geom)# -ALTER TABLE edgv.hdv_atracadouro_terminal_l OWNER TO postgres; +ALTER TABLE edgv.hdv_atracadouro_terminal_l OWNER TO postgres# ALTER TABLE edgv.hdv_atracadouro_terminal_l ADD CONSTRAINT hdv_atracadouro_terminal_l_tipoatracad_fk FOREIGN KEY (tipoatracad) REFERENCES dominios.tipo_atracad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_l ALTER COLUMN tipoatracad SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_l ALTER COLUMN tipoatracad SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_l ADD CONSTRAINT hdv_atracadouro_terminal_l_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_l ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_l ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_l ADD CONSTRAINT hdv_atracadouro_terminal_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_l ADD CONSTRAINT hdv_atracadouro_terminal_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_l ADD CONSTRAINT hdv_atracadouro_terminal_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_l ADD CONSTRAINT hdv_atracadouro_terminal_l_aptidaooperacional_fk FOREIGN KEY (aptidaooperacional) REFERENCES dominios.aptidao_operacional_atracadouro (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_l ALTER COLUMN aptidaooperacional SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_l ALTER COLUMN aptidaooperacional SET DEFAULT 9999# CREATE TABLE edgv.hdv_atracadouro_terminal_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoatracad smallint NOT NULL, @@ -13281,58 +13528,59 @@ CREATE TABLE edgv.hdv_atracadouro_terminal_p( operacional smallint NOT NULL, situacaofisica smallint NOT NULL, aptidaooperacional smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hdv_atracadouro_terminal_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hdv_atracadouro_terminal_p_geom ON edgv.hdv_atracadouro_terminal_p USING gist (geom); +)# +CREATE INDEX hdv_atracadouro_terminal_p_geom ON edgv.hdv_atracadouro_terminal_p USING gist (geom)# -ALTER TABLE edgv.hdv_atracadouro_terminal_p OWNER TO postgres; +ALTER TABLE edgv.hdv_atracadouro_terminal_p OWNER TO postgres# ALTER TABLE edgv.hdv_atracadouro_terminal_p ADD CONSTRAINT hdv_atracadouro_terminal_p_tipoatracad_fk FOREIGN KEY (tipoatracad) REFERENCES dominios.tipo_atracad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_p ALTER COLUMN tipoatracad SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_p ALTER COLUMN tipoatracad SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_p ADD CONSTRAINT hdv_atracadouro_terminal_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_p ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_p ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_p ADD CONSTRAINT hdv_atracadouro_terminal_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_p ADD CONSTRAINT hdv_atracadouro_terminal_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_p ADD CONSTRAINT hdv_atracadouro_terminal_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_p ADD CONSTRAINT hdv_atracadouro_terminal_p_aptidaooperacional_fk FOREIGN KEY (aptidaooperacional) REFERENCES dominios.aptidao_operacional_atracadouro (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_p ALTER COLUMN aptidaooperacional SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_p ALTER COLUMN aptidaooperacional SET DEFAULT 9999# CREATE TABLE edgv.hdv_atracadouro_terminal_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoatracad smallint NOT NULL, @@ -13341,120 +13589,125 @@ CREATE TABLE edgv.hdv_atracadouro_terminal_a( operacional smallint NOT NULL, situacaofisica smallint NOT NULL, aptidaooperacional smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hdv_atracadouro_terminal_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hdv_atracadouro_terminal_a_geom ON edgv.hdv_atracadouro_terminal_a USING gist (geom); +)# +CREATE INDEX hdv_atracadouro_terminal_a_geom ON edgv.hdv_atracadouro_terminal_a USING gist (geom)# -ALTER TABLE edgv.hdv_atracadouro_terminal_a OWNER TO postgres; +ALTER TABLE edgv.hdv_atracadouro_terminal_a OWNER TO postgres# ALTER TABLE edgv.hdv_atracadouro_terminal_a ADD CONSTRAINT hdv_atracadouro_terminal_a_tipoatracad_fk FOREIGN KEY (tipoatracad) REFERENCES dominios.tipo_atracad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_a ALTER COLUMN tipoatracad SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_a ALTER COLUMN tipoatracad SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_a ADD CONSTRAINT hdv_atracadouro_terminal_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_a ADD CONSTRAINT hdv_atracadouro_terminal_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_a ADD CONSTRAINT hdv_atracadouro_terminal_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_a ADD CONSTRAINT hdv_atracadouro_terminal_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.hdv_atracadouro_terminal_a ADD CONSTRAINT hdv_atracadouro_terminal_a_aptidaooperacional_fk FOREIGN KEY (aptidaooperacional) REFERENCES dominios.aptidao_operacional_atracadouro (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_atracadouro_terminal_a ALTER COLUMN aptidaooperacional SET DEFAULT 9999; +ALTER TABLE edgv.hdv_atracadouro_terminal_a ALTER COLUMN aptidaooperacional SET DEFAULT 9999# CREATE TABLE edgv.hdv_fundeadouro_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipofundeadouro smallint NOT NULL, administracao smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hdv_fundeadouro_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hdv_fundeadouro_p_geom ON edgv.hdv_fundeadouro_p USING gist (geom); +)# +CREATE INDEX hdv_fundeadouro_p_geom ON edgv.hdv_fundeadouro_p USING gist (geom)# -ALTER TABLE edgv.hdv_fundeadouro_p OWNER TO postgres; +ALTER TABLE edgv.hdv_fundeadouro_p OWNER TO postgres# ALTER TABLE edgv.hdv_fundeadouro_p ADD CONSTRAINT hdv_fundeadouro_p_tipofundeadouro_fk FOREIGN KEY (tipofundeadouro) REFERENCES dominios.tipo_fundeadouro (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_fundeadouro_p ALTER COLUMN tipofundeadouro SET DEFAULT 9999; +ALTER TABLE edgv.hdv_fundeadouro_p ALTER COLUMN tipofundeadouro SET DEFAULT 9999# ALTER TABLE edgv.hdv_fundeadouro_p ADD CONSTRAINT hdv_fundeadouro_p_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hdv_fundeadouro_p - ADD CONSTRAINT hdv_fundeadouro_p_administracao_check - CHECK (administracao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 7 :: SMALLINT, 15 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hdv_fundeadouro_p ALTER COLUMN administracao SET DEFAULT 9999; + ADD CONSTRAINT hdv_fundeadouro_p_administracao_check + CHECK (administracao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 7 :: SMALLINT, 15 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hdv_fundeadouro_p ALTER COLUMN administracao SET DEFAULT 9999# CREATE TABLE edgv.hdv_fundeadouro_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipofundeadouro smallint NOT NULL, administracao smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hdv_fundeadouro_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hdv_fundeadouro_a_geom ON edgv.hdv_fundeadouro_a USING gist (geom); +)# +CREATE INDEX hdv_fundeadouro_a_geom ON edgv.hdv_fundeadouro_a USING gist (geom)# -ALTER TABLE edgv.hdv_fundeadouro_a OWNER TO postgres; +ALTER TABLE edgv.hdv_fundeadouro_a OWNER TO postgres# ALTER TABLE edgv.hdv_fundeadouro_a ADD CONSTRAINT hdv_fundeadouro_a_tipofundeadouro_fk FOREIGN KEY (tipofundeadouro) REFERENCES dominios.tipo_fundeadouro (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_fundeadouro_a ALTER COLUMN tipofundeadouro SET DEFAULT 9999; +ALTER TABLE edgv.hdv_fundeadouro_a ALTER COLUMN tipofundeadouro SET DEFAULT 9999# ALTER TABLE edgv.hdv_fundeadouro_a ADD CONSTRAINT hdv_fundeadouro_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hdv_fundeadouro_a - ADD CONSTRAINT hdv_fundeadouro_a_administracao_check - CHECK (administracao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 7 :: SMALLINT, 15 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hdv_fundeadouro_a ALTER COLUMN administracao SET DEFAULT 9999; + ADD CONSTRAINT hdv_fundeadouro_a_administracao_check + CHECK (administracao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 7 :: SMALLINT, 15 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hdv_fundeadouro_a ALTER COLUMN administracao SET DEFAULT 9999# CREATE TABLE edgv.hdv_trecho_hidroviario_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -13462,127 +13715,133 @@ CREATE TABLE edgv.hdv_trecho_hidroviario_l( regime smallint NOT NULL, extensaotrecho real, caladomaxseca real, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hdv_trecho_hidroviario_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hdv_trecho_hidroviario_l_geom ON edgv.hdv_trecho_hidroviario_l USING gist (geom); +)# +CREATE INDEX hdv_trecho_hidroviario_l_geom ON edgv.hdv_trecho_hidroviario_l USING gist (geom)# -ALTER TABLE edgv.hdv_trecho_hidroviario_l OWNER TO postgres; +ALTER TABLE edgv.hdv_trecho_hidroviario_l OWNER TO postgres# ALTER TABLE edgv.hdv_trecho_hidroviario_l ADD CONSTRAINT hdv_trecho_hidroviario_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_trecho_hidroviario_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hdv_trecho_hidroviario_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hdv_trecho_hidroviario_l ADD CONSTRAINT hdv_trecho_hidroviario_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_trecho_hidroviario_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hdv_trecho_hidroviario_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.hdv_trecho_hidroviario_l ADD CONSTRAINT hdv_trecho_hidroviario_l_regime_fk FOREIGN KEY (regime) REFERENCES dominios.regime (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hdv_trecho_hidroviario_l ALTER COLUMN regime SET DEFAULT 9999; +ALTER TABLE edgv.hdv_trecho_hidroviario_l ALTER COLUMN regime SET DEFAULT 9999# CREATE TABLE edgv.hid_sumidouro_vertedouro_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tiposumvert smallint NOT NULL, causa smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hid_sumidouro_vertedouro_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_sumidouro_vertedouro_p_geom ON edgv.hid_sumidouro_vertedouro_p USING gist (geom); +)# +CREATE INDEX hid_sumidouro_vertedouro_p_geom ON edgv.hid_sumidouro_vertedouro_p USING gist (geom)# -ALTER TABLE edgv.hid_sumidouro_vertedouro_p OWNER TO postgres; +ALTER TABLE edgv.hid_sumidouro_vertedouro_p OWNER TO postgres# ALTER TABLE edgv.hid_sumidouro_vertedouro_p ADD CONSTRAINT hid_sumidouro_vertedouro_p_tiposumvert_fk FOREIGN KEY (tiposumvert) REFERENCES dominios.tipo_sum_vert (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_sumidouro_vertedouro_p ALTER COLUMN tiposumvert SET DEFAULT 9999; +ALTER TABLE edgv.hid_sumidouro_vertedouro_p ALTER COLUMN tiposumvert SET DEFAULT 9999# ALTER TABLE edgv.hid_sumidouro_vertedouro_p ADD CONSTRAINT hid_sumidouro_vertedouro_p_causa_fk FOREIGN KEY (causa) REFERENCES dominios.causa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_sumidouro_vertedouro_p ALTER COLUMN causa SET DEFAULT 9999; +ALTER TABLE edgv.hid_sumidouro_vertedouro_p ALTER COLUMN causa SET DEFAULT 9999# CREATE TABLE edgv.hid_ilha_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, tipoilha smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hid_ilha_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_ilha_p_geom ON edgv.hid_ilha_p USING gist (geom); +)# +CREATE INDEX hid_ilha_p_geom ON edgv.hid_ilha_p USING gist (geom)# -ALTER TABLE edgv.hid_ilha_p OWNER TO postgres; +ALTER TABLE edgv.hid_ilha_p OWNER TO postgres# ALTER TABLE edgv.hid_ilha_p ADD CONSTRAINT hid_ilha_p_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hid_ilha_p - ADD CONSTRAINT hid_ilha_p_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[21 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hid_ilha_p ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT hid_ilha_p_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[21 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hid_ilha_p ALTER COLUMN tipoelemnat SET DEFAULT 9999# ALTER TABLE edgv.hid_ilha_p ADD CONSTRAINT hid_ilha_p_tipoilha_fk FOREIGN KEY (tipoilha) REFERENCES dominios.tipo_ilha (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_ilha_p ALTER COLUMN tipoilha SET DEFAULT 9999; +ALTER TABLE edgv.hid_ilha_p ALTER COLUMN tipoilha SET DEFAULT 9999# CREATE TABLE edgv.hid_ilha_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, tipoilha smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hid_ilha_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_ilha_a_geom ON edgv.hid_ilha_a USING gist (geom); +)# +CREATE INDEX hid_ilha_a_geom ON edgv.hid_ilha_a USING gist (geom)# -ALTER TABLE edgv.hid_ilha_a OWNER TO postgres; +ALTER TABLE edgv.hid_ilha_a OWNER TO postgres# ALTER TABLE edgv.hid_ilha_a ADD CONSTRAINT hid_ilha_a_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hid_ilha_a - ADD CONSTRAINT hid_ilha_a_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[21 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hid_ilha_a ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT hid_ilha_a_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[21 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hid_ilha_a ALTER COLUMN tipoelemnat SET DEFAULT 9999# ALTER TABLE edgv.hid_ilha_a ADD CONSTRAINT hid_ilha_a_tipoilha_fk FOREIGN KEY (tipoilha) REFERENCES dominios.tipo_ilha (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_ilha_a ALTER COLUMN tipoilha SET DEFAULT 9999; +ALTER TABLE edgv.hid_ilha_a ALTER COLUMN tipoilha SET DEFAULT 9999# CREATE TABLE edgv.hid_vala_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, @@ -13591,64 +13850,67 @@ CREATE TABLE edgv.hid_vala_l( matconstr smallint NOT NULL, usoprincipal smallint NOT NULL, finalidade smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hid_vala_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_vala_l_geom ON edgv.hid_vala_l USING gist (geom); +)# +CREATE INDEX hid_vala_l_geom ON edgv.hid_vala_l USING gist (geom)# -ALTER TABLE edgv.hid_vala_l OWNER TO postgres; +ALTER TABLE edgv.hid_vala_l OWNER TO postgres# ALTER TABLE edgv.hid_vala_l ADD CONSTRAINT hid_vala_l_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hid_vala_l - ADD CONSTRAINT hid_vala_l_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[31 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hid_vala_l ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT hid_vala_l_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[31 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hid_vala_l ALTER COLUMN tipoalterantrop SET DEFAULT 9999# ALTER TABLE edgv.hid_vala_l ADD CONSTRAINT hid_vala_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_vala_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hid_vala_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hid_vala_l ADD CONSTRAINT hid_vala_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_vala_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hid_vala_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.hid_vala_l ADD CONSTRAINT hid_vala_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_vala_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hid_vala_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hid_vala_l ADD CONSTRAINT hid_vala_l_usoprincipal_fk FOREIGN KEY (usoprincipal) REFERENCES dominios.uso_principal (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_vala_l ALTER COLUMN usoprincipal SET DEFAULT 9999; +ALTER TABLE edgv.hid_vala_l ALTER COLUMN usoprincipal SET DEFAULT 9999# ALTER TABLE edgv.hid_vala_l ADD CONSTRAINT hid_vala_l_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade_galeria_bueiro (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hid_vala_l - ADD CONSTRAINT hid_vala_l_finalidade_check - CHECK (finalidade = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hid_vala_l ALTER COLUMN finalidade SET DEFAULT 9999; + ADD CONSTRAINT hid_vala_l_finalidade_check + CHECK (finalidade = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hid_vala_l ALTER COLUMN finalidade SET DEFAULT 9999# CREATE TABLE edgv.hid_vala_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, @@ -13657,124 +13919,130 @@ CREATE TABLE edgv.hid_vala_a( matconstr smallint NOT NULL, usoprincipal smallint NOT NULL, finalidade smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hid_vala_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_vala_a_geom ON edgv.hid_vala_a USING gist (geom); +)# +CREATE INDEX hid_vala_a_geom ON edgv.hid_vala_a USING gist (geom)# -ALTER TABLE edgv.hid_vala_a OWNER TO postgres; +ALTER TABLE edgv.hid_vala_a OWNER TO postgres# ALTER TABLE edgv.hid_vala_a ADD CONSTRAINT hid_vala_a_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hid_vala_a - ADD CONSTRAINT hid_vala_a_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[31 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hid_vala_a ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT hid_vala_a_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[31 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hid_vala_a ALTER COLUMN tipoalterantrop SET DEFAULT 9999# ALTER TABLE edgv.hid_vala_a ADD CONSTRAINT hid_vala_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_vala_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hid_vala_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hid_vala_a ADD CONSTRAINT hid_vala_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_vala_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hid_vala_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.hid_vala_a ADD CONSTRAINT hid_vala_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_vala_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hid_vala_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hid_vala_a ADD CONSTRAINT hid_vala_a_usoprincipal_fk FOREIGN KEY (usoprincipal) REFERENCES dominios.uso_principal (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_vala_a ALTER COLUMN usoprincipal SET DEFAULT 9999; +ALTER TABLE edgv.hid_vala_a ALTER COLUMN usoprincipal SET DEFAULT 9999# ALTER TABLE edgv.hid_vala_a ADD CONSTRAINT hid_vala_a_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade_galeria_bueiro (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hid_vala_a - ADD CONSTRAINT hid_vala_a_finalidade_check - CHECK (finalidade = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hid_vala_a ALTER COLUMN finalidade SET DEFAULT 9999; + ADD CONSTRAINT hid_vala_a_finalidade_check + CHECK (finalidade = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hid_vala_a ALTER COLUMN finalidade SET DEFAULT 9999# CREATE TABLE edgv.hid_dique_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, matconstr smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hid_dique_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_dique_l_geom ON edgv.hid_dique_l USING gist (geom); +)# +CREATE INDEX hid_dique_l_geom ON edgv.hid_dique_l USING gist (geom)# -ALTER TABLE edgv.hid_dique_l OWNER TO postgres; +ALTER TABLE edgv.hid_dique_l OWNER TO postgres# ALTER TABLE edgv.hid_dique_l ADD CONSTRAINT hid_dique_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_dique_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hid_dique_l ALTER COLUMN matconstr SET DEFAULT 9999# CREATE TABLE edgv.hid_dique_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, matconstr smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hid_dique_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_dique_p_geom ON edgv.hid_dique_p USING gist (geom); +)# +CREATE INDEX hid_dique_p_geom ON edgv.hid_dique_p USING gist (geom)# -ALTER TABLE edgv.hid_dique_p OWNER TO postgres; +ALTER TABLE edgv.hid_dique_p OWNER TO postgres# ALTER TABLE edgv.hid_dique_p ADD CONSTRAINT hid_dique_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_dique_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hid_dique_p ALTER COLUMN matconstr SET DEFAULT 9999# CREATE TABLE edgv.hid_dique_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, matconstr smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hid_dique_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_dique_a_geom ON edgv.hid_dique_a USING gist (geom); +)# +CREATE INDEX hid_dique_a_geom ON edgv.hid_dique_a USING gist (geom)# -ALTER TABLE edgv.hid_dique_a OWNER TO postgres; +ALTER TABLE edgv.hid_dique_a OWNER TO postgres# ALTER TABLE edgv.hid_dique_a ADD CONSTRAINT hid_dique_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_dique_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hid_dique_a ALTER COLUMN matconstr SET DEFAULT 9999# CREATE TABLE edgv.hid_canal_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, @@ -13783,64 +14051,67 @@ CREATE TABLE edgv.hid_canal_l( matconstr smallint NOT NULL, usoprincipal smallint NOT NULL, finalidade smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hid_canal_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_canal_l_geom ON edgv.hid_canal_l USING gist (geom); +)# +CREATE INDEX hid_canal_l_geom ON edgv.hid_canal_l USING gist (geom)# -ALTER TABLE edgv.hid_canal_l OWNER TO postgres; +ALTER TABLE edgv.hid_canal_l OWNER TO postgres# ALTER TABLE edgv.hid_canal_l ADD CONSTRAINT hid_canal_l_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hid_canal_l - ADD CONSTRAINT hid_canal_l_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[30 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hid_canal_l ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT hid_canal_l_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[30 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hid_canal_l ALTER COLUMN tipoalterantrop SET DEFAULT 9999# ALTER TABLE edgv.hid_canal_l ADD CONSTRAINT hid_canal_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_canal_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hid_canal_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hid_canal_l ADD CONSTRAINT hid_canal_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_canal_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hid_canal_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.hid_canal_l ADD CONSTRAINT hid_canal_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_canal_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hid_canal_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hid_canal_l ADD CONSTRAINT hid_canal_l_usoprincipal_fk FOREIGN KEY (usoprincipal) REFERENCES dominios.uso_principal (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_canal_l ALTER COLUMN usoprincipal SET DEFAULT 9999; +ALTER TABLE edgv.hid_canal_l ALTER COLUMN usoprincipal SET DEFAULT 9999# ALTER TABLE edgv.hid_canal_l ADD CONSTRAINT hid_canal_l_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade_galeria_bueiro (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hid_canal_l - ADD CONSTRAINT hid_canal_l_finalidade_check - CHECK (finalidade = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hid_canal_l ALTER COLUMN finalidade SET DEFAULT 9999; + ADD CONSTRAINT hid_canal_l_finalidade_check + CHECK (finalidade = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hid_canal_l ALTER COLUMN finalidade SET DEFAULT 9999# CREATE TABLE edgv.hid_canal_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, @@ -13849,64 +14120,67 @@ CREATE TABLE edgv.hid_canal_a( matconstr smallint NOT NULL, usoprincipal smallint NOT NULL, finalidade smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hid_canal_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_canal_a_geom ON edgv.hid_canal_a USING gist (geom); +)# +CREATE INDEX hid_canal_a_geom ON edgv.hid_canal_a USING gist (geom)# -ALTER TABLE edgv.hid_canal_a OWNER TO postgres; +ALTER TABLE edgv.hid_canal_a OWNER TO postgres# ALTER TABLE edgv.hid_canal_a ADD CONSTRAINT hid_canal_a_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hid_canal_a - ADD CONSTRAINT hid_canal_a_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[30 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hid_canal_a ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT hid_canal_a_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[30 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hid_canal_a ALTER COLUMN tipoalterantrop SET DEFAULT 9999# ALTER TABLE edgv.hid_canal_a ADD CONSTRAINT hid_canal_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_canal_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hid_canal_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hid_canal_a ADD CONSTRAINT hid_canal_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_canal_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hid_canal_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.hid_canal_a ADD CONSTRAINT hid_canal_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_canal_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hid_canal_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hid_canal_a ADD CONSTRAINT hid_canal_a_usoprincipal_fk FOREIGN KEY (usoprincipal) REFERENCES dominios.uso_principal (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_canal_a ALTER COLUMN usoprincipal SET DEFAULT 9999; +ALTER TABLE edgv.hid_canal_a ALTER COLUMN usoprincipal SET DEFAULT 9999# ALTER TABLE edgv.hid_canal_a ADD CONSTRAINT hid_canal_a_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade_galeria_bueiro (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hid_canal_a - ADD CONSTRAINT hid_canal_a_finalidade_check - CHECK (finalidade = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hid_canal_a ALTER COLUMN finalidade SET DEFAULT 9999; + ADD CONSTRAINT hid_canal_a_finalidade_check + CHECK (finalidade = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hid_canal_a ALTER COLUMN finalidade SET DEFAULT 9999# CREATE TABLE edgv.hid_massa_dagua_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipomassadagua smallint NOT NULL, @@ -13915,51 +14189,52 @@ CREATE TABLE edgv.hid_massa_dagua_a( dominialidade smallint NOT NULL, artificial smallint NOT NULL, possuitrechodrenagem boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hid_massa_dagua_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_massa_dagua_a_geom ON edgv.hid_massa_dagua_a USING gist (geom); +)# +CREATE INDEX hid_massa_dagua_a_geom ON edgv.hid_massa_dagua_a USING gist (geom)# -ALTER TABLE edgv.hid_massa_dagua_a OWNER TO postgres; +ALTER TABLE edgv.hid_massa_dagua_a OWNER TO postgres# ALTER TABLE edgv.hid_massa_dagua_a ADD CONSTRAINT hid_massa_dagua_a_tipomassadagua_fk FOREIGN KEY (tipomassadagua) REFERENCES dominios.tipo_massa_dagua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_massa_dagua_a ALTER COLUMN tipomassadagua SET DEFAULT 9999; +ALTER TABLE edgv.hid_massa_dagua_a ALTER COLUMN tipomassadagua SET DEFAULT 9999# ALTER TABLE edgv.hid_massa_dagua_a ADD CONSTRAINT hid_massa_dagua_a_regime_fk FOREIGN KEY (regime) REFERENCES dominios.regime (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_massa_dagua_a ALTER COLUMN regime SET DEFAULT 9999; +ALTER TABLE edgv.hid_massa_dagua_a ALTER COLUMN regime SET DEFAULT 9999# ALTER TABLE edgv.hid_massa_dagua_a ADD CONSTRAINT hid_massa_dagua_a_salgada_fk FOREIGN KEY (salgada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_massa_dagua_a ALTER COLUMN salgada SET DEFAULT 9999; +ALTER TABLE edgv.hid_massa_dagua_a ALTER COLUMN salgada SET DEFAULT 9999# ALTER TABLE edgv.hid_massa_dagua_a ADD CONSTRAINT hid_massa_dagua_a_dominialidade_fk FOREIGN KEY (dominialidade) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_massa_dagua_a ALTER COLUMN dominialidade SET DEFAULT 9999; +ALTER TABLE edgv.hid_massa_dagua_a ALTER COLUMN dominialidade SET DEFAULT 9999# ALTER TABLE edgv.hid_massa_dagua_a ADD CONSTRAINT hid_massa_dagua_a_artificial_fk FOREIGN KEY (artificial) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_massa_dagua_a ALTER COLUMN artificial SET DEFAULT 9999; +ALTER TABLE edgv.hid_massa_dagua_a ALTER COLUMN artificial SET DEFAULT 9999# CREATE TABLE edgv.hid_trecho_drenagem_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipotrechodrenagem smallint NOT NULL, @@ -13967,372 +14242,388 @@ CREATE TABLE edgv.hid_trecho_drenagem_l( larguramedia real, regime smallint NOT NULL, encoberto boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hid_trecho_drenagem_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_trecho_drenagem_l_geom ON edgv.hid_trecho_drenagem_l USING gist (geom); +)# +CREATE INDEX hid_trecho_drenagem_l_geom ON edgv.hid_trecho_drenagem_l USING gist (geom)# -ALTER TABLE edgv.hid_trecho_drenagem_l OWNER TO postgres; +ALTER TABLE edgv.hid_trecho_drenagem_l OWNER TO postgres# ALTER TABLE edgv.hid_trecho_drenagem_l ADD CONSTRAINT hid_trecho_drenagem_l_tipotrechodrenagem_fk FOREIGN KEY (tipotrechodrenagem) REFERENCES dominios.tipo_trecho_drenagem (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_trecho_drenagem_l ALTER COLUMN tipotrechodrenagem SET DEFAULT 9999; +ALTER TABLE edgv.hid_trecho_drenagem_l ALTER COLUMN tipotrechodrenagem SET DEFAULT 9999# ALTER TABLE edgv.hid_trecho_drenagem_l ADD CONSTRAINT hid_trecho_drenagem_l_navegavel_fk FOREIGN KEY (navegavel) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_trecho_drenagem_l ALTER COLUMN navegavel SET DEFAULT 9999; +ALTER TABLE edgv.hid_trecho_drenagem_l ALTER COLUMN navegavel SET DEFAULT 9999# ALTER TABLE edgv.hid_trecho_drenagem_l ADD CONSTRAINT hid_trecho_drenagem_l_regime_fk FOREIGN KEY (regime) REFERENCES dominios.regime (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_trecho_drenagem_l ALTER COLUMN regime SET DEFAULT 9999; +ALTER TABLE edgv.hid_trecho_drenagem_l ALTER COLUMN regime SET DEFAULT 9999# CREATE TABLE edgv.hid_comporta_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hid_comporta_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_comporta_l_geom ON edgv.hid_comporta_l USING gist (geom); +)# +CREATE INDEX hid_comporta_l_geom ON edgv.hid_comporta_l USING gist (geom)# -ALTER TABLE edgv.hid_comporta_l OWNER TO postgres; +ALTER TABLE edgv.hid_comporta_l OWNER TO postgres# ALTER TABLE edgv.hid_comporta_l ADD CONSTRAINT hid_comporta_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_comporta_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hid_comporta_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hid_comporta_l ADD CONSTRAINT hid_comporta_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_comporta_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hid_comporta_l ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.hid_comporta_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hid_comporta_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_comporta_p_geom ON edgv.hid_comporta_p USING gist (geom); +)# +CREATE INDEX hid_comporta_p_geom ON edgv.hid_comporta_p USING gist (geom)# -ALTER TABLE edgv.hid_comporta_p OWNER TO postgres; +ALTER TABLE edgv.hid_comporta_p OWNER TO postgres# ALTER TABLE edgv.hid_comporta_p ADD CONSTRAINT hid_comporta_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_comporta_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hid_comporta_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hid_comporta_p ADD CONSTRAINT hid_comporta_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_comporta_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hid_comporta_p ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.hid_corredeira_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hid_corredeira_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_corredeira_l_geom ON edgv.hid_corredeira_l USING gist (geom); +)# +CREATE INDEX hid_corredeira_l_geom ON edgv.hid_corredeira_l USING gist (geom)# -ALTER TABLE edgv.hid_corredeira_l OWNER TO postgres; +ALTER TABLE edgv.hid_corredeira_l OWNER TO postgres# CREATE TABLE edgv.hid_corredeira_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hid_corredeira_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_corredeira_p_geom ON edgv.hid_corredeira_p USING gist (geom); +)# +CREATE INDEX hid_corredeira_p_geom ON edgv.hid_corredeira_p USING gist (geom)# -ALTER TABLE edgv.hid_corredeira_p OWNER TO postgres; +ALTER TABLE edgv.hid_corredeira_p OWNER TO postgres# CREATE TABLE edgv.hid_corredeira_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hid_corredeira_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_corredeira_a_geom ON edgv.hid_corredeira_a USING gist (geom); +)# +CREATE INDEX hid_corredeira_a_geom ON edgv.hid_corredeira_a USING gist (geom)# -ALTER TABLE edgv.hid_corredeira_a OWNER TO postgres; +ALTER TABLE edgv.hid_corredeira_a OWNER TO postgres# CREATE TABLE edgv.hid_queda_dagua_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoqueda smallint NOT NULL, altura real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hid_queda_dagua_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_queda_dagua_p_geom ON edgv.hid_queda_dagua_p USING gist (geom); +)# +CREATE INDEX hid_queda_dagua_p_geom ON edgv.hid_queda_dagua_p USING gist (geom)# -ALTER TABLE edgv.hid_queda_dagua_p OWNER TO postgres; +ALTER TABLE edgv.hid_queda_dagua_p OWNER TO postgres# ALTER TABLE edgv.hid_queda_dagua_p ADD CONSTRAINT hid_queda_dagua_p_tipoqueda_fk FOREIGN KEY (tipoqueda) REFERENCES dominios.tipo_queda (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_queda_dagua_p ALTER COLUMN tipoqueda SET DEFAULT 9999; +ALTER TABLE edgv.hid_queda_dagua_p ALTER COLUMN tipoqueda SET DEFAULT 9999# CREATE TABLE edgv.hid_queda_dagua_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoqueda smallint NOT NULL, altura real, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hid_queda_dagua_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_queda_dagua_l_geom ON edgv.hid_queda_dagua_l USING gist (geom); +)# +CREATE INDEX hid_queda_dagua_l_geom ON edgv.hid_queda_dagua_l USING gist (geom)# -ALTER TABLE edgv.hid_queda_dagua_l OWNER TO postgres; +ALTER TABLE edgv.hid_queda_dagua_l OWNER TO postgres# ALTER TABLE edgv.hid_queda_dagua_l ADD CONSTRAINT hid_queda_dagua_l_tipoqueda_fk FOREIGN KEY (tipoqueda) REFERENCES dominios.tipo_queda (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_queda_dagua_l ALTER COLUMN tipoqueda SET DEFAULT 9999; +ALTER TABLE edgv.hid_queda_dagua_l ALTER COLUMN tipoqueda SET DEFAULT 9999# CREATE TABLE edgv.hid_recife_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tiporecife smallint NOT NULL, situacaoemagua smallint NOT NULL, situacaocosta smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hid_recife_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_recife_p_geom ON edgv.hid_recife_p USING gist (geom); +)# +CREATE INDEX hid_recife_p_geom ON edgv.hid_recife_p USING gist (geom)# -ALTER TABLE edgv.hid_recife_p OWNER TO postgres; +ALTER TABLE edgv.hid_recife_p OWNER TO postgres# ALTER TABLE edgv.hid_recife_p ADD CONSTRAINT hid_recife_p_tiporecife_fk FOREIGN KEY (tiporecife) REFERENCES dominios.tipo_recife (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_recife_p ALTER COLUMN tiporecife SET DEFAULT 9999; +ALTER TABLE edgv.hid_recife_p ALTER COLUMN tiporecife SET DEFAULT 9999# ALTER TABLE edgv.hid_recife_p ADD CONSTRAINT hid_recife_p_situacaoemagua_fk FOREIGN KEY (situacaoemagua) REFERENCES dominios.situacao_em_agua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_recife_p ALTER COLUMN situacaoemagua SET DEFAULT 9999; +ALTER TABLE edgv.hid_recife_p ALTER COLUMN situacaoemagua SET DEFAULT 9999# ALTER TABLE edgv.hid_recife_p ADD CONSTRAINT hid_recife_p_situacaocosta_fk FOREIGN KEY (situacaocosta) REFERENCES dominios.situacao_costa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_recife_p ALTER COLUMN situacaocosta SET DEFAULT 9999; +ALTER TABLE edgv.hid_recife_p ALTER COLUMN situacaocosta SET DEFAULT 9999# CREATE TABLE edgv.hid_recife_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tiporecife smallint NOT NULL, situacaoemagua smallint NOT NULL, situacaocosta smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hid_recife_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_recife_a_geom ON edgv.hid_recife_a USING gist (geom); +)# +CREATE INDEX hid_recife_a_geom ON edgv.hid_recife_a USING gist (geom)# -ALTER TABLE edgv.hid_recife_a OWNER TO postgres; +ALTER TABLE edgv.hid_recife_a OWNER TO postgres# ALTER TABLE edgv.hid_recife_a ADD CONSTRAINT hid_recife_a_tiporecife_fk FOREIGN KEY (tiporecife) REFERENCES dominios.tipo_recife (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_recife_a ALTER COLUMN tiporecife SET DEFAULT 9999; +ALTER TABLE edgv.hid_recife_a ALTER COLUMN tiporecife SET DEFAULT 9999# ALTER TABLE edgv.hid_recife_a ADD CONSTRAINT hid_recife_a_situacaoemagua_fk FOREIGN KEY (situacaoemagua) REFERENCES dominios.situacao_em_agua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_recife_a ALTER COLUMN situacaoemagua SET DEFAULT 9999; +ALTER TABLE edgv.hid_recife_a ALTER COLUMN situacaoemagua SET DEFAULT 9999# ALTER TABLE edgv.hid_recife_a ADD CONSTRAINT hid_recife_a_situacaocosta_fk FOREIGN KEY (situacaocosta) REFERENCES dominios.situacao_costa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_recife_a ALTER COLUMN situacaocosta SET DEFAULT 9999; +ALTER TABLE edgv.hid_recife_a ALTER COLUMN situacaocosta SET DEFAULT 9999# CREATE TABLE edgv.hid_terreno_sujeito_inundacao_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, periodicidadeinunda varchar(20), + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hid_terreno_sujeito_inundacao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_terreno_sujeito_inundacao_a_geom ON edgv.hid_terreno_sujeito_inundacao_a USING gist (geom); +)# +CREATE INDEX hid_terreno_sujeito_inundacao_a_geom ON edgv.hid_terreno_sujeito_inundacao_a USING gist (geom)# -ALTER TABLE edgv.hid_terreno_sujeito_inundacao_a OWNER TO postgres; +ALTER TABLE edgv.hid_terreno_sujeito_inundacao_a OWNER TO postgres# CREATE TABLE edgv.hid_rocha_em_agua_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, formarocha smallint NOT NULL, situacaoemagua smallint NOT NULL, alturalamina real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hid_rocha_em_agua_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_rocha_em_agua_p_geom ON edgv.hid_rocha_em_agua_p USING gist (geom); +)# +CREATE INDEX hid_rocha_em_agua_p_geom ON edgv.hid_rocha_em_agua_p USING gist (geom)# -ALTER TABLE edgv.hid_rocha_em_agua_p OWNER TO postgres; +ALTER TABLE edgv.hid_rocha_em_agua_p OWNER TO postgres# ALTER TABLE edgv.hid_rocha_em_agua_p ADD CONSTRAINT hid_rocha_em_agua_p_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hid_rocha_em_agua_p - ADD CONSTRAINT hid_rocha_em_agua_p_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[23 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hid_rocha_em_agua_p ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT hid_rocha_em_agua_p_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[23 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hid_rocha_em_agua_p ALTER COLUMN tipoelemnat SET DEFAULT 9999# ALTER TABLE edgv.hid_rocha_em_agua_p ADD CONSTRAINT hid_rocha_em_agua_p_formarocha_fk FOREIGN KEY (formarocha) REFERENCES dominios.forma_rocha (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_rocha_em_agua_p ALTER COLUMN formarocha SET DEFAULT 9999; +ALTER TABLE edgv.hid_rocha_em_agua_p ALTER COLUMN formarocha SET DEFAULT 9999# ALTER TABLE edgv.hid_rocha_em_agua_p ADD CONSTRAINT hid_rocha_em_agua_p_situacaoemagua_fk FOREIGN KEY (situacaoemagua) REFERENCES dominios.situacao_em_agua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_rocha_em_agua_p ALTER COLUMN situacaoemagua SET DEFAULT 9999; +ALTER TABLE edgv.hid_rocha_em_agua_p ALTER COLUMN situacaoemagua SET DEFAULT 9999# CREATE TABLE edgv.hid_rocha_em_agua_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, formarocha smallint NOT NULL, situacaoemagua smallint NOT NULL, alturalamina real, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hid_rocha_em_agua_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_rocha_em_agua_a_geom ON edgv.hid_rocha_em_agua_a USING gist (geom); +)# +CREATE INDEX hid_rocha_em_agua_a_geom ON edgv.hid_rocha_em_agua_a USING gist (geom)# -ALTER TABLE edgv.hid_rocha_em_agua_a OWNER TO postgres; +ALTER TABLE edgv.hid_rocha_em_agua_a OWNER TO postgres# ALTER TABLE edgv.hid_rocha_em_agua_a ADD CONSTRAINT hid_rocha_em_agua_a_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.hid_rocha_em_agua_a - ADD CONSTRAINT hid_rocha_em_agua_a_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[23 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.hid_rocha_em_agua_a ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT hid_rocha_em_agua_a_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[23 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.hid_rocha_em_agua_a ALTER COLUMN tipoelemnat SET DEFAULT 9999# ALTER TABLE edgv.hid_rocha_em_agua_a ADD CONSTRAINT hid_rocha_em_agua_a_formarocha_fk FOREIGN KEY (formarocha) REFERENCES dominios.forma_rocha (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_rocha_em_agua_a ALTER COLUMN formarocha SET DEFAULT 9999; +ALTER TABLE edgv.hid_rocha_em_agua_a ALTER COLUMN formarocha SET DEFAULT 9999# ALTER TABLE edgv.hid_rocha_em_agua_a ADD CONSTRAINT hid_rocha_em_agua_a_situacaoemagua_fk FOREIGN KEY (situacaoemagua) REFERENCES dominios.situacao_em_agua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_rocha_em_agua_a ALTER COLUMN situacaoemagua SET DEFAULT 9999; +ALTER TABLE edgv.hid_rocha_em_agua_a ALTER COLUMN situacaoemagua SET DEFAULT 9999# CREATE TABLE edgv.hid_banco_areia_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipobanco smallint NOT NULL, situacaoemagua smallint NOT NULL, materialpredominante smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hid_banco_areia_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_banco_areia_a_geom ON edgv.hid_banco_areia_a USING gist (geom); +)# +CREATE INDEX hid_banco_areia_a_geom ON edgv.hid_banco_areia_a USING gist (geom)# -ALTER TABLE edgv.hid_banco_areia_a OWNER TO postgres; +ALTER TABLE edgv.hid_banco_areia_a OWNER TO postgres# ALTER TABLE edgv.hid_banco_areia_a ADD CONSTRAINT hid_banco_areia_a_tipobanco_fk FOREIGN KEY (tipobanco) REFERENCES dominios.tipo_banco (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_banco_areia_a ALTER COLUMN tipobanco SET DEFAULT 9999; +ALTER TABLE edgv.hid_banco_areia_a ALTER COLUMN tipobanco SET DEFAULT 9999# ALTER TABLE edgv.hid_banco_areia_a ADD CONSTRAINT hid_banco_areia_a_situacaoemagua_fk FOREIGN KEY (situacaoemagua) REFERENCES dominios.situacao_em_agua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_banco_areia_a ALTER COLUMN situacaoemagua SET DEFAULT 9999; +ALTER TABLE edgv.hid_banco_areia_a ALTER COLUMN situacaoemagua SET DEFAULT 9999# ALTER TABLE edgv.hid_banco_areia_a ADD CONSTRAINT hid_banco_areia_a_materialpredominante_fk FOREIGN KEY (materialpredominante) REFERENCES dominios.material_predominante (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_banco_areia_a ALTER COLUMN materialpredominante SET DEFAULT 9999; +ALTER TABLE edgv.hid_banco_areia_a ALTER COLUMN materialpredominante SET DEFAULT 9999# CREATE TABLE edgv.hid_quebramar_molhe_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoquebramolhe smallint NOT NULL, @@ -14340,51 +14631,52 @@ CREATE TABLE edgv.hid_quebramar_molhe_l( matconstr smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hid_quebramar_molhe_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_quebramar_molhe_l_geom ON edgv.hid_quebramar_molhe_l USING gist (geom); +)# +CREATE INDEX hid_quebramar_molhe_l_geom ON edgv.hid_quebramar_molhe_l USING gist (geom)# -ALTER TABLE edgv.hid_quebramar_molhe_l OWNER TO postgres; +ALTER TABLE edgv.hid_quebramar_molhe_l OWNER TO postgres# ALTER TABLE edgv.hid_quebramar_molhe_l ADD CONSTRAINT hid_quebramar_molhe_l_tipoquebramolhe_fk FOREIGN KEY (tipoquebramolhe) REFERENCES dominios.tipo_quebra_molhe (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_quebramar_molhe_l ALTER COLUMN tipoquebramolhe SET DEFAULT 9999; +ALTER TABLE edgv.hid_quebramar_molhe_l ALTER COLUMN tipoquebramolhe SET DEFAULT 9999# ALTER TABLE edgv.hid_quebramar_molhe_l ADD CONSTRAINT hid_quebramar_molhe_l_situacaoemagua_fk FOREIGN KEY (situacaoemagua) REFERENCES dominios.situacao_em_agua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_quebramar_molhe_l ALTER COLUMN situacaoemagua SET DEFAULT 9999; +ALTER TABLE edgv.hid_quebramar_molhe_l ALTER COLUMN situacaoemagua SET DEFAULT 9999# ALTER TABLE edgv.hid_quebramar_molhe_l ADD CONSTRAINT hid_quebramar_molhe_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_quebramar_molhe_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hid_quebramar_molhe_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hid_quebramar_molhe_l ADD CONSTRAINT hid_quebramar_molhe_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_quebramar_molhe_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hid_quebramar_molhe_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hid_quebramar_molhe_l ADD CONSTRAINT hid_quebramar_molhe_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_quebramar_molhe_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hid_quebramar_molhe_l ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.hid_quebramar_molhe_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoquebramolhe smallint NOT NULL, @@ -14392,750 +14684,779 @@ CREATE TABLE edgv.hid_quebramar_molhe_a( matconstr smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hid_quebramar_molhe_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_quebramar_molhe_a_geom ON edgv.hid_quebramar_molhe_a USING gist (geom); +)# +CREATE INDEX hid_quebramar_molhe_a_geom ON edgv.hid_quebramar_molhe_a USING gist (geom)# -ALTER TABLE edgv.hid_quebramar_molhe_a OWNER TO postgres; +ALTER TABLE edgv.hid_quebramar_molhe_a OWNER TO postgres# ALTER TABLE edgv.hid_quebramar_molhe_a ADD CONSTRAINT hid_quebramar_molhe_a_tipoquebramolhe_fk FOREIGN KEY (tipoquebramolhe) REFERENCES dominios.tipo_quebra_molhe (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_quebramar_molhe_a ALTER COLUMN tipoquebramolhe SET DEFAULT 9999; +ALTER TABLE edgv.hid_quebramar_molhe_a ALTER COLUMN tipoquebramolhe SET DEFAULT 9999# ALTER TABLE edgv.hid_quebramar_molhe_a ADD CONSTRAINT hid_quebramar_molhe_a_situacaoemagua_fk FOREIGN KEY (situacaoemagua) REFERENCES dominios.situacao_em_agua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_quebramar_molhe_a ALTER COLUMN situacaoemagua SET DEFAULT 9999; +ALTER TABLE edgv.hid_quebramar_molhe_a ALTER COLUMN situacaoemagua SET DEFAULT 9999# ALTER TABLE edgv.hid_quebramar_molhe_a ADD CONSTRAINT hid_quebramar_molhe_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_quebramar_molhe_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hid_quebramar_molhe_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hid_quebramar_molhe_a ADD CONSTRAINT hid_quebramar_molhe_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_quebramar_molhe_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hid_quebramar_molhe_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hid_quebramar_molhe_a ADD CONSTRAINT hid_quebramar_molhe_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_quebramar_molhe_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hid_quebramar_molhe_a ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.hid_foz_maritima_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hid_foz_maritima_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_foz_maritima_l_geom ON edgv.hid_foz_maritima_l USING gist (geom); +)# +CREATE INDEX hid_foz_maritima_l_geom ON edgv.hid_foz_maritima_l USING gist (geom)# -ALTER TABLE edgv.hid_foz_maritima_l OWNER TO postgres; +ALTER TABLE edgv.hid_foz_maritima_l OWNER TO postgres# CREATE TABLE edgv.hid_foz_maritima_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hid_foz_maritima_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_foz_maritima_p_geom ON edgv.hid_foz_maritima_p USING gist (geom); +)# +CREATE INDEX hid_foz_maritima_p_geom ON edgv.hid_foz_maritima_p USING gist (geom)# -ALTER TABLE edgv.hid_foz_maritima_p OWNER TO postgres; +ALTER TABLE edgv.hid_foz_maritima_p OWNER TO postgres# CREATE TABLE edgv.hid_fonte_dagua_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipofontedagua smallint NOT NULL, qualidagua smallint NOT NULL, regime smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hid_fonte_dagua_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_fonte_dagua_p_geom ON edgv.hid_fonte_dagua_p USING gist (geom); +)# +CREATE INDEX hid_fonte_dagua_p_geom ON edgv.hid_fonte_dagua_p USING gist (geom)# -ALTER TABLE edgv.hid_fonte_dagua_p OWNER TO postgres; +ALTER TABLE edgv.hid_fonte_dagua_p OWNER TO postgres# ALTER TABLE edgv.hid_fonte_dagua_p ADD CONSTRAINT hid_fonte_dagua_p_tipofontedagua_fk FOREIGN KEY (tipofontedagua) REFERENCES dominios.tipo_fonte_dagua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_fonte_dagua_p ALTER COLUMN tipofontedagua SET DEFAULT 9999; +ALTER TABLE edgv.hid_fonte_dagua_p ALTER COLUMN tipofontedagua SET DEFAULT 9999# ALTER TABLE edgv.hid_fonte_dagua_p ADD CONSTRAINT hid_fonte_dagua_p_qualidagua_fk FOREIGN KEY (qualidagua) REFERENCES dominios.qualid_agua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_fonte_dagua_p ALTER COLUMN qualidagua SET DEFAULT 9999; +ALTER TABLE edgv.hid_fonte_dagua_p ALTER COLUMN qualidagua SET DEFAULT 9999# ALTER TABLE edgv.hid_fonte_dagua_p ADD CONSTRAINT hid_fonte_dagua_p_regime_fk FOREIGN KEY (regime) REFERENCES dominios.regime (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_fonte_dagua_p ALTER COLUMN regime SET DEFAULT 9999; +ALTER TABLE edgv.hid_fonte_dagua_p ALTER COLUMN regime SET DEFAULT 9999# CREATE TABLE edgv.hid_area_umida_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoareaumida smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hid_area_umida_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_area_umida_a_geom ON edgv.hid_area_umida_a USING gist (geom); +)# +CREATE INDEX hid_area_umida_a_geom ON edgv.hid_area_umida_a USING gist (geom)# -ALTER TABLE edgv.hid_area_umida_a OWNER TO postgres; +ALTER TABLE edgv.hid_area_umida_a OWNER TO postgres# ALTER TABLE edgv.hid_area_umida_a ADD CONSTRAINT hid_area_umida_a_tipoareaumida_fk FOREIGN KEY (tipoareaumida) REFERENCES dominios.tipo_area_umida (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_area_umida_a ALTER COLUMN tipoareaumida SET DEFAULT 9999; +ALTER TABLE edgv.hid_area_umida_a ALTER COLUMN tipoareaumida SET DEFAULT 9999# CREATE TABLE edgv.hid_barragem_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, matconstr smallint NOT NULL, usoprincipal smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT hid_barragem_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_barragem_l_geom ON edgv.hid_barragem_l USING gist (geom); +)# +CREATE INDEX hid_barragem_l_geom ON edgv.hid_barragem_l USING gist (geom)# -ALTER TABLE edgv.hid_barragem_l OWNER TO postgres; +ALTER TABLE edgv.hid_barragem_l OWNER TO postgres# ALTER TABLE edgv.hid_barragem_l ADD CONSTRAINT hid_barragem_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_barragem_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hid_barragem_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hid_barragem_l ADD CONSTRAINT hid_barragem_l_usoprincipal_fk FOREIGN KEY (usoprincipal) REFERENCES dominios.uso_principal (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_barragem_l ALTER COLUMN usoprincipal SET DEFAULT 9999; +ALTER TABLE edgv.hid_barragem_l ALTER COLUMN usoprincipal SET DEFAULT 9999# ALTER TABLE edgv.hid_barragem_l ADD CONSTRAINT hid_barragem_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_barragem_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hid_barragem_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hid_barragem_l ADD CONSTRAINT hid_barragem_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_barragem_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hid_barragem_l ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.hid_barragem_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, matconstr smallint NOT NULL, usoprincipal smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT hid_barragem_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_barragem_p_geom ON edgv.hid_barragem_p USING gist (geom); +)# +CREATE INDEX hid_barragem_p_geom ON edgv.hid_barragem_p USING gist (geom)# -ALTER TABLE edgv.hid_barragem_p OWNER TO postgres; +ALTER TABLE edgv.hid_barragem_p OWNER TO postgres# ALTER TABLE edgv.hid_barragem_p ADD CONSTRAINT hid_barragem_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_barragem_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hid_barragem_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hid_barragem_p ADD CONSTRAINT hid_barragem_p_usoprincipal_fk FOREIGN KEY (usoprincipal) REFERENCES dominios.uso_principal (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_barragem_p ALTER COLUMN usoprincipal SET DEFAULT 9999; +ALTER TABLE edgv.hid_barragem_p ALTER COLUMN usoprincipal SET DEFAULT 9999# ALTER TABLE edgv.hid_barragem_p ADD CONSTRAINT hid_barragem_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_barragem_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hid_barragem_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hid_barragem_p ADD CONSTRAINT hid_barragem_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_barragem_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hid_barragem_p ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.hid_barragem_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, matconstr smallint NOT NULL, usoprincipal smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT hid_barragem_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX hid_barragem_a_geom ON edgv.hid_barragem_a USING gist (geom); +)# +CREATE INDEX hid_barragem_a_geom ON edgv.hid_barragem_a USING gist (geom)# -ALTER TABLE edgv.hid_barragem_a OWNER TO postgres; +ALTER TABLE edgv.hid_barragem_a OWNER TO postgres# ALTER TABLE edgv.hid_barragem_a ADD CONSTRAINT hid_barragem_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_barragem_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.hid_barragem_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.hid_barragem_a ADD CONSTRAINT hid_barragem_a_usoprincipal_fk FOREIGN KEY (usoprincipal) REFERENCES dominios.uso_principal (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_barragem_a ALTER COLUMN usoprincipal SET DEFAULT 9999; +ALTER TABLE edgv.hid_barragem_a ALTER COLUMN usoprincipal SET DEFAULT 9999# ALTER TABLE edgv.hid_barragem_a ADD CONSTRAINT hid_barragem_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_barragem_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.hid_barragem_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.hid_barragem_a ADD CONSTRAINT hid_barragem_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.hid_barragem_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.hid_barragem_a ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.laz_sitio_arqueologico_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, turistica smallint NOT NULL, cultura smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT laz_sitio_arqueologico_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX laz_sitio_arqueologico_p_geom ON edgv.laz_sitio_arqueologico_p USING gist (geom); +)# +CREATE INDEX laz_sitio_arqueologico_p_geom ON edgv.laz_sitio_arqueologico_p USING gist (geom)# -ALTER TABLE edgv.laz_sitio_arqueologico_p OWNER TO postgres; +ALTER TABLE edgv.laz_sitio_arqueologico_p OWNER TO postgres# ALTER TABLE edgv.laz_sitio_arqueologico_p ADD CONSTRAINT laz_sitio_arqueologico_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_sitio_arqueologico_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.laz_sitio_arqueologico_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.laz_sitio_arqueologico_p ADD CONSTRAINT laz_sitio_arqueologico_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.laz_sitio_arqueologico_p - ADD CONSTRAINT laz_sitio_arqueologico_p_cultura_check - CHECK (cultura = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.laz_sitio_arqueologico_p ALTER COLUMN cultura SET DEFAULT 9999; + ADD CONSTRAINT laz_sitio_arqueologico_p_cultura_check + CHECK (cultura = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.laz_sitio_arqueologico_p ALTER COLUMN cultura SET DEFAULT 9999# CREATE TABLE edgv.laz_sitio_arqueologico_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, turistica smallint NOT NULL, cultura smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT laz_sitio_arqueologico_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX laz_sitio_arqueologico_a_geom ON edgv.laz_sitio_arqueologico_a USING gist (geom); +)# +CREATE INDEX laz_sitio_arqueologico_a_geom ON edgv.laz_sitio_arqueologico_a USING gist (geom)# -ALTER TABLE edgv.laz_sitio_arqueologico_a OWNER TO postgres; +ALTER TABLE edgv.laz_sitio_arqueologico_a OWNER TO postgres# ALTER TABLE edgv.laz_sitio_arqueologico_a ADD CONSTRAINT laz_sitio_arqueologico_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_sitio_arqueologico_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.laz_sitio_arqueologico_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.laz_sitio_arqueologico_a ADD CONSTRAINT laz_sitio_arqueologico_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.laz_sitio_arqueologico_a - ADD CONSTRAINT laz_sitio_arqueologico_a_cultura_check - CHECK (cultura = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.laz_sitio_arqueologico_a ALTER COLUMN cultura SET DEFAULT 9999; + ADD CONSTRAINT laz_sitio_arqueologico_a_cultura_check + CHECK (cultura = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.laz_sitio_arqueologico_a ALTER COLUMN cultura SET DEFAULT 9999# CREATE TABLE edgv.laz_pista_competicao_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, tipopistacomp smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT laz_pista_competicao_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX laz_pista_competicao_l_geom ON edgv.laz_pista_competicao_l USING gist (geom); +)# +CREATE INDEX laz_pista_competicao_l_geom ON edgv.laz_pista_competicao_l USING gist (geom)# -ALTER TABLE edgv.laz_pista_competicao_l OWNER TO postgres; +ALTER TABLE edgv.laz_pista_competicao_l OWNER TO postgres# ALTER TABLE edgv.laz_pista_competicao_l ADD CONSTRAINT laz_pista_competicao_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_pista_competicao_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.laz_pista_competicao_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.laz_pista_competicao_l ADD CONSTRAINT laz_pista_competicao_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_pista_competicao_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.laz_pista_competicao_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.laz_pista_competicao_l ADD CONSTRAINT laz_pista_competicao_l_tipopistacomp_fk FOREIGN KEY (tipopistacomp) REFERENCES dominios.tipo_pista_comp (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_pista_competicao_l ALTER COLUMN tipopistacomp SET DEFAULT 9999; +ALTER TABLE edgv.laz_pista_competicao_l ALTER COLUMN tipopistacomp SET DEFAULT 9999# CREATE TABLE edgv.laz_pista_competicao_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, tipopistacomp smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT laz_pista_competicao_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX laz_pista_competicao_p_geom ON edgv.laz_pista_competicao_p USING gist (geom); +)# +CREATE INDEX laz_pista_competicao_p_geom ON edgv.laz_pista_competicao_p USING gist (geom)# -ALTER TABLE edgv.laz_pista_competicao_p OWNER TO postgres; +ALTER TABLE edgv.laz_pista_competicao_p OWNER TO postgres# ALTER TABLE edgv.laz_pista_competicao_p ADD CONSTRAINT laz_pista_competicao_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_pista_competicao_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.laz_pista_competicao_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.laz_pista_competicao_p ADD CONSTRAINT laz_pista_competicao_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_pista_competicao_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.laz_pista_competicao_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.laz_pista_competicao_p ADD CONSTRAINT laz_pista_competicao_p_tipopistacomp_fk FOREIGN KEY (tipopistacomp) REFERENCES dominios.tipo_pista_comp (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_pista_competicao_p ALTER COLUMN tipopistacomp SET DEFAULT 9999; +ALTER TABLE edgv.laz_pista_competicao_p ALTER COLUMN tipopistacomp SET DEFAULT 9999# CREATE TABLE edgv.laz_pista_competicao_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, tipopistacomp smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT laz_pista_competicao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX laz_pista_competicao_a_geom ON edgv.laz_pista_competicao_a USING gist (geom); +)# +CREATE INDEX laz_pista_competicao_a_geom ON edgv.laz_pista_competicao_a USING gist (geom)# -ALTER TABLE edgv.laz_pista_competicao_a OWNER TO postgres; +ALTER TABLE edgv.laz_pista_competicao_a OWNER TO postgres# ALTER TABLE edgv.laz_pista_competicao_a ADD CONSTRAINT laz_pista_competicao_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_pista_competicao_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.laz_pista_competicao_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.laz_pista_competicao_a ADD CONSTRAINT laz_pista_competicao_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_pista_competicao_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.laz_pista_competicao_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.laz_pista_competicao_a ADD CONSTRAINT laz_pista_competicao_a_tipopistacomp_fk FOREIGN KEY (tipopistacomp) REFERENCES dominios.tipo_pista_comp (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_pista_competicao_a ALTER COLUMN tipopistacomp SET DEFAULT 9999; +ALTER TABLE edgv.laz_pista_competicao_a ALTER COLUMN tipopistacomp SET DEFAULT 9999# CREATE TABLE edgv.laz_arquibancada_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT laz_arquibancada_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX laz_arquibancada_a_geom ON edgv.laz_arquibancada_a USING gist (geom); +)# +CREATE INDEX laz_arquibancada_a_geom ON edgv.laz_arquibancada_a USING gist (geom)# -ALTER TABLE edgv.laz_arquibancada_a OWNER TO postgres; +ALTER TABLE edgv.laz_arquibancada_a OWNER TO postgres# ALTER TABLE edgv.laz_arquibancada_a ADD CONSTRAINT laz_arquibancada_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_arquibancada_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.laz_arquibancada_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.laz_arquibancada_a ADD CONSTRAINT laz_arquibancada_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_arquibancada_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.laz_arquibancada_a ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.laz_campo_quadra_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, tipocampoquadra smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT laz_campo_quadra_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX laz_campo_quadra_p_geom ON edgv.laz_campo_quadra_p USING gist (geom); +)# +CREATE INDEX laz_campo_quadra_p_geom ON edgv.laz_campo_quadra_p USING gist (geom)# -ALTER TABLE edgv.laz_campo_quadra_p OWNER TO postgres; +ALTER TABLE edgv.laz_campo_quadra_p OWNER TO postgres# ALTER TABLE edgv.laz_campo_quadra_p ADD CONSTRAINT laz_campo_quadra_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_campo_quadra_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.laz_campo_quadra_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.laz_campo_quadra_p ADD CONSTRAINT laz_campo_quadra_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_campo_quadra_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.laz_campo_quadra_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.laz_campo_quadra_p ADD CONSTRAINT laz_campo_quadra_p_tipocampoquadra_fk FOREIGN KEY (tipocampoquadra) REFERENCES dominios.tipo_campo_quadra (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_campo_quadra_p ALTER COLUMN tipocampoquadra SET DEFAULT 9999; +ALTER TABLE edgv.laz_campo_quadra_p ALTER COLUMN tipocampoquadra SET DEFAULT 9999# CREATE TABLE edgv.laz_campo_quadra_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, tipocampoquadra smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT laz_campo_quadra_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX laz_campo_quadra_a_geom ON edgv.laz_campo_quadra_a USING gist (geom); +)# +CREATE INDEX laz_campo_quadra_a_geom ON edgv.laz_campo_quadra_a USING gist (geom)# -ALTER TABLE edgv.laz_campo_quadra_a OWNER TO postgres; +ALTER TABLE edgv.laz_campo_quadra_a OWNER TO postgres# ALTER TABLE edgv.laz_campo_quadra_a ADD CONSTRAINT laz_campo_quadra_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_campo_quadra_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.laz_campo_quadra_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.laz_campo_quadra_a ADD CONSTRAINT laz_campo_quadra_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_campo_quadra_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.laz_campo_quadra_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.laz_campo_quadra_a ADD CONSTRAINT laz_campo_quadra_a_tipocampoquadra_fk FOREIGN KEY (tipocampoquadra) REFERENCES dominios.tipo_campo_quadra (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_campo_quadra_a ALTER COLUMN tipocampoquadra SET DEFAULT 9999; +ALTER TABLE edgv.laz_campo_quadra_a ALTER COLUMN tipocampoquadra SET DEFAULT 9999# CREATE TABLE edgv.laz_piscina_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT laz_piscina_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX laz_piscina_a_geom ON edgv.laz_piscina_a USING gist (geom); +)# +CREATE INDEX laz_piscina_a_geom ON edgv.laz_piscina_a USING gist (geom)# -ALTER TABLE edgv.laz_piscina_a OWNER TO postgres; +ALTER TABLE edgv.laz_piscina_a OWNER TO postgres# ALTER TABLE edgv.laz_piscina_a ADD CONSTRAINT laz_piscina_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_piscina_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.laz_piscina_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.laz_piscina_a ADD CONSTRAINT laz_piscina_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_piscina_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.laz_piscina_a ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.laz_ruina_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, turistica smallint NOT NULL, cultura smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT laz_ruina_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX laz_ruina_p_geom ON edgv.laz_ruina_p USING gist (geom); +)# +CREATE INDEX laz_ruina_p_geom ON edgv.laz_ruina_p USING gist (geom)# -ALTER TABLE edgv.laz_ruina_p OWNER TO postgres; +ALTER TABLE edgv.laz_ruina_p OWNER TO postgres# ALTER TABLE edgv.laz_ruina_p ADD CONSTRAINT laz_ruina_p_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_ruina_p ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.laz_ruina_p ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.laz_ruina_p ADD CONSTRAINT laz_ruina_p_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.laz_ruina_p - ADD CONSTRAINT laz_ruina_p_cultura_check - CHECK (cultura = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.laz_ruina_p ALTER COLUMN cultura SET DEFAULT 9999; + ADD CONSTRAINT laz_ruina_p_cultura_check + CHECK (cultura = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.laz_ruina_p ALTER COLUMN cultura SET DEFAULT 9999# CREATE TABLE edgv.laz_ruina_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, turistica smallint NOT NULL, cultura smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT laz_ruina_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX laz_ruina_a_geom ON edgv.laz_ruina_a USING gist (geom); +)# +CREATE INDEX laz_ruina_a_geom ON edgv.laz_ruina_a USING gist (geom)# -ALTER TABLE edgv.laz_ruina_a OWNER TO postgres; +ALTER TABLE edgv.laz_ruina_a OWNER TO postgres# ALTER TABLE edgv.laz_ruina_a ADD CONSTRAINT laz_ruina_a_turistica_fk FOREIGN KEY (turistica) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.laz_ruina_a ALTER COLUMN turistica SET DEFAULT 9999; +ALTER TABLE edgv.laz_ruina_a ALTER COLUMN turistica SET DEFAULT 9999# ALTER TABLE edgv.laz_ruina_a ADD CONSTRAINT laz_ruina_a_cultura_fk FOREIGN KEY (cultura) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.laz_ruina_a - ADD CONSTRAINT laz_ruina_a_cultura_check - CHECK (cultura = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.laz_ruina_a ALTER COLUMN cultura SET DEFAULT 9999; + ADD CONSTRAINT laz_ruina_a_cultura_check + CHECK (cultura = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.laz_ruina_a ALTER COLUMN cultura SET DEFAULT 9999# CREATE TABLE edgv.lml_pais_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, sigla varchar(3), codiso3166 varchar(3), + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT lml_pais_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_pais_a_geom ON edgv.lml_pais_a USING gist (geom); +)# +CREATE INDEX lml_pais_a_geom ON edgv.lml_pais_a USING gist (geom)# -ALTER TABLE edgv.lml_pais_a OWNER TO postgres; +ALTER TABLE edgv.lml_pais_a OWNER TO postgres# CREATE TABLE edgv.lml_posic_geo_localidade_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, - identificador varchar(80), + identificador varchar(255), latitude varchar(16), longitude varchar(16), - nomelocal varchar(80), + nomelocal varchar(255), anodereferencia integer, tipolocalidade smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT lml_posic_geo_localidade_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_posic_geo_localidade_p_geom ON edgv.lml_posic_geo_localidade_p USING gist (geom); +)# +CREATE INDEX lml_posic_geo_localidade_p_geom ON edgv.lml_posic_geo_localidade_p USING gist (geom)# -ALTER TABLE edgv.lml_posic_geo_localidade_p OWNER TO postgres; +ALTER TABLE edgv.lml_posic_geo_localidade_p OWNER TO postgres# ALTER TABLE edgv.lml_posic_geo_localidade_p ADD CONSTRAINT lml_posic_geo_localidade_p_tipolocalidade_fk FOREIGN KEY (tipolocalidade) REFERENCES dominios.tipo_localidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_posic_geo_localidade_p ALTER COLUMN tipolocalidade SET DEFAULT 9999; +ALTER TABLE edgv.lml_posic_geo_localidade_p ALTER COLUMN tipolocalidade SET DEFAULT 9999# CREATE TABLE edgv.lml_distrito_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, geocodigo varchar(15), anodereferencia integer, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT lml_distrito_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_distrito_a_geom ON edgv.lml_distrito_a USING gist (geom); +)# +CREATE INDEX lml_distrito_a_geom ON edgv.lml_distrito_a USING gist (geom)# -ALTER TABLE edgv.lml_distrito_a OWNER TO postgres; +ALTER TABLE edgv.lml_distrito_a OWNER TO postgres# CREATE TABLE edgv.lml_area_densamente_edificada_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT lml_area_densamente_edificada_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_area_densamente_edificada_a_geom ON edgv.lml_area_densamente_edificada_a USING gist (geom); +)# +CREATE INDEX lml_area_densamente_edificada_a_geom ON edgv.lml_area_densamente_edificada_a USING gist (geom)# -ALTER TABLE edgv.lml_area_densamente_edificada_a OWNER TO postgres; +ALTER TABLE edgv.lml_area_densamente_edificada_a OWNER TO postgres# CREATE TABLE edgv.lml_unidade_federacao_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, geocodigo varchar(15), sigla smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT lml_unidade_federacao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_unidade_federacao_a_geom ON edgv.lml_unidade_federacao_a USING gist (geom); +)# +CREATE INDEX lml_unidade_federacao_a_geom ON edgv.lml_unidade_federacao_a USING gist (geom)# -ALTER TABLE edgv.lml_unidade_federacao_a OWNER TO postgres; +ALTER TABLE edgv.lml_unidade_federacao_a OWNER TO postgres# ALTER TABLE edgv.lml_unidade_federacao_a ADD CONSTRAINT lml_unidade_federacao_a_sigla_fk FOREIGN KEY (sigla) REFERENCES dominios.sigla_uf (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_unidade_federacao_a ALTER COLUMN sigla SET DEFAULT 9999; +ALTER TABLE edgv.lml_unidade_federacao_a ALTER COLUMN sigla SET DEFAULT 9999# CREATE TABLE edgv.lml_terra_indigena_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, codidentificadorunico varchar(50), arealegal real, - classificacao varchar(100), + classificacao varchar(255), jurisdicao smallint NOT NULL, administracao smallint NOT NULL, situacaojuridica smallint NOT NULL, datasituacaojuridica varchar(10), - grupoetnico varchar(100), + grupoetnico varchar(255), perimetrooficial real, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT lml_terra_indigena_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_terra_indigena_a_geom ON edgv.lml_terra_indigena_a USING gist (geom); +)# +CREATE INDEX lml_terra_indigena_a_geom ON edgv.lml_terra_indigena_a USING gist (geom)# -ALTER TABLE edgv.lml_terra_indigena_a OWNER TO postgres; +ALTER TABLE edgv.lml_terra_indigena_a OWNER TO postgres# ALTER TABLE edgv.lml_terra_indigena_a ADD CONSTRAINT lml_terra_indigena_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_terra_indigena_a ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.lml_terra_indigena_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.lml_terra_indigena_a ADD CONSTRAINT lml_terra_indigena_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_terra_indigena_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.lml_terra_indigena_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.lml_terra_indigena_a ADD CONSTRAINT lml_terra_indigena_a_situacaojuridica_fk FOREIGN KEY (situacaojuridica) REFERENCES dominios.situacao_juridica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_terra_indigena_a ALTER COLUMN situacaojuridica SET DEFAULT 9999; +ALTER TABLE edgv.lml_terra_indigena_a ALTER COLUMN situacaojuridica SET DEFAULT 9999# CREATE TABLE edgv.lml_unidade_protecao_integral_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, codidentificadorunico varchar(50), @@ -15143,54 +15464,56 @@ CREATE TABLE edgv.lml_unidade_protecao_integral_a( anocriacao varchar(4), historicomodificacoes varchar(255), sigla varchar(255), - atolegal varchar(100), + atolegal varchar(255), areaoficial varchar(15), administracao smallint NOT NULL, - classificacao varchar(100), + classificacao varchar(255), jurisdicao smallint NOT NULL, tipounidprotegida smallint NOT NULL, tipounidprotinteg smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT lml_unidade_protecao_integral_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_unidade_protecao_integral_a_geom ON edgv.lml_unidade_protecao_integral_a USING gist (geom); +)# +CREATE INDEX lml_unidade_protecao_integral_a_geom ON edgv.lml_unidade_protecao_integral_a USING gist (geom)# -ALTER TABLE edgv.lml_unidade_protecao_integral_a OWNER TO postgres; +ALTER TABLE edgv.lml_unidade_protecao_integral_a OWNER TO postgres# ALTER TABLE edgv.lml_unidade_protecao_integral_a ADD CONSTRAINT lml_unidade_protecao_integral_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_unidade_protecao_integral_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.lml_unidade_protecao_integral_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.lml_unidade_protecao_integral_a ADD CONSTRAINT lml_unidade_protecao_integral_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_unidade_protecao_integral_a ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.lml_unidade_protecao_integral_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.lml_unidade_protecao_integral_a ADD CONSTRAINT lml_unidade_protecao_integral_a_tipounidprotegida_fk FOREIGN KEY (tipounidprotegida) REFERENCES dominios.tipo_unid_protegida (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.lml_unidade_protecao_integral_a - ADD CONSTRAINT lml_unidade_protecao_integral_a_tipounidprotegida_check - CHECK (tipounidprotegida = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.lml_unidade_protecao_integral_a ALTER COLUMN tipounidprotegida SET DEFAULT 9999; + ADD CONSTRAINT lml_unidade_protecao_integral_a_tipounidprotegida_check + CHECK (tipounidprotegida = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.lml_unidade_protecao_integral_a ALTER COLUMN tipounidprotegida SET DEFAULT 9999# ALTER TABLE edgv.lml_unidade_protecao_integral_a ADD CONSTRAINT lml_unidade_protecao_integral_a_tipounidprotinteg_fk FOREIGN KEY (tipounidprotinteg) REFERENCES dominios.tipo_unid_prot_integ (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_unidade_protecao_integral_a ALTER COLUMN tipounidprotinteg SET DEFAULT 9999; +ALTER TABLE edgv.lml_unidade_protecao_integral_a ALTER COLUMN tipounidprotinteg SET DEFAULT 9999# CREATE TABLE edgv.lml_unidade_uso_sustentavel_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, codidentificadorunico varchar(50), @@ -15198,168 +15521,177 @@ CREATE TABLE edgv.lml_unidade_uso_sustentavel_a( anocriacao varchar(4), historicomodificacoes varchar(255), sigla varchar(255), - atolegal varchar(100), + atolegal varchar(255), areaoficial varchar(15), administracao smallint NOT NULL, - classificacao varchar(100), + classificacao varchar(255), jurisdicao smallint NOT NULL, tipounidprotegida smallint NOT NULL, tipounidusosust smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT lml_unidade_uso_sustentavel_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_unidade_uso_sustentavel_a_geom ON edgv.lml_unidade_uso_sustentavel_a USING gist (geom); +)# +CREATE INDEX lml_unidade_uso_sustentavel_a_geom ON edgv.lml_unidade_uso_sustentavel_a USING gist (geom)# -ALTER TABLE edgv.lml_unidade_uso_sustentavel_a OWNER TO postgres; +ALTER TABLE edgv.lml_unidade_uso_sustentavel_a OWNER TO postgres# ALTER TABLE edgv.lml_unidade_uso_sustentavel_a ADD CONSTRAINT lml_unidade_uso_sustentavel_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_unidade_uso_sustentavel_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.lml_unidade_uso_sustentavel_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.lml_unidade_uso_sustentavel_a ADD CONSTRAINT lml_unidade_uso_sustentavel_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_unidade_uso_sustentavel_a ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.lml_unidade_uso_sustentavel_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.lml_unidade_uso_sustentavel_a ADD CONSTRAINT lml_unidade_uso_sustentavel_a_tipounidprotegida_fk FOREIGN KEY (tipounidprotegida) REFERENCES dominios.tipo_unid_protegida (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.lml_unidade_uso_sustentavel_a - ADD CONSTRAINT lml_unidade_uso_sustentavel_a_tipounidprotegida_check - CHECK (tipounidprotegida = ANY(ARRAY[3 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.lml_unidade_uso_sustentavel_a ALTER COLUMN tipounidprotegida SET DEFAULT 9999; + ADD CONSTRAINT lml_unidade_uso_sustentavel_a_tipounidprotegida_check + CHECK (tipounidprotegida = ANY(ARRAY[3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.lml_unidade_uso_sustentavel_a ALTER COLUMN tipounidprotegida SET DEFAULT 9999# ALTER TABLE edgv.lml_unidade_uso_sustentavel_a ADD CONSTRAINT lml_unidade_uso_sustentavel_a_tipounidusosust_fk FOREIGN KEY (tipounidusosust) REFERENCES dominios.tipo_unid_uso_sust (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_unidade_uso_sustentavel_a ALTER COLUMN tipounidusosust SET DEFAULT 9999; +ALTER TABLE edgv.lml_unidade_uso_sustentavel_a ALTER COLUMN tipounidusosust SET DEFAULT 9999# CREATE TABLE edgv.lml_municipio_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, geocodigo varchar(15), anodereferencia integer, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT lml_municipio_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_municipio_a_geom ON edgv.lml_municipio_a USING gist (geom); +)# +CREATE INDEX lml_municipio_a_geom ON edgv.lml_municipio_a USING gist (geom)# -ALTER TABLE edgv.lml_municipio_a OWNER TO postgres; +ALTER TABLE edgv.lml_municipio_a OWNER TO postgres# CREATE TABLE edgv.lml_terra_publica_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, codidentificadorunico varchar(50), arealegal real, - classificacao varchar(100), + classificacao varchar(255), jurisdicao smallint NOT NULL, administracao smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT lml_terra_publica_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_terra_publica_a_geom ON edgv.lml_terra_publica_a USING gist (geom); +)# +CREATE INDEX lml_terra_publica_a_geom ON edgv.lml_terra_publica_a USING gist (geom)# -ALTER TABLE edgv.lml_terra_publica_a OWNER TO postgres; +ALTER TABLE edgv.lml_terra_publica_a OWNER TO postgres# ALTER TABLE edgv.lml_terra_publica_a ADD CONSTRAINT lml_terra_publica_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_terra_publica_a ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.lml_terra_publica_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.lml_terra_publica_a ADD CONSTRAINT lml_terra_publica_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_terra_publica_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.lml_terra_publica_a ALTER COLUMN administracao SET DEFAULT 9999# CREATE TABLE edgv.lml_area_pub_militar_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, codidentificadorunico varchar(50), arealegal real, - classificacao varchar(100), + classificacao varchar(255), administracao smallint NOT NULL, jurisdicao smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT lml_area_pub_militar_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_area_pub_militar_a_geom ON edgv.lml_area_pub_militar_a USING gist (geom); +)# +CREATE INDEX lml_area_pub_militar_a_geom ON edgv.lml_area_pub_militar_a USING gist (geom)# -ALTER TABLE edgv.lml_area_pub_militar_a OWNER TO postgres; +ALTER TABLE edgv.lml_area_pub_militar_a OWNER TO postgres# ALTER TABLE edgv.lml_area_pub_militar_a ADD CONSTRAINT lml_area_pub_militar_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.lml_area_pub_militar_a - ADD CONSTRAINT lml_area_pub_militar_a_administracao_check - CHECK (administracao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.lml_area_pub_militar_a ALTER COLUMN administracao SET DEFAULT 9999; + ADD CONSTRAINT lml_area_pub_militar_a_administracao_check + CHECK (administracao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.lml_area_pub_militar_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.lml_area_pub_militar_a ADD CONSTRAINT lml_area_pub_militar_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.lml_area_pub_militar_a - ADD CONSTRAINT lml_area_pub_militar_a_jurisdicao_check - CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.lml_area_pub_militar_a ALTER COLUMN jurisdicao SET DEFAULT 9999; + ADD CONSTRAINT lml_area_pub_militar_a_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.lml_area_pub_militar_a ALTER COLUMN jurisdicao SET DEFAULT 9999# CREATE TABLE edgv.lml_area_urbana_isolada_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoassociado smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT lml_area_urbana_isolada_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_area_urbana_isolada_a_geom ON edgv.lml_area_urbana_isolada_a USING gist (geom); +)# +CREATE INDEX lml_area_urbana_isolada_a_geom ON edgv.lml_area_urbana_isolada_a USING gist (geom)# -ALTER TABLE edgv.lml_area_urbana_isolada_a OWNER TO postgres; +ALTER TABLE edgv.lml_area_urbana_isolada_a OWNER TO postgres# ALTER TABLE edgv.lml_area_urbana_isolada_a ADD CONSTRAINT lml_area_urbana_isolada_a_tipoassociado_fk FOREIGN KEY (tipoassociado) REFERENCES dominios.tipo_associado (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_area_urbana_isolada_a ALTER COLUMN tipoassociado SET DEFAULT 9999; +ALTER TABLE edgv.lml_area_urbana_isolada_a ALTER COLUMN tipoassociado SET DEFAULT 9999# CREATE TABLE edgv.lml_nome_local_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT lml_nome_local_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_nome_local_p_geom ON edgv.lml_nome_local_p USING gist (geom); +)# +CREATE INDEX lml_nome_local_p_geom ON edgv.lml_nome_local_p USING gist (geom)# -ALTER TABLE edgv.lml_nome_local_p OWNER TO postgres; +ALTER TABLE edgv.lml_nome_local_p OWNER TO postgres# CREATE TABLE edgv.lml_unidade_conservacao_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, codidentificadorunico varchar(50), @@ -15367,46 +15699,48 @@ CREATE TABLE edgv.lml_unidade_conservacao_a( anocriacao varchar(4), historicomodificacoes varchar(255), sigla varchar(255), - atolegal varchar(100), + atolegal varchar(255), areaoficial varchar(15), administracao smallint NOT NULL, - classificacao varchar(100), + classificacao varchar(255), jurisdicao smallint NOT NULL, tipounidprotegida smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT lml_unidade_conservacao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_unidade_conservacao_a_geom ON edgv.lml_unidade_conservacao_a USING gist (geom); +)# +CREATE INDEX lml_unidade_conservacao_a_geom ON edgv.lml_unidade_conservacao_a USING gist (geom)# -ALTER TABLE edgv.lml_unidade_conservacao_a OWNER TO postgres; +ALTER TABLE edgv.lml_unidade_conservacao_a OWNER TO postgres# ALTER TABLE edgv.lml_unidade_conservacao_a ADD CONSTRAINT lml_unidade_conservacao_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_unidade_conservacao_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.lml_unidade_conservacao_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.lml_unidade_conservacao_a ADD CONSTRAINT lml_unidade_conservacao_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.lml_unidade_conservacao_a ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.lml_unidade_conservacao_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.lml_unidade_conservacao_a ADD CONSTRAINT lml_unidade_conservacao_a_tipounidprotegida_fk FOREIGN KEY (tipounidprotegida) REFERENCES dominios.tipo_unid_protegida (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.lml_unidade_conservacao_a - ADD CONSTRAINT lml_unidade_conservacao_a_tipounidprotegida_check - CHECK (tipounidprotegida = ANY(ARRAY[4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.lml_unidade_conservacao_a ALTER COLUMN tipounidprotegida SET DEFAULT 9999; + ADD CONSTRAINT lml_unidade_conservacao_a_tipounidprotegida_check + CHECK (tipounidprotegida = ANY(ARRAY[4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.lml_unidade_conservacao_a ALTER COLUMN tipounidprotegida SET DEFAULT 9999# CREATE TABLE edgv.pto_marco_de_limite_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipomarcolim smallint NOT NULL, @@ -15414,42 +15748,43 @@ CREATE TABLE edgv.pto_marco_de_limite_p( longitude varchar(16), altitudeortometrica real, sistemageodesico smallint NOT NULL, - outrarefplan varchar(20), + outrarefplan varchar(255), referencialaltim smallint NOT NULL, - outrarefalt varchar(20), + outrarefalt varchar(255), codigo varchar(9), - orgaoenteresp varchar(15), + orgaoenteresp varchar(255), + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT pto_marco_de_limite_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX pto_marco_de_limite_p_geom ON edgv.pto_marco_de_limite_p USING gist (geom); +)# +CREATE INDEX pto_marco_de_limite_p_geom ON edgv.pto_marco_de_limite_p USING gist (geom)# -ALTER TABLE edgv.pto_marco_de_limite_p OWNER TO postgres; +ALTER TABLE edgv.pto_marco_de_limite_p OWNER TO postgres# ALTER TABLE edgv.pto_marco_de_limite_p ADD CONSTRAINT pto_marco_de_limite_p_tipomarcolim_fk FOREIGN KEY (tipomarcolim) REFERENCES dominios.tipo_hierarquia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_marco_de_limite_p ALTER COLUMN tipomarcolim SET DEFAULT 9999; +ALTER TABLE edgv.pto_marco_de_limite_p ALTER COLUMN tipomarcolim SET DEFAULT 9999# ALTER TABLE edgv.pto_marco_de_limite_p ADD CONSTRAINT pto_marco_de_limite_p_sistemageodesico_fk FOREIGN KEY (sistemageodesico) REFERENCES dominios.sistema_geodesico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_marco_de_limite_p ALTER COLUMN sistemageodesico SET DEFAULT 9999; +ALTER TABLE edgv.pto_marco_de_limite_p ALTER COLUMN sistemageodesico SET DEFAULT 9999# ALTER TABLE edgv.pto_marco_de_limite_p ADD CONSTRAINT pto_marco_de_limite_p_referencialaltim_fk FOREIGN KEY (referencialaltim) REFERENCES dominios.referencial_altim (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_marco_de_limite_p ALTER COLUMN referencialaltim SET DEFAULT 9999; +ALTER TABLE edgv.pto_marco_de_limite_p ALTER COLUMN referencialaltim SET DEFAULT 9999# CREATE TABLE edgv.pto_pto_ref_geod_topo_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, tiporef smallint NOT NULL, latitude varchar(16), @@ -15457,10 +15792,10 @@ CREATE TABLE edgv.pto_pto_ref_geod_topo_p( altitudeortometrica real, altitudegeometrica real, sistemageodesico smallint NOT NULL, - outrarefplan varchar(20), + outrarefplan varchar(255), referencialaltim smallint NOT NULL, - outrarefalt varchar(20), - codponto varchar(12), + outrarefalt varchar(255), + codponto varchar(255), obs varchar(255), nome varchar(255), proximidade smallint NOT NULL, @@ -15471,72 +15806,73 @@ CREATE TABLE edgv.pto_pto_ref_geod_topo_p( datavisita varchar(10), datamedicao varchar(10), valorgravidade real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT pto_pto_ref_geod_topo_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX pto_pto_ref_geod_topo_p_geom ON edgv.pto_pto_ref_geod_topo_p USING gist (geom); +)# +CREATE INDEX pto_pto_ref_geod_topo_p_geom ON edgv.pto_pto_ref_geod_topo_p USING gist (geom)# -ALTER TABLE edgv.pto_pto_ref_geod_topo_p OWNER TO postgres; +ALTER TABLE edgv.pto_pto_ref_geod_topo_p OWNER TO postgres# ALTER TABLE edgv.pto_pto_ref_geod_topo_p ADD CONSTRAINT pto_pto_ref_geod_topo_p_tiporef_fk FOREIGN KEY (tiporef) REFERENCES dominios.tipo_ref (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN tiporef SET DEFAULT 9999; +ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN tiporef SET DEFAULT 9999# ALTER TABLE edgv.pto_pto_ref_geod_topo_p ADD CONSTRAINT pto_pto_ref_geod_topo_p_sistemageodesico_fk FOREIGN KEY (sistemageodesico) REFERENCES dominios.sistema_geodesico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN sistemageodesico SET DEFAULT 9999; +ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN sistemageodesico SET DEFAULT 9999# ALTER TABLE edgv.pto_pto_ref_geod_topo_p ADD CONSTRAINT pto_pto_ref_geod_topo_p_referencialaltim_fk FOREIGN KEY (referencialaltim) REFERENCES dominios.referencial_altim (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN referencialaltim SET DEFAULT 9999; +ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN referencialaltim SET DEFAULT 9999# ALTER TABLE edgv.pto_pto_ref_geod_topo_p ADD CONSTRAINT pto_pto_ref_geod_topo_p_proximidade_fk FOREIGN KEY (proximidade) REFERENCES dominios.proximidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN proximidade SET DEFAULT 9999; +ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN proximidade SET DEFAULT 9999# ALTER TABLE edgv.pto_pto_ref_geod_topo_p ADD CONSTRAINT pto_pto_ref_geod_topo_p_tipoptorefgeodtopo_fk FOREIGN KEY (tipoptorefgeodtopo) REFERENCES dominios.tipo_pto_ref_geod_topo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN tipoptorefgeodtopo SET DEFAULT 9999; +ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN tipoptorefgeodtopo SET DEFAULT 9999# ALTER TABLE edgv.pto_pto_ref_geod_topo_p ADD CONSTRAINT pto_pto_ref_geod_topo_p_redereferencia_fk FOREIGN KEY (redereferencia) REFERENCES dominios.rede_referencia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN redereferencia SET DEFAULT 9999; +ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN redereferencia SET DEFAULT 9999# ALTER TABLE edgv.pto_pto_ref_geod_topo_p ADD CONSTRAINT pto_pto_ref_geod_topo_p_referencialgrav_fk FOREIGN KEY (referencialgrav) REFERENCES dominios.referencial_grav (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN referencialgrav SET DEFAULT 9999; +ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN referencialgrav SET DEFAULT 9999# ALTER TABLE edgv.pto_pto_ref_geod_topo_p ADD CONSTRAINT pto_pto_ref_geod_topo_p_situacaomarco_fk FOREIGN KEY (situacaomarco) REFERENCES dominios.situacao_marco (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN situacaomarco SET DEFAULT 9999; +ALTER TABLE edgv.pto_pto_ref_geod_topo_p ALTER COLUMN situacaomarco SET DEFAULT 9999# CREATE TABLE edgv.pto_pto_geod_topo_controle_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, tiporef smallint NOT NULL, latitude varchar(16), @@ -15544,775 +15880,834 @@ CREATE TABLE edgv.pto_pto_geod_topo_controle_p( altitudeortometrica real, altitudegeometrica real, sistemageodesico smallint NOT NULL, - outrarefplan varchar(20), + outrarefplan varchar(255), referencialaltim smallint NOT NULL, - outrarefalt varchar(20), + outrarefalt varchar(255), codponto varchar(12), obs varchar(255), + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT pto_pto_geod_topo_controle_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX pto_pto_geod_topo_controle_p_geom ON edgv.pto_pto_geod_topo_controle_p USING gist (geom); +)# +CREATE INDEX pto_pto_geod_topo_controle_p_geom ON edgv.pto_pto_geod_topo_controle_p USING gist (geom)# -ALTER TABLE edgv.pto_pto_geod_topo_controle_p OWNER TO postgres; +ALTER TABLE edgv.pto_pto_geod_topo_controle_p OWNER TO postgres# ALTER TABLE edgv.pto_pto_geod_topo_controle_p ADD CONSTRAINT pto_pto_geod_topo_controle_p_tiporef_fk FOREIGN KEY (tiporef) REFERENCES dominios.tipo_ref (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_pto_geod_topo_controle_p ALTER COLUMN tiporef SET DEFAULT 9999; +ALTER TABLE edgv.pto_pto_geod_topo_controle_p ALTER COLUMN tiporef SET DEFAULT 9999# ALTER TABLE edgv.pto_pto_geod_topo_controle_p ADD CONSTRAINT pto_pto_geod_topo_controle_p_sistemageodesico_fk FOREIGN KEY (sistemageodesico) REFERENCES dominios.sistema_geodesico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_pto_geod_topo_controle_p ALTER COLUMN sistemageodesico SET DEFAULT 9999; +ALTER TABLE edgv.pto_pto_geod_topo_controle_p ALTER COLUMN sistemageodesico SET DEFAULT 9999# ALTER TABLE edgv.pto_pto_geod_topo_controle_p ADD CONSTRAINT pto_pto_geod_topo_controle_p_referencialaltim_fk FOREIGN KEY (referencialaltim) REFERENCES dominios.referencial_altim (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_pto_geod_topo_controle_p ALTER COLUMN referencialaltim SET DEFAULT 9999; +ALTER TABLE edgv.pto_pto_geod_topo_controle_p ALTER COLUMN referencialaltim SET DEFAULT 9999# CREATE TABLE edgv.pto_pto_est_med_fenomenos_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoptoestmed smallint NOT NULL, codestacao varchar(50), + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT pto_pto_est_med_fenomenos_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX pto_pto_est_med_fenomenos_p_geom ON edgv.pto_pto_est_med_fenomenos_p USING gist (geom); +)# +CREATE INDEX pto_pto_est_med_fenomenos_p_geom ON edgv.pto_pto_est_med_fenomenos_p USING gist (geom)# -ALTER TABLE edgv.pto_pto_est_med_fenomenos_p OWNER TO postgres; +ALTER TABLE edgv.pto_pto_est_med_fenomenos_p OWNER TO postgres# ALTER TABLE edgv.pto_pto_est_med_fenomenos_p ADD CONSTRAINT pto_pto_est_med_fenomenos_p_tipoptoestmed_fk FOREIGN KEY (tipoptoestmed) REFERENCES dominios.tipo_pto_est_med (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.pto_pto_est_med_fenomenos_p ALTER COLUMN tipoptoestmed SET DEFAULT 9999; +ALTER TABLE edgv.pto_pto_est_med_fenomenos_p ALTER COLUMN tipoptoestmed SET DEFAULT 9999# CREATE TABLE edgv.rel_curva_nivel_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, cota integer, depressao boolean NOT NULL, tipocurvanivel smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT rel_curva_nivel_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_curva_nivel_l_geom ON edgv.rel_curva_nivel_l USING gist (geom); +)# +CREATE INDEX rel_curva_nivel_l_geom ON edgv.rel_curva_nivel_l USING gist (geom)# -ALTER TABLE edgv.rel_curva_nivel_l OWNER TO postgres; +ALTER TABLE edgv.rel_curva_nivel_l OWNER TO postgres# ALTER TABLE edgv.rel_curva_nivel_l ADD CONSTRAINT rel_curva_nivel_l_tipocurvanivel_fk FOREIGN KEY (tipocurvanivel) REFERENCES dominios.tipo_curva_nivel (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rel_curva_nivel_l ALTER COLUMN tipocurvanivel SET DEFAULT 9999; +ALTER TABLE edgv.rel_curva_nivel_l ALTER COLUMN tipocurvanivel SET DEFAULT 9999# CREATE TABLE edgv.rel_gruta_caverna_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT rel_gruta_caverna_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_gruta_caverna_l_geom ON edgv.rel_gruta_caverna_l USING gist (geom); +)# +CREATE INDEX rel_gruta_caverna_l_geom ON edgv.rel_gruta_caverna_l USING gist (geom)# -ALTER TABLE edgv.rel_gruta_caverna_l OWNER TO postgres; +ALTER TABLE edgv.rel_gruta_caverna_l OWNER TO postgres# ALTER TABLE edgv.rel_gruta_caverna_l ADD CONSTRAINT rel_gruta_caverna_l_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_gruta_caverna_l - ADD CONSTRAINT rel_gruta_caverna_l_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[15 :: SMALLINT, 20 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_gruta_caverna_l ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_gruta_caverna_l_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[15 :: SMALLINT, 20 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_gruta_caverna_l ALTER COLUMN tipoelemnat SET DEFAULT 9999# CREATE TABLE edgv.rel_gruta_caverna_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT rel_gruta_caverna_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_gruta_caverna_p_geom ON edgv.rel_gruta_caverna_p USING gist (geom); +)# +CREATE INDEX rel_gruta_caverna_p_geom ON edgv.rel_gruta_caverna_p USING gist (geom)# -ALTER TABLE edgv.rel_gruta_caverna_p OWNER TO postgres; +ALTER TABLE edgv.rel_gruta_caverna_p OWNER TO postgres# ALTER TABLE edgv.rel_gruta_caverna_p ADD CONSTRAINT rel_gruta_caverna_p_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_gruta_caverna_p - ADD CONSTRAINT rel_gruta_caverna_p_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[15 :: SMALLINT, 20 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_gruta_caverna_p ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_gruta_caverna_p_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[15 :: SMALLINT, 20 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_gruta_caverna_p ALTER COLUMN tipoelemnat SET DEFAULT 9999# CREATE TABLE edgv.rel_rocha_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, formarocha smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT rel_rocha_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_rocha_l_geom ON edgv.rel_rocha_l USING gist (geom); +)# +CREATE INDEX rel_rocha_l_geom ON edgv.rel_rocha_l USING gist (geom)# -ALTER TABLE edgv.rel_rocha_l OWNER TO postgres; +ALTER TABLE edgv.rel_rocha_l OWNER TO postgres# ALTER TABLE edgv.rel_rocha_l ADD CONSTRAINT rel_rocha_l_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_rocha_l - ADD CONSTRAINT rel_rocha_l_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[23 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_rocha_l ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_rocha_l_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[23 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_rocha_l ALTER COLUMN tipoelemnat SET DEFAULT 9999# ALTER TABLE edgv.rel_rocha_l ADD CONSTRAINT rel_rocha_l_formarocha_fk FOREIGN KEY (formarocha) REFERENCES dominios.forma_rocha (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rel_rocha_l ALTER COLUMN formarocha SET DEFAULT 9999; +ALTER TABLE edgv.rel_rocha_l ALTER COLUMN formarocha SET DEFAULT 9999# CREATE TABLE edgv.rel_rocha_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, formarocha smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT rel_rocha_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_rocha_p_geom ON edgv.rel_rocha_p USING gist (geom); +)# +CREATE INDEX rel_rocha_p_geom ON edgv.rel_rocha_p USING gist (geom)# -ALTER TABLE edgv.rel_rocha_p OWNER TO postgres; +ALTER TABLE edgv.rel_rocha_p OWNER TO postgres# ALTER TABLE edgv.rel_rocha_p ADD CONSTRAINT rel_rocha_p_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_rocha_p - ADD CONSTRAINT rel_rocha_p_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[23 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_rocha_p ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_rocha_p_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[23 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_rocha_p ALTER COLUMN tipoelemnat SET DEFAULT 9999# ALTER TABLE edgv.rel_rocha_p ADD CONSTRAINT rel_rocha_p_formarocha_fk FOREIGN KEY (formarocha) REFERENCES dominios.forma_rocha (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rel_rocha_p ALTER COLUMN formarocha SET DEFAULT 9999; +ALTER TABLE edgv.rel_rocha_p ALTER COLUMN formarocha SET DEFAULT 9999# CREATE TABLE edgv.rel_rocha_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, formarocha smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT rel_rocha_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_rocha_a_geom ON edgv.rel_rocha_a USING gist (geom); +)# +CREATE INDEX rel_rocha_a_geom ON edgv.rel_rocha_a USING gist (geom)# -ALTER TABLE edgv.rel_rocha_a OWNER TO postgres; +ALTER TABLE edgv.rel_rocha_a OWNER TO postgres# ALTER TABLE edgv.rel_rocha_a ADD CONSTRAINT rel_rocha_a_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_rocha_a - ADD CONSTRAINT rel_rocha_a_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[23 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_rocha_a ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_rocha_a_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[23 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_rocha_a ALTER COLUMN tipoelemnat SET DEFAULT 9999# ALTER TABLE edgv.rel_rocha_a ADD CONSTRAINT rel_rocha_a_formarocha_fk FOREIGN KEY (formarocha) REFERENCES dominios.forma_rocha (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rel_rocha_a ALTER COLUMN formarocha SET DEFAULT 9999; +ALTER TABLE edgv.rel_rocha_a ALTER COLUMN formarocha SET DEFAULT 9999# CREATE TABLE edgv.rel_corte_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, matconstr smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT rel_corte_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_corte_l_geom ON edgv.rel_corte_l USING gist (geom); +)# +CREATE INDEX rel_corte_l_geom ON edgv.rel_corte_l USING gist (geom)# -ALTER TABLE edgv.rel_corte_l OWNER TO postgres; +ALTER TABLE edgv.rel_corte_l OWNER TO postgres# ALTER TABLE edgv.rel_corte_l ADD CONSTRAINT rel_corte_l_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_corte_l - ADD CONSTRAINT rel_corte_l_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[26 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_corte_l ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT rel_corte_l_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[26 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_corte_l ALTER COLUMN tipoalterantrop SET DEFAULT 9999# ALTER TABLE edgv.rel_corte_l ADD CONSTRAINT rel_corte_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_corte_l - ADD CONSTRAINT rel_corte_l_matconstr_check - CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 23 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_corte_l ALTER COLUMN matconstr SET DEFAULT 9999; + ADD CONSTRAINT rel_corte_l_matconstr_check + CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 23 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_corte_l ALTER COLUMN matconstr SET DEFAULT 9999# CREATE TABLE edgv.rel_corte_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, matconstr smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT rel_corte_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_corte_p_geom ON edgv.rel_corte_p USING gist (geom); +)# +CREATE INDEX rel_corte_p_geom ON edgv.rel_corte_p USING gist (geom)# -ALTER TABLE edgv.rel_corte_p OWNER TO postgres; +ALTER TABLE edgv.rel_corte_p OWNER TO postgres# ALTER TABLE edgv.rel_corte_p ADD CONSTRAINT rel_corte_p_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_corte_p - ADD CONSTRAINT rel_corte_p_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[26 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_corte_p ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT rel_corte_p_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[26 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_corte_p ALTER COLUMN tipoalterantrop SET DEFAULT 9999# ALTER TABLE edgv.rel_corte_p ADD CONSTRAINT rel_corte_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_corte_p - ADD CONSTRAINT rel_corte_p_matconstr_check - CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 23 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_corte_p ALTER COLUMN matconstr SET DEFAULT 9999; + ADD CONSTRAINT rel_corte_p_matconstr_check + CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 23 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_corte_p ALTER COLUMN matconstr SET DEFAULT 9999# CREATE TABLE edgv.rel_corte_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, matconstr smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT rel_corte_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_corte_a_geom ON edgv.rel_corte_a USING gist (geom); +)# +CREATE INDEX rel_corte_a_geom ON edgv.rel_corte_a USING gist (geom)# -ALTER TABLE edgv.rel_corte_a OWNER TO postgres; +ALTER TABLE edgv.rel_corte_a OWNER TO postgres# ALTER TABLE edgv.rel_corte_a ADD CONSTRAINT rel_corte_a_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_corte_a - ADD CONSTRAINT rel_corte_a_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[26 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_corte_a ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT rel_corte_a_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[26 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_corte_a ALTER COLUMN tipoalterantrop SET DEFAULT 9999# ALTER TABLE edgv.rel_corte_a ADD CONSTRAINT rel_corte_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_corte_a - ADD CONSTRAINT rel_corte_a_matconstr_check - CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 23 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_corte_a ALTER COLUMN matconstr SET DEFAULT 9999; + ADD CONSTRAINT rel_corte_a_matconstr_check + CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 23 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_corte_a ALTER COLUMN matconstr SET DEFAULT 9999# CREATE TABLE edgv.rel_terreno_exposto_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, tipoterrexp smallint NOT NULL, causaexposicao smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT rel_terreno_exposto_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_terreno_exposto_a_geom ON edgv.rel_terreno_exposto_a USING gist (geom); +)# +CREATE INDEX rel_terreno_exposto_a_geom ON edgv.rel_terreno_exposto_a USING gist (geom)# -ALTER TABLE edgv.rel_terreno_exposto_a OWNER TO postgres; +ALTER TABLE edgv.rel_terreno_exposto_a OWNER TO postgres# ALTER TABLE edgv.rel_terreno_exposto_a ADD CONSTRAINT rel_terreno_exposto_a_tipoterrexp_fk FOREIGN KEY (tipoterrexp) REFERENCES dominios.tipo_terreno_exposto (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rel_terreno_exposto_a ALTER COLUMN tipoterrexp SET DEFAULT 9999; +ALTER TABLE edgv.rel_terreno_exposto_a ALTER COLUMN tipoterrexp SET DEFAULT 9999# ALTER TABLE edgv.rel_terreno_exposto_a ADD CONSTRAINT rel_terreno_exposto_a_causaexposicao_fk FOREIGN KEY (causaexposicao) REFERENCES dominios.causa_exposicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rel_terreno_exposto_a ALTER COLUMN causaexposicao SET DEFAULT 9999; +ALTER TABLE edgv.rel_terreno_exposto_a ALTER COLUMN causaexposicao SET DEFAULT 9999# CREATE TABLE edgv.rel_dolina_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT rel_dolina_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_dolina_p_geom ON edgv.rel_dolina_p USING gist (geom); +)# +CREATE INDEX rel_dolina_p_geom ON edgv.rel_dolina_p USING gist (geom)# -ALTER TABLE edgv.rel_dolina_p OWNER TO postgres; +ALTER TABLE edgv.rel_dolina_p OWNER TO postgres# ALTER TABLE edgv.rel_dolina_p ADD CONSTRAINT rel_dolina_p_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_dolina_p - ADD CONSTRAINT rel_dolina_p_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[16 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_dolina_p ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_dolina_p_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[16 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_dolina_p ALTER COLUMN tipoelemnat SET DEFAULT 9999# CREATE TABLE edgv.rel_dolina_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT rel_dolina_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_dolina_a_geom ON edgv.rel_dolina_a USING gist (geom); +)# +CREATE INDEX rel_dolina_a_geom ON edgv.rel_dolina_a USING gist (geom)# -ALTER TABLE edgv.rel_dolina_a OWNER TO postgres; +ALTER TABLE edgv.rel_dolina_a OWNER TO postgres# ALTER TABLE edgv.rel_dolina_a ADD CONSTRAINT rel_dolina_a_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_dolina_a - ADD CONSTRAINT rel_dolina_a_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[16 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_dolina_a ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_dolina_a_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[16 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_dolina_a ALTER COLUMN tipoelemnat SET DEFAULT 9999# CREATE TABLE edgv.rel_aterro_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, matconstr smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT rel_aterro_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_aterro_l_geom ON edgv.rel_aterro_l USING gist (geom); +)# +CREATE INDEX rel_aterro_l_geom ON edgv.rel_aterro_l USING gist (geom)# -ALTER TABLE edgv.rel_aterro_l OWNER TO postgres; +ALTER TABLE edgv.rel_aterro_l OWNER TO postgres# ALTER TABLE edgv.rel_aterro_l ADD CONSTRAINT rel_aterro_l_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_aterro_l - ADD CONSTRAINT rel_aterro_l_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[27 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_aterro_l ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT rel_aterro_l_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[27 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_aterro_l ALTER COLUMN tipoalterantrop SET DEFAULT 9999# ALTER TABLE edgv.rel_aterro_l ADD CONSTRAINT rel_aterro_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_aterro_l - ADD CONSTRAINT rel_aterro_l_matconstr_check - CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 23 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_aterro_l ALTER COLUMN matconstr SET DEFAULT 9999; + ADD CONSTRAINT rel_aterro_l_matconstr_check + CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 23 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_aterro_l ALTER COLUMN matconstr SET DEFAULT 9999# CREATE TABLE edgv.rel_aterro_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, matconstr smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT rel_aterro_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_aterro_p_geom ON edgv.rel_aterro_p USING gist (geom); +)# +CREATE INDEX rel_aterro_p_geom ON edgv.rel_aterro_p USING gist (geom)# -ALTER TABLE edgv.rel_aterro_p OWNER TO postgres; +ALTER TABLE edgv.rel_aterro_p OWNER TO postgres# ALTER TABLE edgv.rel_aterro_p ADD CONSTRAINT rel_aterro_p_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_aterro_p - ADD CONSTRAINT rel_aterro_p_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[27 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_aterro_p ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT rel_aterro_p_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[27 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_aterro_p ALTER COLUMN tipoalterantrop SET DEFAULT 9999# ALTER TABLE edgv.rel_aterro_p ADD CONSTRAINT rel_aterro_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_aterro_p - ADD CONSTRAINT rel_aterro_p_matconstr_check - CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 23 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_aterro_p ALTER COLUMN matconstr SET DEFAULT 9999; + ADD CONSTRAINT rel_aterro_p_matconstr_check + CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 23 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_aterro_p ALTER COLUMN matconstr SET DEFAULT 9999# CREATE TABLE edgv.rel_aterro_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, matconstr smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT rel_aterro_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_aterro_a_geom ON edgv.rel_aterro_a USING gist (geom); +)# +CREATE INDEX rel_aterro_a_geom ON edgv.rel_aterro_a USING gist (geom)# -ALTER TABLE edgv.rel_aterro_a OWNER TO postgres; +ALTER TABLE edgv.rel_aterro_a OWNER TO postgres# ALTER TABLE edgv.rel_aterro_a ADD CONSTRAINT rel_aterro_a_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_aterro_a - ADD CONSTRAINT rel_aterro_a_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[27 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_aterro_a ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT rel_aterro_a_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[27 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_aterro_a ALTER COLUMN tipoalterantrop SET DEFAULT 9999# ALTER TABLE edgv.rel_aterro_a ADD CONSTRAINT rel_aterro_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_aterro_a - ADD CONSTRAINT rel_aterro_a_matconstr_check - CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 23 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_aterro_a ALTER COLUMN matconstr SET DEFAULT 9999; + ADD CONSTRAINT rel_aterro_a_matconstr_check + CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 23 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_aterro_a ALTER COLUMN matconstr SET DEFAULT 9999# CREATE TABLE edgv.rel_ponto_cotado_altimetrico_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, cotacomprovada boolean NOT NULL, cota real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT rel_ponto_cotado_altimetrico_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_ponto_cotado_altimetrico_p_geom ON edgv.rel_ponto_cotado_altimetrico_p USING gist (geom); +)# +CREATE INDEX rel_ponto_cotado_altimetrico_p_geom ON edgv.rel_ponto_cotado_altimetrico_p USING gist (geom)# -ALTER TABLE edgv.rel_ponto_cotado_altimetrico_p OWNER TO postgres; +ALTER TABLE edgv.rel_ponto_cotado_altimetrico_p OWNER TO postgres# CREATE TABLE edgv.rel_elemento_fisiografico_natural_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT rel_elemento_fisiografico_natural_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_elemento_fisiografico_natural_l_geom ON edgv.rel_elemento_fisiografico_natural_l USING gist (geom); +)# +CREATE INDEX rel_elemento_fisiografico_natural_l_geom ON edgv.rel_elemento_fisiografico_natural_l USING gist (geom)# -ALTER TABLE edgv.rel_elemento_fisiografico_natural_l OWNER TO postgres; +ALTER TABLE edgv.rel_elemento_fisiografico_natural_l OWNER TO postgres# ALTER TABLE edgv.rel_elemento_fisiografico_natural_l ADD CONSTRAINT rel_elemento_fisiografico_natural_l_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_elemento_fisiografico_natural_l - ADD CONSTRAINT rel_elemento_fisiografico_natural_l_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_elemento_fisiografico_natural_l ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_elemento_fisiografico_natural_l_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_elemento_fisiografico_natural_l ALTER COLUMN tipoelemnat SET DEFAULT 9999# CREATE TABLE edgv.rel_elemento_fisiografico_natural_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT rel_elemento_fisiografico_natural_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_elemento_fisiografico_natural_p_geom ON edgv.rel_elemento_fisiografico_natural_p USING gist (geom); +)# +CREATE INDEX rel_elemento_fisiografico_natural_p_geom ON edgv.rel_elemento_fisiografico_natural_p USING gist (geom)# -ALTER TABLE edgv.rel_elemento_fisiografico_natural_p OWNER TO postgres; +ALTER TABLE edgv.rel_elemento_fisiografico_natural_p OWNER TO postgres# ALTER TABLE edgv.rel_elemento_fisiografico_natural_p ADD CONSTRAINT rel_elemento_fisiografico_natural_p_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_elemento_fisiografico_natural_p - ADD CONSTRAINT rel_elemento_fisiografico_natural_p_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_elemento_fisiografico_natural_p ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_elemento_fisiografico_natural_p_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_elemento_fisiografico_natural_p ALTER COLUMN tipoelemnat SET DEFAULT 9999# CREATE TABLE edgv.rel_elemento_fisiografico_natural_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT rel_elemento_fisiografico_natural_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_elemento_fisiografico_natural_a_geom ON edgv.rel_elemento_fisiografico_natural_a USING gist (geom); +)# +CREATE INDEX rel_elemento_fisiografico_natural_a_geom ON edgv.rel_elemento_fisiografico_natural_a USING gist (geom)# -ALTER TABLE edgv.rel_elemento_fisiografico_natural_a OWNER TO postgres; +ALTER TABLE edgv.rel_elemento_fisiografico_natural_a OWNER TO postgres# ALTER TABLE edgv.rel_elemento_fisiografico_natural_a ADD CONSTRAINT rel_elemento_fisiografico_natural_a_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_elemento_fisiografico_natural_a - ADD CONSTRAINT rel_elemento_fisiografico_natural_a_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_elemento_fisiografico_natural_a ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_elemento_fisiografico_natural_a_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_elemento_fisiografico_natural_a ALTER COLUMN tipoelemnat SET DEFAULT 9999# CREATE TABLE edgv.rel_pico_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT rel_pico_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_pico_p_geom ON edgv.rel_pico_p USING gist (geom); +)# +CREATE INDEX rel_pico_p_geom ON edgv.rel_pico_p USING gist (geom)# -ALTER TABLE edgv.rel_pico_p OWNER TO postgres; +ALTER TABLE edgv.rel_pico_p OWNER TO postgres# ALTER TABLE edgv.rel_pico_p ADD CONSTRAINT rel_pico_p_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_pico_p - ADD CONSTRAINT rel_pico_p_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[22 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_pico_p ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_pico_p_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[22 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_pico_p ALTER COLUMN tipoelemnat SET DEFAULT 9999# CREATE TABLE edgv.rel_duna_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, fixa boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT rel_duna_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_duna_l_geom ON edgv.rel_duna_l USING gist (geom); +)# +CREATE INDEX rel_duna_l_geom ON edgv.rel_duna_l USING gist (geom)# -ALTER TABLE edgv.rel_duna_l OWNER TO postgres; +ALTER TABLE edgv.rel_duna_l OWNER TO postgres# ALTER TABLE edgv.rel_duna_l ADD CONSTRAINT rel_duna_l_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_duna_l - ADD CONSTRAINT rel_duna_l_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[17 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_duna_l ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_duna_l_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[17 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_duna_l ALTER COLUMN tipoelemnat SET DEFAULT 9999# CREATE TABLE edgv.rel_duna_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, fixa boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT rel_duna_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_duna_p_geom ON edgv.rel_duna_p USING gist (geom); +)# +CREATE INDEX rel_duna_p_geom ON edgv.rel_duna_p USING gist (geom)# -ALTER TABLE edgv.rel_duna_p OWNER TO postgres; +ALTER TABLE edgv.rel_duna_p OWNER TO postgres# ALTER TABLE edgv.rel_duna_p ADD CONSTRAINT rel_duna_p_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_duna_p - ADD CONSTRAINT rel_duna_p_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[17 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_duna_p ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_duna_p_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[17 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_duna_p ALTER COLUMN tipoelemnat SET DEFAULT 9999# CREATE TABLE edgv.rel_duna_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoelemnat smallint NOT NULL, fixa boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT rel_duna_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_duna_a_geom ON edgv.rel_duna_a USING gist (geom); +)# +CREATE INDEX rel_duna_a_geom ON edgv.rel_duna_a USING gist (geom)# -ALTER TABLE edgv.rel_duna_a OWNER TO postgres; +ALTER TABLE edgv.rel_duna_a OWNER TO postgres# ALTER TABLE edgv.rel_duna_a ADD CONSTRAINT rel_duna_a_tipoelemnat_fk FOREIGN KEY (tipoelemnat) REFERENCES dominios.tipo_elem_nat (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_duna_a - ADD CONSTRAINT rel_duna_a_tipoelemnat_check - CHECK (tipoelemnat = ANY(ARRAY[17 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_duna_a ALTER COLUMN tipoelemnat SET DEFAULT 9999; + ADD CONSTRAINT rel_duna_a_tipoelemnat_check + CHECK (tipoelemnat = ANY(ARRAY[17 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_duna_a ALTER COLUMN tipoelemnat SET DEFAULT 9999# CREATE TABLE edgv.rel_curva_batimetrica_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, profundidade integer, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT rel_curva_batimetrica_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_curva_batimetrica_l_geom ON edgv.rel_curva_batimetrica_l USING gist (geom); +)# +CREATE INDEX rel_curva_batimetrica_l_geom ON edgv.rel_curva_batimetrica_l USING gist (geom)# -ALTER TABLE edgv.rel_curva_batimetrica_l OWNER TO postgres; +ALTER TABLE edgv.rel_curva_batimetrica_l OWNER TO postgres# CREATE TABLE edgv.rel_alteracao_fisiografica_antropica_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT rel_alteracao_fisiografica_antropica_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_alteracao_fisiografica_antropica_l_geom ON edgv.rel_alteracao_fisiografica_antropica_l USING gist (geom); +)# +CREATE INDEX rel_alteracao_fisiografica_antropica_l_geom ON edgv.rel_alteracao_fisiografica_antropica_l USING gist (geom)# -ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_l OWNER TO postgres; +ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_l OWNER TO postgres# ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_l ADD CONSTRAINT rel_alteracao_fisiografica_antropica_l_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_l - ADD CONSTRAINT rel_alteracao_fisiografica_antropica_l_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[0 :: SMALLINT, 24 :: SMALLINT, 28 :: SMALLINT, 29 :: SMALLINT, 32 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_l ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT rel_alteracao_fisiografica_antropica_l_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[0 :: SMALLINT, 24 :: SMALLINT, 28 :: SMALLINT, 29 :: SMALLINT, 32 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_l ALTER COLUMN tipoalterantrop SET DEFAULT 9999# CREATE TABLE edgv.rel_alteracao_fisiografica_antropica_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT rel_alteracao_fisiografica_antropica_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_alteracao_fisiografica_antropica_p_geom ON edgv.rel_alteracao_fisiografica_antropica_p USING gist (geom); +)# +CREATE INDEX rel_alteracao_fisiografica_antropica_p_geom ON edgv.rel_alteracao_fisiografica_antropica_p USING gist (geom)# -ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_p OWNER TO postgres; +ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_p OWNER TO postgres# ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_p ADD CONSTRAINT rel_alteracao_fisiografica_antropica_p_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_p - ADD CONSTRAINT rel_alteracao_fisiografica_antropica_p_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[0 :: SMALLINT, 24 :: SMALLINT, 28 :: SMALLINT, 29 :: SMALLINT, 32 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_p ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT rel_alteracao_fisiografica_antropica_p_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[0 :: SMALLINT, 24 :: SMALLINT, 28 :: SMALLINT, 29 :: SMALLINT, 32 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_p ALTER COLUMN tipoalterantrop SET DEFAULT 9999# CREATE TABLE edgv.rel_alteracao_fisiografica_antropica_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoalterantrop smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT rel_alteracao_fisiografica_antropica_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_alteracao_fisiografica_antropica_a_geom ON edgv.rel_alteracao_fisiografica_antropica_a USING gist (geom); +)# +CREATE INDEX rel_alteracao_fisiografica_antropica_a_geom ON edgv.rel_alteracao_fisiografica_antropica_a USING gist (geom)# -ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_a OWNER TO postgres; +ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_a OWNER TO postgres# ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_a ADD CONSTRAINT rel_alteracao_fisiografica_antropica_a_tipoalterantrop_fk FOREIGN KEY (tipoalterantrop) REFERENCES dominios.tipo_alter_antrop (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_a - ADD CONSTRAINT rel_alteracao_fisiografica_antropica_a_tipoalterantrop_check - CHECK (tipoalterantrop = ANY(ARRAY[0 :: SMALLINT, 24 :: SMALLINT, 28 :: SMALLINT, 29 :: SMALLINT, 32 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_a ALTER COLUMN tipoalterantrop SET DEFAULT 9999; + ADD CONSTRAINT rel_alteracao_fisiografica_antropica_a_tipoalterantrop_check + CHECK (tipoalterantrop = ANY(ARRAY[0 :: SMALLINT, 24 :: SMALLINT, 28 :: SMALLINT, 29 :: SMALLINT, 32 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rel_alteracao_fisiografica_antropica_a ALTER COLUMN tipoalterantrop SET DEFAULT 9999# CREATE TABLE edgv.rel_ponto_cotado_batimetrico_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, profundidade real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT rel_ponto_cotado_batimetrico_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rel_ponto_cotado_batimetrico_p_geom ON edgv.rel_ponto_cotado_batimetrico_p USING gist (geom); +)# +CREATE INDEX rel_ponto_cotado_batimetrico_p_geom ON edgv.rel_ponto_cotado_batimetrico_p USING gist (geom)# -ALTER TABLE edgv.rel_ponto_cotado_batimetrico_p OWNER TO postgres; +ALTER TABLE edgv.rel_ponto_cotado_batimetrico_p OWNER TO postgres# CREATE TABLE edgv.rod_trecho_rodoviario_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, jurisdicao smallint NOT NULL, administracao smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), revestimento smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, @@ -16327,101 +16722,103 @@ CREATE TABLE edgv.rod_trecho_rodoviario_l( limitevelocidade real, trechoemperimetrourbano smallint NOT NULL, acostamento smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT rod_trecho_rodoviario_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rod_trecho_rodoviario_l_geom ON edgv.rod_trecho_rodoviario_l USING gist (geom); +)# +CREATE INDEX rod_trecho_rodoviario_l_geom ON edgv.rod_trecho_rodoviario_l USING gist (geom)# -ALTER TABLE edgv.rod_trecho_rodoviario_l OWNER TO postgres; +ALTER TABLE edgv.rod_trecho_rodoviario_l OWNER TO postgres# ALTER TABLE edgv.rod_trecho_rodoviario_l ADD CONSTRAINT rod_trecho_rodoviario_l_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_l ADD CONSTRAINT rod_trecho_rodoviario_l_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_l ADD CONSTRAINT rod_trecho_rodoviario_l_revestimento_fk FOREIGN KEY (revestimento) REFERENCES dominios.revestimento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN revestimento SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN revestimento SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_l ADD CONSTRAINT rod_trecho_rodoviario_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_l ADD CONSTRAINT rod_trecho_rodoviario_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_l ADD CONSTRAINT rod_trecho_rodoviario_l_canteirodivisorio_fk FOREIGN KEY (canteirodivisorio) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN canteirodivisorio SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN canteirodivisorio SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_l ADD CONSTRAINT rod_trecho_rodoviario_l_trafego_fk FOREIGN KEY (trafego) REFERENCES dominios.trafego (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN trafego SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN trafego SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_l ADD CONSTRAINT rod_trecho_rodoviario_l_tipopavimentacao_fk FOREIGN KEY (tipopavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN tipopavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN tipopavimentacao SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_l ADD CONSTRAINT rod_trecho_rodoviario_l_tipovia_fk FOREIGN KEY (tipovia) REFERENCES dominios.tipo_via (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rod_trecho_rodoviario_l - ADD CONSTRAINT rod_trecho_rodoviario_l_tipovia_check - CHECK (tipovia = ANY(ARRAY[2 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN tipovia SET DEFAULT 9999; + ADD CONSTRAINT rod_trecho_rodoviario_l_tipovia_check + CHECK (tipovia = ANY(ARRAY[2 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN tipovia SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_l ADD CONSTRAINT rod_trecho_rodoviario_l_trechoemperimetrourbano_fk FOREIGN KEY (trechoemperimetrourbano) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN trechoemperimetrourbano SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN trechoemperimetrourbano SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_l ADD CONSTRAINT rod_trecho_rodoviario_l_acostamento_fk FOREIGN KEY (acostamento) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN acostamento SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_l ALTER COLUMN acostamento SET DEFAULT 9999# CREATE TABLE edgv.rod_trecho_rodoviario_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, jurisdicao smallint NOT NULL, administracao smallint NOT NULL, - concessionaria varchar(100), + concessionaria varchar(255), revestimento smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, @@ -16436,96 +16833,98 @@ CREATE TABLE edgv.rod_trecho_rodoviario_a( limitevelocidade real, trechoemperimetrourbano smallint NOT NULL, acostamento smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT rod_trecho_rodoviario_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX rod_trecho_rodoviario_a_geom ON edgv.rod_trecho_rodoviario_a USING gist (geom); +)# +CREATE INDEX rod_trecho_rodoviario_a_geom ON edgv.rod_trecho_rodoviario_a USING gist (geom)# -ALTER TABLE edgv.rod_trecho_rodoviario_a OWNER TO postgres; +ALTER TABLE edgv.rod_trecho_rodoviario_a OWNER TO postgres# ALTER TABLE edgv.rod_trecho_rodoviario_a ADD CONSTRAINT rod_trecho_rodoviario_a_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN jurisdicao SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN jurisdicao SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_a ADD CONSTRAINT rod_trecho_rodoviario_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_a ADD CONSTRAINT rod_trecho_rodoviario_a_revestimento_fk FOREIGN KEY (revestimento) REFERENCES dominios.revestimento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN revestimento SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN revestimento SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_a ADD CONSTRAINT rod_trecho_rodoviario_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_a ADD CONSTRAINT rod_trecho_rodoviario_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_a ADD CONSTRAINT rod_trecho_rodoviario_a_canteirodivisorio_fk FOREIGN KEY (canteirodivisorio) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN canteirodivisorio SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN canteirodivisorio SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_a ADD CONSTRAINT rod_trecho_rodoviario_a_trafego_fk FOREIGN KEY (trafego) REFERENCES dominios.trafego (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN trafego SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN trafego SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_a ADD CONSTRAINT rod_trecho_rodoviario_a_tipopavimentacao_fk FOREIGN KEY (tipopavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN tipopavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN tipopavimentacao SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_a ADD CONSTRAINT rod_trecho_rodoviario_a_tipovia_fk FOREIGN KEY (tipovia) REFERENCES dominios.tipo_via (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.rod_trecho_rodoviario_a - ADD CONSTRAINT rod_trecho_rodoviario_a_tipovia_check - CHECK (tipovia = ANY(ARRAY[2 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN tipovia SET DEFAULT 9999; + ADD CONSTRAINT rod_trecho_rodoviario_a_tipovia_check + CHECK (tipovia = ANY(ARRAY[2 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN tipovia SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_a ADD CONSTRAINT rod_trecho_rodoviario_a_trechoemperimetrourbano_fk FOREIGN KEY (trechoemperimetrourbano) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN trechoemperimetrourbano SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN trechoemperimetrourbano SET DEFAULT 9999# ALTER TABLE edgv.rod_trecho_rodoviario_a ADD CONSTRAINT rod_trecho_rodoviario_a_acostamento_fk FOREIGN KEY (acostamento) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN acostamento SET DEFAULT 9999; +ALTER TABLE edgv.rod_trecho_rodoviario_a ALTER COLUMN acostamento SET DEFAULT 9999# CREATE TABLE edgv.snb_dep_abast_agua_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -16541,109 +16940,113 @@ CREATE TABLE edgv.snb_dep_abast_agua_p( estadofisico smallint NOT NULL, finalidadedep smallint NOT NULL, situacaoagua smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT snb_dep_abast_agua_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX snb_dep_abast_agua_p_geom ON edgv.snb_dep_abast_agua_p USING gist (geom); +)# +CREATE INDEX snb_dep_abast_agua_p_geom ON edgv.snb_dep_abast_agua_p USING gist (geom)# -ALTER TABLE edgv.snb_dep_abast_agua_p OWNER TO postgres; +ALTER TABLE edgv.snb_dep_abast_agua_p OWNER TO postgres# ALTER TABLE edgv.snb_dep_abast_agua_p ADD CONSTRAINT snb_dep_abast_agua_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_p ADD CONSTRAINT snb_dep_abast_agua_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_p ADD CONSTRAINT snb_dep_abast_agua_p_tipodepgeral_fk FOREIGN KEY (tipodepgeral) REFERENCES dominios.tipo_dep_geral (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.snb_dep_abast_agua_p - ADD CONSTRAINT snb_dep_abast_agua_p_tipodepgeral_check - CHECK (tipodepgeral = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 19 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN tipodepgeral SET DEFAULT 9999; + ADD CONSTRAINT snb_dep_abast_agua_p_tipodepgeral_check + CHECK (tipodepgeral = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 19 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN tipodepgeral SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_p ADD CONSTRAINT snb_dep_abast_agua_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_p ADD CONSTRAINT snb_dep_abast_agua_p_tipoexposicao_fk FOREIGN KEY (tipoexposicao) REFERENCES dominios.tipo_exposicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN tipoexposicao SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN tipoexposicao SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_p ADD CONSTRAINT snb_dep_abast_agua_p_tipoprodutoresiduo_fk FOREIGN KEY (tipoprodutoresiduo) REFERENCES dominios.tipo_produto_residuo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.snb_dep_abast_agua_p - ADD CONSTRAINT snb_dep_abast_agua_p_tipoprodutoresiduo_check - CHECK (tipoprodutoresiduo = ANY(ARRAY[46 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN tipoprodutoresiduo SET DEFAULT 9999; + ADD CONSTRAINT snb_dep_abast_agua_p_tipoprodutoresiduo_check + CHECK (tipoprodutoresiduo = ANY(ARRAY[46 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN tipoprodutoresiduo SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_p ADD CONSTRAINT snb_dep_abast_agua_p_tipoconteudo_fk FOREIGN KEY (tipoconteudo) REFERENCES dominios.tipo_conteudo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN tipoconteudo SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN tipoconteudo SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_p ADD CONSTRAINT snb_dep_abast_agua_p_unidadevolume_fk FOREIGN KEY (unidadevolume) REFERENCES dominios.unidade_volume (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN unidadevolume SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN unidadevolume SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_p ADD CONSTRAINT snb_dep_abast_agua_p_tratamento_fk FOREIGN KEY (tratamento) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN tratamento SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN tratamento SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_p ADD CONSTRAINT snb_dep_abast_agua_p_estadofisico_fk FOREIGN KEY (estadofisico) REFERENCES dominios.estado_fisico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.snb_dep_abast_agua_p - ADD CONSTRAINT snb_dep_abast_agua_p_estadofisico_check - CHECK (estadofisico = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN estadofisico SET DEFAULT 9999; + ADD CONSTRAINT snb_dep_abast_agua_p_estadofisico_check + CHECK (estadofisico = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN estadofisico SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_p ADD CONSTRAINT snb_dep_abast_agua_p_finalidadedep_fk FOREIGN KEY (finalidadedep) REFERENCES dominios.finalidade_deposito (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN finalidadedep SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN finalidadedep SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_p ADD CONSTRAINT snb_dep_abast_agua_p_situacaoagua_fk FOREIGN KEY (situacaoagua) REFERENCES dominios.situacao_agua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN situacaoagua SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_p ALTER COLUMN situacaoagua SET DEFAULT 9999# CREATE TABLE edgv.snb_dep_abast_agua_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -16659,190 +17062,198 @@ CREATE TABLE edgv.snb_dep_abast_agua_a( estadofisico smallint NOT NULL, finalidadedep smallint NOT NULL, situacaoagua smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT snb_dep_abast_agua_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX snb_dep_abast_agua_a_geom ON edgv.snb_dep_abast_agua_a USING gist (geom); +)# +CREATE INDEX snb_dep_abast_agua_a_geom ON edgv.snb_dep_abast_agua_a USING gist (geom)# -ALTER TABLE edgv.snb_dep_abast_agua_a OWNER TO postgres; +ALTER TABLE edgv.snb_dep_abast_agua_a OWNER TO postgres# ALTER TABLE edgv.snb_dep_abast_agua_a ADD CONSTRAINT snb_dep_abast_agua_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_a ADD CONSTRAINT snb_dep_abast_agua_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_a ADD CONSTRAINT snb_dep_abast_agua_a_tipodepgeral_fk FOREIGN KEY (tipodepgeral) REFERENCES dominios.tipo_dep_geral (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.snb_dep_abast_agua_a - ADD CONSTRAINT snb_dep_abast_agua_a_tipodepgeral_check - CHECK (tipodepgeral = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 19 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN tipodepgeral SET DEFAULT 9999; + ADD CONSTRAINT snb_dep_abast_agua_a_tipodepgeral_check + CHECK (tipodepgeral = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 19 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN tipodepgeral SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_a ADD CONSTRAINT snb_dep_abast_agua_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_a ADD CONSTRAINT snb_dep_abast_agua_a_tipoexposicao_fk FOREIGN KEY (tipoexposicao) REFERENCES dominios.tipo_exposicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN tipoexposicao SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN tipoexposicao SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_a ADD CONSTRAINT snb_dep_abast_agua_a_tipoprodutoresiduo_fk FOREIGN KEY (tipoprodutoresiduo) REFERENCES dominios.tipo_produto_residuo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.snb_dep_abast_agua_a - ADD CONSTRAINT snb_dep_abast_agua_a_tipoprodutoresiduo_check - CHECK (tipoprodutoresiduo = ANY(ARRAY[46 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN tipoprodutoresiduo SET DEFAULT 9999; + ADD CONSTRAINT snb_dep_abast_agua_a_tipoprodutoresiduo_check + CHECK (tipoprodutoresiduo = ANY(ARRAY[46 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN tipoprodutoresiduo SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_a ADD CONSTRAINT snb_dep_abast_agua_a_tipoconteudo_fk FOREIGN KEY (tipoconteudo) REFERENCES dominios.tipo_conteudo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN tipoconteudo SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN tipoconteudo SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_a ADD CONSTRAINT snb_dep_abast_agua_a_unidadevolume_fk FOREIGN KEY (unidadevolume) REFERENCES dominios.unidade_volume (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN unidadevolume SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN unidadevolume SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_a ADD CONSTRAINT snb_dep_abast_agua_a_tratamento_fk FOREIGN KEY (tratamento) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN tratamento SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN tratamento SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_a ADD CONSTRAINT snb_dep_abast_agua_a_estadofisico_fk FOREIGN KEY (estadofisico) REFERENCES dominios.estado_fisico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.snb_dep_abast_agua_a - ADD CONSTRAINT snb_dep_abast_agua_a_estadofisico_check - CHECK (estadofisico = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN estadofisico SET DEFAULT 9999; + ADD CONSTRAINT snb_dep_abast_agua_a_estadofisico_check + CHECK (estadofisico = ANY(ARRAY[1 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN estadofisico SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_a ADD CONSTRAINT snb_dep_abast_agua_a_finalidadedep_fk FOREIGN KEY (finalidadedep) REFERENCES dominios.finalidade_deposito (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN finalidadedep SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN finalidadedep SET DEFAULT 9999# ALTER TABLE edgv.snb_dep_abast_agua_a ADD CONSTRAINT snb_dep_abast_agua_a_situacaoagua_fk FOREIGN KEY (situacaoagua) REFERENCES dominios.situacao_agua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN situacaoagua SET DEFAULT 9999; +ALTER TABLE edgv.snb_dep_abast_agua_a ALTER COLUMN situacaoagua SET DEFAULT 9999# CREATE TABLE edgv.snb_barragem_calcadao_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoequipdesenvsocial smallint NOT NULL, - sigla varchar(80), - codequipdesenvsocial varchar(80), + sigla varchar(255), + codequipdesenvsocial varchar(255), localizacaoequipdesenvsocial smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT snb_barragem_calcadao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX snb_barragem_calcadao_a_geom ON edgv.snb_barragem_calcadao_a USING gist (geom); +)# +CREATE INDEX snb_barragem_calcadao_a_geom ON edgv.snb_barragem_calcadao_a USING gist (geom)# -ALTER TABLE edgv.snb_barragem_calcadao_a OWNER TO postgres; +ALTER TABLE edgv.snb_barragem_calcadao_a OWNER TO postgres# ALTER TABLE edgv.snb_barragem_calcadao_a ADD CONSTRAINT snb_barragem_calcadao_a_tipoequipdesenvsocial_fk FOREIGN KEY (tipoequipdesenvsocial) REFERENCES dominios.tipo_equip_desenv_social (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.snb_barragem_calcadao_a - ADD CONSTRAINT snb_barragem_calcadao_a_tipoequipdesenvsocial_check - CHECK (tipoequipdesenvsocial = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.snb_barragem_calcadao_a ALTER COLUMN tipoequipdesenvsocial SET DEFAULT 9999; + ADD CONSTRAINT snb_barragem_calcadao_a_tipoequipdesenvsocial_check + CHECK (tipoequipdesenvsocial = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.snb_barragem_calcadao_a ALTER COLUMN tipoequipdesenvsocial SET DEFAULT 9999# ALTER TABLE edgv.snb_barragem_calcadao_a ADD CONSTRAINT snb_barragem_calcadao_a_localizacaoequipdesenvsocial_fk FOREIGN KEY (localizacaoequipdesenvsocial) REFERENCES dominios.local_equip_desenv_social (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.snb_barragem_calcadao_a ALTER COLUMN localizacaoequipdesenvsocial SET DEFAULT 9999; +ALTER TABLE edgv.snb_barragem_calcadao_a ALTER COLUMN localizacaoequipdesenvsocial SET DEFAULT 9999# CREATE TABLE edgv.tra_entroncamento_pto_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipoentroncamento smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT tra_entroncamento_pto_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_entroncamento_pto_p_geom ON edgv.tra_entroncamento_pto_p USING gist (geom); +)# +CREATE INDEX tra_entroncamento_pto_p_geom ON edgv.tra_entroncamento_pto_p USING gist (geom)# -ALTER TABLE edgv.tra_entroncamento_pto_p OWNER TO postgres; +ALTER TABLE edgv.tra_entroncamento_pto_p OWNER TO postgres# ALTER TABLE edgv.tra_entroncamento_pto_p ADD CONSTRAINT tra_entroncamento_pto_p_tipoentroncamento_fk FOREIGN KEY (tipoentroncamento) REFERENCES dominios.tipo_entroncamento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_entroncamento_pto_p ALTER COLUMN tipoentroncamento SET DEFAULT 9999; +ALTER TABLE edgv.tra_entroncamento_pto_p ALTER COLUMN tipoentroncamento SET DEFAULT 9999# CREATE TABLE edgv.tra_funicular_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT tra_funicular_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_funicular_l_geom ON edgv.tra_funicular_l USING gist (geom); +)# +CREATE INDEX tra_funicular_l_geom ON edgv.tra_funicular_l USING gist (geom)# -ALTER TABLE edgv.tra_funicular_l OWNER TO postgres; +ALTER TABLE edgv.tra_funicular_l OWNER TO postgres# ALTER TABLE edgv.tra_funicular_l ADD CONSTRAINT tra_funicular_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_funicular_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_funicular_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_funicular_l ADD CONSTRAINT tra_funicular_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_funicular_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_funicular_l ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.tra_ponte_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, modaluso smallint NOT NULL, @@ -16860,78 +17271,81 @@ CREATE TABLE edgv.tra_ponte_l( vaolivrehoriz real, vaovertical real, cargasuportmaxima real, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT tra_ponte_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_ponte_l_geom ON edgv.tra_ponte_l USING gist (geom); +)# +CREATE INDEX tra_ponte_l_geom ON edgv.tra_ponte_l USING gist (geom)# -ALTER TABLE edgv.tra_ponte_l OWNER TO postgres; +ALTER TABLE edgv.tra_ponte_l OWNER TO postgres# ALTER TABLE edgv.tra_ponte_l ADD CONSTRAINT tra_ponte_l_modaluso_fk FOREIGN KEY (modaluso) REFERENCES dominios.modal_uso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_ponte_l - ADD CONSTRAINT tra_ponte_l_modaluso_check - CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_ponte_l ALTER COLUMN modaluso SET DEFAULT 9999; + ADD CONSTRAINT tra_ponte_l_modaluso_check + CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_ponte_l ALTER COLUMN modaluso SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_l ADD CONSTRAINT tra_ponte_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_ponte_l - ADD CONSTRAINT tra_ponte_l_matconstr_check - CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 8 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_ponte_l ALTER COLUMN matconstr SET DEFAULT 9999; + ADD CONSTRAINT tra_ponte_l_matconstr_check + CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 8 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_ponte_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_l ADD CONSTRAINT tra_ponte_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_l ADD CONSTRAINT tra_ponte_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_l ADD CONSTRAINT tra_ponte_l_necessitamanutencao_fk FOREIGN KEY (necessitamanutencao) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_l ALTER COLUMN necessitamanutencao SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_l ALTER COLUMN necessitamanutencao SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_l ADD CONSTRAINT tra_ponte_l_posicaopista_fk FOREIGN KEY (posicaopista) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_l ALTER COLUMN posicaopista SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_l ALTER COLUMN posicaopista SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_l ADD CONSTRAINT tra_ponte_l_tipopavimentacao_fk FOREIGN KEY (tipopavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_l ALTER COLUMN tipopavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_l ALTER COLUMN tipopavimentacao SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_l ADD CONSTRAINT tra_ponte_l_tipoponte_fk FOREIGN KEY (tipoponte) REFERENCES dominios.tipo_ponte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_l ALTER COLUMN tipoponte SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_l ALTER COLUMN tipoponte SET DEFAULT 9999# CREATE TABLE edgv.tra_ponte_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, modaluso smallint NOT NULL, @@ -16949,78 +17363,81 @@ CREATE TABLE edgv.tra_ponte_p( vaolivrehoriz real, vaovertical real, cargasuportmaxima real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT tra_ponte_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_ponte_p_geom ON edgv.tra_ponte_p USING gist (geom); +)# +CREATE INDEX tra_ponte_p_geom ON edgv.tra_ponte_p USING gist (geom)# -ALTER TABLE edgv.tra_ponte_p OWNER TO postgres; +ALTER TABLE edgv.tra_ponte_p OWNER TO postgres# ALTER TABLE edgv.tra_ponte_p ADD CONSTRAINT tra_ponte_p_modaluso_fk FOREIGN KEY (modaluso) REFERENCES dominios.modal_uso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_ponte_p - ADD CONSTRAINT tra_ponte_p_modaluso_check - CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_ponte_p ALTER COLUMN modaluso SET DEFAULT 9999; + ADD CONSTRAINT tra_ponte_p_modaluso_check + CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_ponte_p ALTER COLUMN modaluso SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_p ADD CONSTRAINT tra_ponte_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_ponte_p - ADD CONSTRAINT tra_ponte_p_matconstr_check - CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 8 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_ponte_p ALTER COLUMN matconstr SET DEFAULT 9999; + ADD CONSTRAINT tra_ponte_p_matconstr_check + CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 8 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_ponte_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_p ADD CONSTRAINT tra_ponte_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_p ADD CONSTRAINT tra_ponte_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_p ADD CONSTRAINT tra_ponte_p_necessitamanutencao_fk FOREIGN KEY (necessitamanutencao) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_p ALTER COLUMN necessitamanutencao SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_p ALTER COLUMN necessitamanutencao SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_p ADD CONSTRAINT tra_ponte_p_posicaopista_fk FOREIGN KEY (posicaopista) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_p ALTER COLUMN posicaopista SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_p ALTER COLUMN posicaopista SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_p ADD CONSTRAINT tra_ponte_p_tipopavimentacao_fk FOREIGN KEY (tipopavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_p ALTER COLUMN tipopavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_p ALTER COLUMN tipopavimentacao SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_p ADD CONSTRAINT tra_ponte_p_tipoponte_fk FOREIGN KEY (tipoponte) REFERENCES dominios.tipo_ponte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_p ALTER COLUMN tipoponte SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_p ALTER COLUMN tipoponte SET DEFAULT 9999# CREATE TABLE edgv.tra_ponte_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, modaluso smallint NOT NULL, @@ -17038,146 +17455,152 @@ CREATE TABLE edgv.tra_ponte_a( vaolivrehoriz real, vaovertical real, cargasuportmaxima real, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT tra_ponte_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_ponte_a_geom ON edgv.tra_ponte_a USING gist (geom); +)# +CREATE INDEX tra_ponte_a_geom ON edgv.tra_ponte_a USING gist (geom)# -ALTER TABLE edgv.tra_ponte_a OWNER TO postgres; +ALTER TABLE edgv.tra_ponte_a OWNER TO postgres# ALTER TABLE edgv.tra_ponte_a ADD CONSTRAINT tra_ponte_a_modaluso_fk FOREIGN KEY (modaluso) REFERENCES dominios.modal_uso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_ponte_a - ADD CONSTRAINT tra_ponte_a_modaluso_check - CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_ponte_a ALTER COLUMN modaluso SET DEFAULT 9999; + ADD CONSTRAINT tra_ponte_a_modaluso_check + CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_ponte_a ALTER COLUMN modaluso SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_a ADD CONSTRAINT tra_ponte_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_ponte_a - ADD CONSTRAINT tra_ponte_a_matconstr_check - CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 8 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_ponte_a ALTER COLUMN matconstr SET DEFAULT 9999; + ADD CONSTRAINT tra_ponte_a_matconstr_check + CHECK (matconstr = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 8 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_ponte_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_a ADD CONSTRAINT tra_ponte_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_a ADD CONSTRAINT tra_ponte_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_a ADD CONSTRAINT tra_ponte_a_necessitamanutencao_fk FOREIGN KEY (necessitamanutencao) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_a ALTER COLUMN necessitamanutencao SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_a ALTER COLUMN necessitamanutencao SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_a ADD CONSTRAINT tra_ponte_a_posicaopista_fk FOREIGN KEY (posicaopista) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_a ALTER COLUMN posicaopista SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_a ALTER COLUMN posicaopista SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_a ADD CONSTRAINT tra_ponte_a_tipopavimentacao_fk FOREIGN KEY (tipopavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_a ALTER COLUMN tipopavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_a ALTER COLUMN tipopavimentacao SET DEFAULT 9999# ALTER TABLE edgv.tra_ponte_a ADD CONSTRAINT tra_ponte_a_tipoponte_fk FOREIGN KEY (tipoponte) REFERENCES dominios.tipo_ponte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_ponte_a ALTER COLUMN tipoponte SET DEFAULT 9999; +ALTER TABLE edgv.tra_ponte_a ALTER COLUMN tipoponte SET DEFAULT 9999# CREATE TABLE edgv.tra_caminho_aereo_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipocaminhoaereo smallint NOT NULL, tipousocaminhoaer smallint NOT NULL, operacional smallint NOT NULL, situacaofisica smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT tra_caminho_aereo_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_caminho_aereo_l_geom ON edgv.tra_caminho_aereo_l USING gist (geom); +)# +CREATE INDEX tra_caminho_aereo_l_geom ON edgv.tra_caminho_aereo_l USING gist (geom)# -ALTER TABLE edgv.tra_caminho_aereo_l OWNER TO postgres; +ALTER TABLE edgv.tra_caminho_aereo_l OWNER TO postgres# ALTER TABLE edgv.tra_caminho_aereo_l ADD CONSTRAINT tra_caminho_aereo_l_tipocaminhoaereo_fk FOREIGN KEY (tipocaminhoaereo) REFERENCES dominios.tipo_caminho_aereo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_caminho_aereo_l ALTER COLUMN tipocaminhoaereo SET DEFAULT 9999; +ALTER TABLE edgv.tra_caminho_aereo_l ALTER COLUMN tipocaminhoaereo SET DEFAULT 9999# ALTER TABLE edgv.tra_caminho_aereo_l ADD CONSTRAINT tra_caminho_aereo_l_tipousocaminhoaer_fk FOREIGN KEY (tipousocaminhoaer) REFERENCES dominios.tipo_transporte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_caminho_aereo_l ALTER COLUMN tipousocaminhoaer SET DEFAULT 9999; +ALTER TABLE edgv.tra_caminho_aereo_l ALTER COLUMN tipousocaminhoaer SET DEFAULT 9999# ALTER TABLE edgv.tra_caminho_aereo_l ADD CONSTRAINT tra_caminho_aereo_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_caminho_aereo_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_caminho_aereo_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_caminho_aereo_l ADD CONSTRAINT tra_caminho_aereo_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_caminho_aereo_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_caminho_aereo_l ALTER COLUMN situacaofisica SET DEFAULT 9999# CREATE TABLE edgv.tra_trilha_picada_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT tra_trilha_picada_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_trilha_picada_l_geom ON edgv.tra_trilha_picada_l USING gist (geom); +)# +CREATE INDEX tra_trilha_picada_l_geom ON edgv.tra_trilha_picada_l USING gist (geom)# -ALTER TABLE edgv.tra_trilha_picada_l OWNER TO postgres; +ALTER TABLE edgv.tra_trilha_picada_l OWNER TO postgres# CREATE TABLE edgv.tra_passagem_nivel_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT tra_passagem_nivel_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_passagem_nivel_p_geom ON edgv.tra_passagem_nivel_p USING gist (geom); +)# +CREATE INDEX tra_passagem_nivel_p_geom ON edgv.tra_passagem_nivel_p USING gist (geom)# -ALTER TABLE edgv.tra_passagem_nivel_p OWNER TO postgres; +ALTER TABLE edgv.tra_passagem_nivel_p OWNER TO postgres# CREATE TABLE edgv.tra_travessia_pedestre_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -17187,51 +17610,52 @@ CREATE TABLE edgv.tra_travessia_pedestre_l( tipotravessiaped smallint NOT NULL, extensao real, largura real, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT tra_travessia_pedestre_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_travessia_pedestre_l_geom ON edgv.tra_travessia_pedestre_l USING gist (geom); +)# +CREATE INDEX tra_travessia_pedestre_l_geom ON edgv.tra_travessia_pedestre_l USING gist (geom)# -ALTER TABLE edgv.tra_travessia_pedestre_l OWNER TO postgres; +ALTER TABLE edgv.tra_travessia_pedestre_l OWNER TO postgres# ALTER TABLE edgv.tra_travessia_pedestre_l ADD CONSTRAINT tra_travessia_pedestre_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_pedestre_l ADD CONSTRAINT tra_travessia_pedestre_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_pedestre_l ADD CONSTRAINT tra_travessia_pedestre_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_pedestre_l ADD CONSTRAINT tra_travessia_pedestre_l_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_l ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_l ALTER COLUMN situacaoespacial SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_pedestre_l ADD CONSTRAINT tra_travessia_pedestre_l_tipotravessiaped_fk FOREIGN KEY (tipotravessiaped) REFERENCES dominios.tipo_travessia_ped (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_l ALTER COLUMN tipotravessiaped SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_l ALTER COLUMN tipotravessiaped SET DEFAULT 9999# CREATE TABLE edgv.tra_travessia_pedestre_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -17241,51 +17665,52 @@ CREATE TABLE edgv.tra_travessia_pedestre_p( tipotravessiaped smallint NOT NULL, extensao real, largura real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT tra_travessia_pedestre_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_travessia_pedestre_p_geom ON edgv.tra_travessia_pedestre_p USING gist (geom); +)# +CREATE INDEX tra_travessia_pedestre_p_geom ON edgv.tra_travessia_pedestre_p USING gist (geom)# -ALTER TABLE edgv.tra_travessia_pedestre_p OWNER TO postgres; +ALTER TABLE edgv.tra_travessia_pedestre_p OWNER TO postgres# ALTER TABLE edgv.tra_travessia_pedestre_p ADD CONSTRAINT tra_travessia_pedestre_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_pedestre_p ADD CONSTRAINT tra_travessia_pedestre_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_pedestre_p ADD CONSTRAINT tra_travessia_pedestre_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_pedestre_p ADD CONSTRAINT tra_travessia_pedestre_p_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_p ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_p ALTER COLUMN situacaoespacial SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_pedestre_p ADD CONSTRAINT tra_travessia_pedestre_p_tipotravessiaped_fk FOREIGN KEY (tipotravessiaped) REFERENCES dominios.tipo_travessia_ped (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_p ALTER COLUMN tipotravessiaped SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_p ALTER COLUMN tipotravessiaped SET DEFAULT 9999# CREATE TABLE edgv.tra_travessia_pedestre_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, operacional smallint NOT NULL, @@ -17295,135 +17720,139 @@ CREATE TABLE edgv.tra_travessia_pedestre_a( tipotravessiaped smallint NOT NULL, extensao real, largura real, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT tra_travessia_pedestre_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_travessia_pedestre_a_geom ON edgv.tra_travessia_pedestre_a USING gist (geom); +)# +CREATE INDEX tra_travessia_pedestre_a_geom ON edgv.tra_travessia_pedestre_a USING gist (geom)# -ALTER TABLE edgv.tra_travessia_pedestre_a OWNER TO postgres; +ALTER TABLE edgv.tra_travessia_pedestre_a OWNER TO postgres# ALTER TABLE edgv.tra_travessia_pedestre_a ADD CONSTRAINT tra_travessia_pedestre_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_pedestre_a ADD CONSTRAINT tra_travessia_pedestre_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_pedestre_a ADD CONSTRAINT tra_travessia_pedestre_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_pedestre_a ADD CONSTRAINT tra_travessia_pedestre_a_situacaoespacial_fk FOREIGN KEY (situacaoespacial) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_a ALTER COLUMN situacaoespacial SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_a ALTER COLUMN situacaoespacial SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_pedestre_a ADD CONSTRAINT tra_travessia_pedestre_a_tipotravessiaped_fk FOREIGN KEY (tipotravessiaped) REFERENCES dominios.tipo_travessia_ped (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_pedestre_a ALTER COLUMN tipotravessiaped SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_pedestre_a ALTER COLUMN tipotravessiaped SET DEFAULT 9999# CREATE TABLE edgv.tra_travessia_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipotravessia smallint NOT NULL, tipouso smallint NOT NULL, tipoembarcacao smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT tra_travessia_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_travessia_l_geom ON edgv.tra_travessia_l USING gist (geom); +)# +CREATE INDEX tra_travessia_l_geom ON edgv.tra_travessia_l USING gist (geom)# -ALTER TABLE edgv.tra_travessia_l OWNER TO postgres; +ALTER TABLE edgv.tra_travessia_l OWNER TO postgres# ALTER TABLE edgv.tra_travessia_l ADD CONSTRAINT tra_travessia_l_tipotravessia_fk FOREIGN KEY (tipotravessia) REFERENCES dominios.tipo_travessia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_l ALTER COLUMN tipotravessia SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_l ALTER COLUMN tipotravessia SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_l ADD CONSTRAINT tra_travessia_l_tipouso_fk FOREIGN KEY (tipouso) REFERENCES dominios.tipo_transporte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_l ALTER COLUMN tipouso SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_l ALTER COLUMN tipouso SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_l ADD CONSTRAINT tra_travessia_l_tipoembarcacao_fk FOREIGN KEY (tipoembarcacao) REFERENCES dominios.tipo_embarcacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_l ALTER COLUMN tipoembarcacao SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_l ALTER COLUMN tipoembarcacao SET DEFAULT 9999# CREATE TABLE edgv.tra_travessia_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, tipotravessia smallint NOT NULL, tipouso smallint NOT NULL, tipoembarcacao smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT tra_travessia_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_travessia_p_geom ON edgv.tra_travessia_p USING gist (geom); +)# +CREATE INDEX tra_travessia_p_geom ON edgv.tra_travessia_p USING gist (geom)# -ALTER TABLE edgv.tra_travessia_p OWNER TO postgres; +ALTER TABLE edgv.tra_travessia_p OWNER TO postgres# ALTER TABLE edgv.tra_travessia_p ADD CONSTRAINT tra_travessia_p_tipotravessia_fk FOREIGN KEY (tipotravessia) REFERENCES dominios.tipo_travessia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_p ALTER COLUMN tipotravessia SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_p ALTER COLUMN tipotravessia SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_p ADD CONSTRAINT tra_travessia_p_tipouso_fk FOREIGN KEY (tipouso) REFERENCES dominios.tipo_transporte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_p ALTER COLUMN tipouso SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_p ALTER COLUMN tipouso SET DEFAULT 9999# ALTER TABLE edgv.tra_travessia_p ADD CONSTRAINT tra_travessia_p_tipoembarcacao_fk FOREIGN KEY (tipoembarcacao) REFERENCES dominios.tipo_embarcacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_travessia_p ALTER COLUMN tipoembarcacao SET DEFAULT 9999; +ALTER TABLE edgv.tra_travessia_p ALTER COLUMN tipoembarcacao SET DEFAULT 9999# CREATE TABLE edgv.tra_caminho_carrocavel_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT tra_caminho_carrocavel_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_caminho_carrocavel_l_geom ON edgv.tra_caminho_carrocavel_l USING gist (geom); +)# +CREATE INDEX tra_caminho_carrocavel_l_geom ON edgv.tra_caminho_carrocavel_l USING gist (geom)# -ALTER TABLE edgv.tra_caminho_carrocavel_l OWNER TO postgres; +ALTER TABLE edgv.tra_caminho_carrocavel_l OWNER TO postgres# CREATE TABLE edgv.tra_tunel_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, modaluso smallint NOT NULL, @@ -17439,78 +17868,81 @@ CREATE TABLE edgv.tra_tunel_l( tipopavimentacao smallint NOT NULL, altura real, tipotunel smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT tra_tunel_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_tunel_l_geom ON edgv.tra_tunel_l USING gist (geom); +)# +CREATE INDEX tra_tunel_l_geom ON edgv.tra_tunel_l USING gist (geom)# -ALTER TABLE edgv.tra_tunel_l OWNER TO postgres; +ALTER TABLE edgv.tra_tunel_l OWNER TO postgres# ALTER TABLE edgv.tra_tunel_l ADD CONSTRAINT tra_tunel_l_modaluso_fk FOREIGN KEY (modaluso) REFERENCES dominios.modal_uso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_tunel_l - ADD CONSTRAINT tra_tunel_l_modaluso_check - CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_tunel_l ALTER COLUMN modaluso SET DEFAULT 9999; + ADD CONSTRAINT tra_tunel_l_modaluso_check + CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_tunel_l ALTER COLUMN modaluso SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_l ADD CONSTRAINT tra_tunel_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_l ADD CONSTRAINT tra_tunel_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_l ADD CONSTRAINT tra_tunel_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_l ADD CONSTRAINT tra_tunel_l_necessitamanutencao_fk FOREIGN KEY (necessitamanutencao) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_l ALTER COLUMN necessitamanutencao SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_l ALTER COLUMN necessitamanutencao SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_l ADD CONSTRAINT tra_tunel_l_posicaopista_fk FOREIGN KEY (posicaopista) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_tunel_l - ADD CONSTRAINT tra_tunel_l_posicaopista_check - CHECK (posicaopista = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_tunel_l ALTER COLUMN posicaopista SET DEFAULT 9999; + ADD CONSTRAINT tra_tunel_l_posicaopista_check + CHECK (posicaopista = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_tunel_l ALTER COLUMN posicaopista SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_l ADD CONSTRAINT tra_tunel_l_tipopavimentacao_fk FOREIGN KEY (tipopavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_l ALTER COLUMN tipopavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_l ALTER COLUMN tipopavimentacao SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_l ADD CONSTRAINT tra_tunel_l_tipotunel_fk FOREIGN KEY (tipotunel) REFERENCES dominios.tipo_tunel (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_l ALTER COLUMN tipotunel SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_l ALTER COLUMN tipotunel SET DEFAULT 9999# CREATE TABLE edgv.tra_tunel_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, modaluso smallint NOT NULL, @@ -17526,78 +17958,81 @@ CREATE TABLE edgv.tra_tunel_p( tipopavimentacao smallint NOT NULL, altura real, tipotunel smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT tra_tunel_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_tunel_p_geom ON edgv.tra_tunel_p USING gist (geom); +)# +CREATE INDEX tra_tunel_p_geom ON edgv.tra_tunel_p USING gist (geom)# -ALTER TABLE edgv.tra_tunel_p OWNER TO postgres; +ALTER TABLE edgv.tra_tunel_p OWNER TO postgres# ALTER TABLE edgv.tra_tunel_p ADD CONSTRAINT tra_tunel_p_modaluso_fk FOREIGN KEY (modaluso) REFERENCES dominios.modal_uso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_tunel_p - ADD CONSTRAINT tra_tunel_p_modaluso_check - CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_tunel_p ALTER COLUMN modaluso SET DEFAULT 9999; + ADD CONSTRAINT tra_tunel_p_modaluso_check + CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_tunel_p ALTER COLUMN modaluso SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_p ADD CONSTRAINT tra_tunel_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_p ADD CONSTRAINT tra_tunel_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_p ADD CONSTRAINT tra_tunel_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_p ADD CONSTRAINT tra_tunel_p_necessitamanutencao_fk FOREIGN KEY (necessitamanutencao) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_p ALTER COLUMN necessitamanutencao SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_p ALTER COLUMN necessitamanutencao SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_p ADD CONSTRAINT tra_tunel_p_posicaopista_fk FOREIGN KEY (posicaopista) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_tunel_p - ADD CONSTRAINT tra_tunel_p_posicaopista_check - CHECK (posicaopista = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_tunel_p ALTER COLUMN posicaopista SET DEFAULT 9999; + ADD CONSTRAINT tra_tunel_p_posicaopista_check + CHECK (posicaopista = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_tunel_p ALTER COLUMN posicaopista SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_p ADD CONSTRAINT tra_tunel_p_tipopavimentacao_fk FOREIGN KEY (tipopavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_p ALTER COLUMN tipopavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_p ALTER COLUMN tipopavimentacao SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_p ADD CONSTRAINT tra_tunel_p_tipotunel_fk FOREIGN KEY (tipotunel) REFERENCES dominios.tipo_tunel (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_p ALTER COLUMN tipotunel SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_p ALTER COLUMN tipotunel SET DEFAULT 9999# CREATE TABLE edgv.tra_tunel_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, modaluso smallint NOT NULL, @@ -17613,78 +18048,81 @@ CREATE TABLE edgv.tra_tunel_a( tipopavimentacao smallint NOT NULL, altura real, tipotunel smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT tra_tunel_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_tunel_a_geom ON edgv.tra_tunel_a USING gist (geom); +)# +CREATE INDEX tra_tunel_a_geom ON edgv.tra_tunel_a USING gist (geom)# -ALTER TABLE edgv.tra_tunel_a OWNER TO postgres; +ALTER TABLE edgv.tra_tunel_a OWNER TO postgres# ALTER TABLE edgv.tra_tunel_a ADD CONSTRAINT tra_tunel_a_modaluso_fk FOREIGN KEY (modaluso) REFERENCES dominios.modal_uso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_tunel_a - ADD CONSTRAINT tra_tunel_a_modaluso_check - CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_tunel_a ALTER COLUMN modaluso SET DEFAULT 9999; + ADD CONSTRAINT tra_tunel_a_modaluso_check + CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_tunel_a ALTER COLUMN modaluso SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_a ADD CONSTRAINT tra_tunel_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_a ADD CONSTRAINT tra_tunel_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_a ADD CONSTRAINT tra_tunel_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_a ADD CONSTRAINT tra_tunel_a_necessitamanutencao_fk FOREIGN KEY (necessitamanutencao) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_a ALTER COLUMN necessitamanutencao SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_a ALTER COLUMN necessitamanutencao SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_a ADD CONSTRAINT tra_tunel_a_posicaopista_fk FOREIGN KEY (posicaopista) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_tunel_a - ADD CONSTRAINT tra_tunel_a_posicaopista_check - CHECK (posicaopista = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_tunel_a ALTER COLUMN posicaopista SET DEFAULT 9999; + ADD CONSTRAINT tra_tunel_a_posicaopista_check + CHECK (posicaopista = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_tunel_a ALTER COLUMN posicaopista SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_a ADD CONSTRAINT tra_tunel_a_tipopavimentacao_fk FOREIGN KEY (tipopavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_a ALTER COLUMN tipopavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_a ALTER COLUMN tipopavimentacao SET DEFAULT 9999# ALTER TABLE edgv.tra_tunel_a ADD CONSTRAINT tra_tunel_a_tipotunel_fk FOREIGN KEY (tipotunel) REFERENCES dominios.tipo_tunel (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_tunel_a ALTER COLUMN tipotunel SET DEFAULT 9999; +ALTER TABLE edgv.tra_tunel_a ALTER COLUMN tipotunel SET DEFAULT 9999# CREATE TABLE edgv.tra_passagem_elevada_viaduto_l( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, modaluso smallint NOT NULL, @@ -17704,78 +18142,81 @@ CREATE TABLE edgv.tra_passagem_elevada_viaduto_l( gabhorizsup real, gabvertsup real, cargasuportmaxima real, + observacao VARCHAR(255), geom geometry(MultiLinestring, [epsg]), CONSTRAINT tra_passagem_elevada_viaduto_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_passagem_elevada_viaduto_l_geom ON edgv.tra_passagem_elevada_viaduto_l USING gist (geom); +)# +CREATE INDEX tra_passagem_elevada_viaduto_l_geom ON edgv.tra_passagem_elevada_viaduto_l USING gist (geom)# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_l OWNER TO postgres; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_l OWNER TO postgres# ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ADD CONSTRAINT tra_passagem_elevada_viaduto_l_modaluso_fk FOREIGN KEY (modaluso) REFERENCES dominios.modal_uso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_passagem_elevada_viaduto_l - ADD CONSTRAINT tra_passagem_elevada_viaduto_l_modaluso_check - CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN modaluso SET DEFAULT 9999; + ADD CONSTRAINT tra_passagem_elevada_viaduto_l_modaluso_check + CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN modaluso SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ADD CONSTRAINT tra_passagem_elevada_viaduto_l_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ADD CONSTRAINT tra_passagem_elevada_viaduto_l_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ADD CONSTRAINT tra_passagem_elevada_viaduto_l_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ADD CONSTRAINT tra_passagem_elevada_viaduto_l_necessitamanutencao_fk FOREIGN KEY (necessitamanutencao) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN necessitamanutencao SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN necessitamanutencao SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ADD CONSTRAINT tra_passagem_elevada_viaduto_l_posicaopista_fk FOREIGN KEY (posicaopista) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_passagem_elevada_viaduto_l - ADD CONSTRAINT tra_passagem_elevada_viaduto_l_posicaopista_check - CHECK (posicaopista = ANY(ARRAY[0 :: SMALLINT, 4 :: SMALLINT, 7 :: SMALLINT, 13 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN posicaopista SET DEFAULT 9999; + ADD CONSTRAINT tra_passagem_elevada_viaduto_l_posicaopista_check + CHECK (posicaopista = ANY(ARRAY[0 :: SMALLINT, 4 :: SMALLINT, 7 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 97 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN posicaopista SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ADD CONSTRAINT tra_passagem_elevada_viaduto_l_tipopavimentacao_fk FOREIGN KEY (tipopavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN tipopavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN tipopavimentacao SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ADD CONSTRAINT tra_passagem_elevada_viaduto_l_tipopassagviad_fk FOREIGN KEY (tipopassagviad) REFERENCES dominios.tipo_passag_viad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN tipopassagviad SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_l ALTER COLUMN tipopassagviad SET DEFAULT 9999# CREATE TABLE edgv.tra_passagem_elevada_viaduto_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, modaluso smallint NOT NULL, @@ -17795,78 +18236,81 @@ CREATE TABLE edgv.tra_passagem_elevada_viaduto_p( gabhorizsup real, gabvertsup real, cargasuportmaxima real, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT tra_passagem_elevada_viaduto_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_passagem_elevada_viaduto_p_geom ON edgv.tra_passagem_elevada_viaduto_p USING gist (geom); +)# +CREATE INDEX tra_passagem_elevada_viaduto_p_geom ON edgv.tra_passagem_elevada_viaduto_p USING gist (geom)# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_p OWNER TO postgres; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_p OWNER TO postgres# ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ADD CONSTRAINT tra_passagem_elevada_viaduto_p_modaluso_fk FOREIGN KEY (modaluso) REFERENCES dominios.modal_uso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_passagem_elevada_viaduto_p - ADD CONSTRAINT tra_passagem_elevada_viaduto_p_modaluso_check - CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN modaluso SET DEFAULT 9999; + ADD CONSTRAINT tra_passagem_elevada_viaduto_p_modaluso_check + CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN modaluso SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ADD CONSTRAINT tra_passagem_elevada_viaduto_p_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ADD CONSTRAINT tra_passagem_elevada_viaduto_p_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ADD CONSTRAINT tra_passagem_elevada_viaduto_p_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ADD CONSTRAINT tra_passagem_elevada_viaduto_p_necessitamanutencao_fk FOREIGN KEY (necessitamanutencao) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN necessitamanutencao SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN necessitamanutencao SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ADD CONSTRAINT tra_passagem_elevada_viaduto_p_posicaopista_fk FOREIGN KEY (posicaopista) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_passagem_elevada_viaduto_p - ADD CONSTRAINT tra_passagem_elevada_viaduto_p_posicaopista_check - CHECK (posicaopista = ANY(ARRAY[0 :: SMALLINT, 4 :: SMALLINT, 7 :: SMALLINT, 13 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN posicaopista SET DEFAULT 9999; + ADD CONSTRAINT tra_passagem_elevada_viaduto_p_posicaopista_check + CHECK (posicaopista = ANY(ARRAY[0 :: SMALLINT, 4 :: SMALLINT, 7 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 97 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN posicaopista SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ADD CONSTRAINT tra_passagem_elevada_viaduto_p_tipopavimentacao_fk FOREIGN KEY (tipopavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN tipopavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN tipopavimentacao SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ADD CONSTRAINT tra_passagem_elevada_viaduto_p_tipopassagviad_fk FOREIGN KEY (tipopassagviad) REFERENCES dominios.tipo_passag_viad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN tipopassagviad SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_p ALTER COLUMN tipopassagviad SET DEFAULT 9999# CREATE TABLE edgv.tra_passagem_elevada_viaduto_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, modaluso smallint NOT NULL, @@ -17886,78 +18330,81 @@ CREATE TABLE edgv.tra_passagem_elevada_viaduto_a( gabhorizsup real, gabvertsup real, cargasuportmaxima real, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT tra_passagem_elevada_viaduto_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_passagem_elevada_viaduto_a_geom ON edgv.tra_passagem_elevada_viaduto_a USING gist (geom); +)# +CREATE INDEX tra_passagem_elevada_viaduto_a_geom ON edgv.tra_passagem_elevada_viaduto_a USING gist (geom)# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_a OWNER TO postgres; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_a OWNER TO postgres# ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ADD CONSTRAINT tra_passagem_elevada_viaduto_a_modaluso_fk FOREIGN KEY (modaluso) REFERENCES dominios.modal_uso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_passagem_elevada_viaduto_a - ADD CONSTRAINT tra_passagem_elevada_viaduto_a_modaluso_check - CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN modaluso SET DEFAULT 9999; + ADD CONSTRAINT tra_passagem_elevada_viaduto_a_modaluso_check + CHECK (modaluso = ANY(ARRAY[4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 9 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN modaluso SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ADD CONSTRAINT tra_passagem_elevada_viaduto_a_matconstr_fk FOREIGN KEY (matconstr) REFERENCES dominios.mat_constr (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN matconstr SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN matconstr SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ADD CONSTRAINT tra_passagem_elevada_viaduto_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ADD CONSTRAINT tra_passagem_elevada_viaduto_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ADD CONSTRAINT tra_passagem_elevada_viaduto_a_necessitamanutencao_fk FOREIGN KEY (necessitamanutencao) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN necessitamanutencao SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN necessitamanutencao SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ADD CONSTRAINT tra_passagem_elevada_viaduto_a_posicaopista_fk FOREIGN KEY (posicaopista) REFERENCES dominios.situacao_espacial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_passagem_elevada_viaduto_a - ADD CONSTRAINT tra_passagem_elevada_viaduto_a_posicaopista_check - CHECK (posicaopista = ANY(ARRAY[0 :: SMALLINT, 4 :: SMALLINT, 7 :: SMALLINT, 13 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN posicaopista SET DEFAULT 9999; + ADD CONSTRAINT tra_passagem_elevada_viaduto_a_posicaopista_check + CHECK (posicaopista = ANY(ARRAY[0 :: SMALLINT, 4 :: SMALLINT, 7 :: SMALLINT, 12 :: SMALLINT, 13 :: SMALLINT, 97 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN posicaopista SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ADD CONSTRAINT tra_passagem_elevada_viaduto_a_tipopavimentacao_fk FOREIGN KEY (tipopavimentacao) REFERENCES dominios.tipo_pavimentacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN tipopavimentacao SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN tipopavimentacao SET DEFAULT 9999# ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ADD CONSTRAINT tra_passagem_elevada_viaduto_a_tipopassagviad_fk FOREIGN KEY (tipopassagviad) REFERENCES dominios.tipo_passag_viad (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN tipopassagviad SET DEFAULT 9999; +ALTER TABLE edgv.tra_passagem_elevada_viaduto_a ALTER COLUMN tipopassagviad SET DEFAULT 9999# CREATE TABLE edgv.tra_patio_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, modaluso smallint NOT NULL, @@ -17965,54 +18412,56 @@ CREATE TABLE edgv.tra_patio_a( operacional smallint NOT NULL, situacaofisica smallint NOT NULL, finalidadepatio smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT tra_patio_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX tra_patio_a_geom ON edgv.tra_patio_a USING gist (geom); +)# +CREATE INDEX tra_patio_a_geom ON edgv.tra_patio_a USING gist (geom)# -ALTER TABLE edgv.tra_patio_a OWNER TO postgres; +ALTER TABLE edgv.tra_patio_a OWNER TO postgres# ALTER TABLE edgv.tra_patio_a ADD CONSTRAINT tra_patio_a_modaluso_fk FOREIGN KEY (modaluso) REFERENCES dominios.modal_uso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_patio_a ALTER COLUMN modaluso SET DEFAULT 9999; +ALTER TABLE edgv.tra_patio_a ALTER COLUMN modaluso SET DEFAULT 9999# ALTER TABLE edgv.tra_patio_a ADD CONSTRAINT tra_patio_a_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_patio_a ALTER COLUMN administracao SET DEFAULT 9999; +ALTER TABLE edgv.tra_patio_a ALTER COLUMN administracao SET DEFAULT 9999# ALTER TABLE edgv.tra_patio_a ADD CONSTRAINT tra_patio_a_operacional_fk FOREIGN KEY (operacional) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_patio_a ALTER COLUMN operacional SET DEFAULT 9999; +ALTER TABLE edgv.tra_patio_a ALTER COLUMN operacional SET DEFAULT 9999# ALTER TABLE edgv.tra_patio_a ADD CONSTRAINT tra_patio_a_situacaofisica_fk FOREIGN KEY (situacaofisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.tra_patio_a ALTER COLUMN situacaofisica SET DEFAULT 9999; +ALTER TABLE edgv.tra_patio_a ALTER COLUMN situacaofisica SET DEFAULT 9999# ALTER TABLE edgv.tra_patio_a ADD CONSTRAINT tra_patio_a_finalidadepatio_fk FOREIGN KEY (finalidadepatio) REFERENCES dominios.finalidade_patio (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.tra_patio_a - ADD CONSTRAINT tra_patio_a_finalidadepatio_check - CHECK (finalidadepatio = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.tra_patio_a ALTER COLUMN finalidadepatio SET DEFAULT 9999; + ADD CONSTRAINT tra_patio_a_finalidadepatio_check + CHECK (finalidadepatio = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 8 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.tra_patio_a ALTER COLUMN finalidadepatio SET DEFAULT 9999# CREATE TABLE edgv.veg_floresta_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, classificacaoporte smallint NOT NULL, @@ -18020,98 +18469,101 @@ CREATE TABLE edgv.veg_floresta_a( densidade smallint NOT NULL, secundaria smallint NOT NULL, especiepredominante smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT veg_floresta_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX veg_floresta_a_geom ON edgv.veg_floresta_a USING gist (geom); +)# +CREATE INDEX veg_floresta_a_geom ON edgv.veg_floresta_a USING gist (geom)# -ALTER TABLE edgv.veg_floresta_a OWNER TO postgres; +ALTER TABLE edgv.veg_floresta_a OWNER TO postgres# ALTER TABLE edgv.veg_floresta_a ADD CONSTRAINT veg_floresta_a_classificacaoporte_fk FOREIGN KEY (classificacaoporte) REFERENCES dominios.classificacao_porte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.veg_floresta_a - ADD CONSTRAINT veg_floresta_a_classificacaoporte_check - CHECK (classificacaoporte = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.veg_floresta_a ALTER COLUMN classificacaoporte SET DEFAULT 9999; + ADD CONSTRAINT veg_floresta_a_classificacaoporte_check + CHECK (classificacaoporte = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.veg_floresta_a ALTER COLUMN classificacaoporte SET DEFAULT 9999# ALTER TABLE edgv.veg_floresta_a ADD CONSTRAINT veg_floresta_a_antropizada_fk FOREIGN KEY (antropizada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_floresta_a ALTER COLUMN antropizada SET DEFAULT 9999; +ALTER TABLE edgv.veg_floresta_a ALTER COLUMN antropizada SET DEFAULT 9999# ALTER TABLE edgv.veg_floresta_a ADD CONSTRAINT veg_floresta_a_densidade_fk FOREIGN KEY (densidade) REFERENCES dominios.densidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_floresta_a ALTER COLUMN densidade SET DEFAULT 9999; +ALTER TABLE edgv.veg_floresta_a ALTER COLUMN densidade SET DEFAULT 9999# ALTER TABLE edgv.veg_floresta_a ADD CONSTRAINT veg_floresta_a_secundaria_fk FOREIGN KEY (secundaria) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_floresta_a ALTER COLUMN secundaria SET DEFAULT 9999; +ALTER TABLE edgv.veg_floresta_a ALTER COLUMN secundaria SET DEFAULT 9999# ALTER TABLE edgv.veg_floresta_a ADD CONSTRAINT veg_floresta_a_especiepredominante_fk FOREIGN KEY (especiepredominante) REFERENCES dominios.especie (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_floresta_a ALTER COLUMN especiepredominante SET DEFAULT 9999; +ALTER TABLE edgv.veg_floresta_a ALTER COLUMN especiepredominante SET DEFAULT 9999# CREATE TABLE edgv.veg_campinarana_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, classificacaoporte smallint NOT NULL, antropizada smallint NOT NULL, densidade smallint NOT NULL, secundaria smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT veg_campinarana_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX veg_campinarana_a_geom ON edgv.veg_campinarana_a USING gist (geom); +)# +CREATE INDEX veg_campinarana_a_geom ON edgv.veg_campinarana_a USING gist (geom)# -ALTER TABLE edgv.veg_campinarana_a OWNER TO postgres; +ALTER TABLE edgv.veg_campinarana_a OWNER TO postgres# ALTER TABLE edgv.veg_campinarana_a ADD CONSTRAINT veg_campinarana_a_classificacaoporte_fk FOREIGN KEY (classificacaoporte) REFERENCES dominios.classificacao_porte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_campinarana_a ALTER COLUMN classificacaoporte SET DEFAULT 9999; +ALTER TABLE edgv.veg_campinarana_a ALTER COLUMN classificacaoporte SET DEFAULT 9999# ALTER TABLE edgv.veg_campinarana_a ADD CONSTRAINT veg_campinarana_a_antropizada_fk FOREIGN KEY (antropizada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_campinarana_a ALTER COLUMN antropizada SET DEFAULT 9999; +ALTER TABLE edgv.veg_campinarana_a ALTER COLUMN antropizada SET DEFAULT 9999# ALTER TABLE edgv.veg_campinarana_a ADD CONSTRAINT veg_campinarana_a_densidade_fk FOREIGN KEY (densidade) REFERENCES dominios.densidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_campinarana_a ALTER COLUMN densidade SET DEFAULT 9999; +ALTER TABLE edgv.veg_campinarana_a ALTER COLUMN densidade SET DEFAULT 9999# ALTER TABLE edgv.veg_campinarana_a ADD CONSTRAINT veg_campinarana_a_secundaria_fk FOREIGN KEY (secundaria) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_campinarana_a ALTER COLUMN secundaria SET DEFAULT 9999; +ALTER TABLE edgv.veg_campinarana_a ALTER COLUMN secundaria SET DEFAULT 9999# CREATE TABLE edgv.veg_veg_cultivada_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, classificacaoporte smallint NOT NULL, @@ -18119,95 +18571,97 @@ CREATE TABLE edgv.veg_veg_cultivada_a( finalidade smallint NOT NULL, terreno smallint NOT NULL, cultivopredominante smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT veg_veg_cultivada_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX veg_veg_cultivada_a_geom ON edgv.veg_veg_cultivada_a USING gist (geom); +)# +CREATE INDEX veg_veg_cultivada_a_geom ON edgv.veg_veg_cultivada_a USING gist (geom)# -ALTER TABLE edgv.veg_veg_cultivada_a OWNER TO postgres; +ALTER TABLE edgv.veg_veg_cultivada_a OWNER TO postgres# ALTER TABLE edgv.veg_veg_cultivada_a ADD CONSTRAINT veg_veg_cultivada_a_classificacaoporte_fk FOREIGN KEY (classificacaoporte) REFERENCES dominios.classificacao_porte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_cultivada_a ALTER COLUMN classificacaoporte SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_cultivada_a ALTER COLUMN classificacaoporte SET DEFAULT 9999# ALTER TABLE edgv.veg_veg_cultivada_a ADD CONSTRAINT veg_veg_cultivada_a_tipolavoura_fk FOREIGN KEY (tipolavoura) REFERENCES dominios.tipo_lavoura (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_cultivada_a ALTER COLUMN tipolavoura SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_cultivada_a ALTER COLUMN tipolavoura SET DEFAULT 9999# ALTER TABLE edgv.veg_veg_cultivada_a ADD CONSTRAINT veg_veg_cultivada_a_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade_cultura (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_cultivada_a ALTER COLUMN finalidade SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_cultivada_a ALTER COLUMN finalidade SET DEFAULT 9999# ALTER TABLE edgv.veg_veg_cultivada_a ADD CONSTRAINT veg_veg_cultivada_a_terreno_fk FOREIGN KEY (terreno) REFERENCES dominios.condicao_terreno (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_cultivada_a ALTER COLUMN terreno SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_cultivada_a ALTER COLUMN terreno SET DEFAULT 9999# ALTER TABLE edgv.veg_veg_cultivada_a ADD CONSTRAINT veg_veg_cultivada_a_cultivopredominante_fk FOREIGN KEY (cultivopredominante) REFERENCES dominios.cultivo_predominante (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_cultivada_a ALTER COLUMN cultivopredominante SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_cultivada_a ALTER COLUMN cultivopredominante SET DEFAULT 9999# CREATE TABLE edgv.veg_veg_restinga_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, classificacaoporte smallint NOT NULL, antropizada smallint NOT NULL, densidade smallint NOT NULL, secundaria smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT veg_veg_restinga_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX veg_veg_restinga_a_geom ON edgv.veg_veg_restinga_a USING gist (geom); +)# +CREATE INDEX veg_veg_restinga_a_geom ON edgv.veg_veg_restinga_a USING gist (geom)# -ALTER TABLE edgv.veg_veg_restinga_a OWNER TO postgres; +ALTER TABLE edgv.veg_veg_restinga_a OWNER TO postgres# ALTER TABLE edgv.veg_veg_restinga_a ADD CONSTRAINT veg_veg_restinga_a_classificacaoporte_fk FOREIGN KEY (classificacaoporte) REFERENCES dominios.classificacao_porte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_restinga_a ALTER COLUMN classificacaoporte SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_restinga_a ALTER COLUMN classificacaoporte SET DEFAULT 9999# ALTER TABLE edgv.veg_veg_restinga_a ADD CONSTRAINT veg_veg_restinga_a_antropizada_fk FOREIGN KEY (antropizada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_restinga_a ALTER COLUMN antropizada SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_restinga_a ALTER COLUMN antropizada SET DEFAULT 9999# ALTER TABLE edgv.veg_veg_restinga_a ADD CONSTRAINT veg_veg_restinga_a_densidade_fk FOREIGN KEY (densidade) REFERENCES dominios.densidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_restinga_a ALTER COLUMN densidade SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_restinga_a ALTER COLUMN densidade SET DEFAULT 9999# ALTER TABLE edgv.veg_veg_restinga_a ADD CONSTRAINT veg_veg_restinga_a_secundaria_fk FOREIGN KEY (secundaria) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_restinga_a ALTER COLUMN secundaria SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_restinga_a ALTER COLUMN secundaria SET DEFAULT 9999# CREATE TABLE edgv.veg_cerrado_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, classificacaoporte smallint NOT NULL, @@ -18215,95 +18669,97 @@ CREATE TABLE edgv.veg_cerrado_a( densidade smallint NOT NULL, secundaria smallint NOT NULL, vereda smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT veg_cerrado_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX veg_cerrado_a_geom ON edgv.veg_cerrado_a USING gist (geom); +)# +CREATE INDEX veg_cerrado_a_geom ON edgv.veg_cerrado_a USING gist (geom)# -ALTER TABLE edgv.veg_cerrado_a OWNER TO postgres; +ALTER TABLE edgv.veg_cerrado_a OWNER TO postgres# ALTER TABLE edgv.veg_cerrado_a ADD CONSTRAINT veg_cerrado_a_classificacaoporte_fk FOREIGN KEY (classificacaoporte) REFERENCES dominios.classificacao_porte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_cerrado_a ALTER COLUMN classificacaoporte SET DEFAULT 9999; +ALTER TABLE edgv.veg_cerrado_a ALTER COLUMN classificacaoporte SET DEFAULT 9999# ALTER TABLE edgv.veg_cerrado_a ADD CONSTRAINT veg_cerrado_a_antropizada_fk FOREIGN KEY (antropizada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_cerrado_a ALTER COLUMN antropizada SET DEFAULT 9999; +ALTER TABLE edgv.veg_cerrado_a ALTER COLUMN antropizada SET DEFAULT 9999# ALTER TABLE edgv.veg_cerrado_a ADD CONSTRAINT veg_cerrado_a_densidade_fk FOREIGN KEY (densidade) REFERENCES dominios.densidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_cerrado_a ALTER COLUMN densidade SET DEFAULT 9999; +ALTER TABLE edgv.veg_cerrado_a ALTER COLUMN densidade SET DEFAULT 9999# ALTER TABLE edgv.veg_cerrado_a ADD CONSTRAINT veg_cerrado_a_secundaria_fk FOREIGN KEY (secundaria) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_cerrado_a ALTER COLUMN secundaria SET DEFAULT 9999; +ALTER TABLE edgv.veg_cerrado_a ALTER COLUMN secundaria SET DEFAULT 9999# ALTER TABLE edgv.veg_cerrado_a ADD CONSTRAINT veg_cerrado_a_vereda_fk FOREIGN KEY (vereda) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_cerrado_a ALTER COLUMN vereda SET DEFAULT 9999; +ALTER TABLE edgv.veg_cerrado_a ALTER COLUMN vereda SET DEFAULT 9999# CREATE TABLE edgv.veg_brejo_pantano_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, classificacaoporte smallint NOT NULL, antropizada smallint NOT NULL, densidade smallint NOT NULL, secundaria smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT veg_brejo_pantano_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX veg_brejo_pantano_a_geom ON edgv.veg_brejo_pantano_a USING gist (geom); +)# +CREATE INDEX veg_brejo_pantano_a_geom ON edgv.veg_brejo_pantano_a USING gist (geom)# -ALTER TABLE edgv.veg_brejo_pantano_a OWNER TO postgres; +ALTER TABLE edgv.veg_brejo_pantano_a OWNER TO postgres# ALTER TABLE edgv.veg_brejo_pantano_a ADD CONSTRAINT veg_brejo_pantano_a_classificacaoporte_fk FOREIGN KEY (classificacaoporte) REFERENCES dominios.classificacao_porte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_brejo_pantano_a ALTER COLUMN classificacaoporte SET DEFAULT 9999; +ALTER TABLE edgv.veg_brejo_pantano_a ALTER COLUMN classificacaoporte SET DEFAULT 9999# ALTER TABLE edgv.veg_brejo_pantano_a ADD CONSTRAINT veg_brejo_pantano_a_antropizada_fk FOREIGN KEY (antropizada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_brejo_pantano_a ALTER COLUMN antropizada SET DEFAULT 9999; +ALTER TABLE edgv.veg_brejo_pantano_a ALTER COLUMN antropizada SET DEFAULT 9999# ALTER TABLE edgv.veg_brejo_pantano_a ADD CONSTRAINT veg_brejo_pantano_a_densidade_fk FOREIGN KEY (densidade) REFERENCES dominios.densidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_brejo_pantano_a ALTER COLUMN densidade SET DEFAULT 9999; +ALTER TABLE edgv.veg_brejo_pantano_a ALTER COLUMN densidade SET DEFAULT 9999# ALTER TABLE edgv.veg_brejo_pantano_a ADD CONSTRAINT veg_brejo_pantano_a_secundaria_fk FOREIGN KEY (secundaria) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_brejo_pantano_a ALTER COLUMN secundaria SET DEFAULT 9999; +ALTER TABLE edgv.veg_brejo_pantano_a ALTER COLUMN secundaria SET DEFAULT 9999# CREATE TABLE edgv.veg_mangue_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, classificacaoporte smallint NOT NULL, @@ -18311,51 +18767,52 @@ CREATE TABLE edgv.veg_mangue_a( densidade smallint NOT NULL, secundaria smallint NOT NULL, tipomanguezal smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT veg_mangue_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX veg_mangue_a_geom ON edgv.veg_mangue_a USING gist (geom); +)# +CREATE INDEX veg_mangue_a_geom ON edgv.veg_mangue_a USING gist (geom)# -ALTER TABLE edgv.veg_mangue_a OWNER TO postgres; +ALTER TABLE edgv.veg_mangue_a OWNER TO postgres# ALTER TABLE edgv.veg_mangue_a ADD CONSTRAINT veg_mangue_a_classificacaoporte_fk FOREIGN KEY (classificacaoporte) REFERENCES dominios.classificacao_porte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_mangue_a ALTER COLUMN classificacaoporte SET DEFAULT 9999; +ALTER TABLE edgv.veg_mangue_a ALTER COLUMN classificacaoporte SET DEFAULT 9999# ALTER TABLE edgv.veg_mangue_a ADD CONSTRAINT veg_mangue_a_antropizada_fk FOREIGN KEY (antropizada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_mangue_a ALTER COLUMN antropizada SET DEFAULT 9999; +ALTER TABLE edgv.veg_mangue_a ALTER COLUMN antropizada SET DEFAULT 9999# ALTER TABLE edgv.veg_mangue_a ADD CONSTRAINT veg_mangue_a_densidade_fk FOREIGN KEY (densidade) REFERENCES dominios.densidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_mangue_a ALTER COLUMN densidade SET DEFAULT 9999; +ALTER TABLE edgv.veg_mangue_a ALTER COLUMN densidade SET DEFAULT 9999# ALTER TABLE edgv.veg_mangue_a ADD CONSTRAINT veg_mangue_a_secundaria_fk FOREIGN KEY (secundaria) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_mangue_a ALTER COLUMN secundaria SET DEFAULT 9999; +ALTER TABLE edgv.veg_mangue_a ALTER COLUMN secundaria SET DEFAULT 9999# ALTER TABLE edgv.veg_mangue_a ADD CONSTRAINT veg_mangue_a_tipomanguezal_fk FOREIGN KEY (tipomanguezal) REFERENCES dominios.tipo_manguezal (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_mangue_a ALTER COLUMN tipomanguezal SET DEFAULT 9999; +ALTER TABLE edgv.veg_mangue_a ALTER COLUMN tipomanguezal SET DEFAULT 9999# CREATE TABLE edgv.veg_reflorestamento_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, classificacaoporte smallint NOT NULL, @@ -18363,57 +18820,60 @@ CREATE TABLE edgv.veg_reflorestamento_a( finalidade smallint NOT NULL, terreno smallint NOT NULL, cultivopredominante smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT veg_reflorestamento_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX veg_reflorestamento_a_geom ON edgv.veg_reflorestamento_a USING gist (geom); +)# +CREATE INDEX veg_reflorestamento_a_geom ON edgv.veg_reflorestamento_a USING gist (geom)# -ALTER TABLE edgv.veg_reflorestamento_a OWNER TO postgres; +ALTER TABLE edgv.veg_reflorestamento_a OWNER TO postgres# ALTER TABLE edgv.veg_reflorestamento_a ADD CONSTRAINT veg_reflorestamento_a_classificacaoporte_fk FOREIGN KEY (classificacaoporte) REFERENCES dominios.classificacao_porte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_reflorestamento_a ALTER COLUMN classificacaoporte SET DEFAULT 9999; +ALTER TABLE edgv.veg_reflorestamento_a ALTER COLUMN classificacaoporte SET DEFAULT 9999# ALTER TABLE edgv.veg_reflorestamento_a ADD CONSTRAINT veg_reflorestamento_a_tipolavoura_fk FOREIGN KEY (tipolavoura) REFERENCES dominios.tipo_lavoura (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.veg_reflorestamento_a - ADD CONSTRAINT veg_reflorestamento_a_tipolavoura_check - CHECK (tipolavoura = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.veg_reflorestamento_a ALTER COLUMN tipolavoura SET DEFAULT 9999; + ADD CONSTRAINT veg_reflorestamento_a_tipolavoura_check + CHECK (tipolavoura = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.veg_reflorestamento_a ALTER COLUMN tipolavoura SET DEFAULT 9999# ALTER TABLE edgv.veg_reflorestamento_a ADD CONSTRAINT veg_reflorestamento_a_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade_cultura (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_reflorestamento_a ALTER COLUMN finalidade SET DEFAULT 9999; +ALTER TABLE edgv.veg_reflorestamento_a ALTER COLUMN finalidade SET DEFAULT 9999# ALTER TABLE edgv.veg_reflorestamento_a ADD CONSTRAINT veg_reflorestamento_a_terreno_fk FOREIGN KEY (terreno) REFERENCES dominios.condicao_terreno (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_reflorestamento_a ALTER COLUMN terreno SET DEFAULT 9999; +ALTER TABLE edgv.veg_reflorestamento_a ALTER COLUMN terreno SET DEFAULT 9999# ALTER TABLE edgv.veg_reflorestamento_a ADD CONSTRAINT veg_reflorestamento_a_cultivopredominante_fk FOREIGN KEY (cultivopredominante) REFERENCES dominios.cultivo_predominante (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.veg_reflorestamento_a - ADD CONSTRAINT veg_reflorestamento_a_cultivopredominante_check - CHECK (cultivopredominante = ANY(ARRAY[20 :: SMALLINT, 21 :: SMALLINT, 23 :: SMALLINT, 96 :: SMALLINT, 98 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.veg_reflorestamento_a ALTER COLUMN cultivopredominante SET DEFAULT 9999; + ADD CONSTRAINT veg_reflorestamento_a_cultivopredominante_check + CHECK (cultivopredominante = ANY(ARRAY[20 :: SMALLINT, 21 :: SMALLINT, 23 :: SMALLINT, 96 :: SMALLINT, 98 :: SMALLINT, 99 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.veg_reflorestamento_a ALTER COLUMN cultivopredominante SET DEFAULT 9999# CREATE TABLE edgv.veg_campo_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, classificacaoporte smallint NOT NULL, @@ -18421,101 +18881,105 @@ CREATE TABLE edgv.veg_campo_a( densidade smallint NOT NULL, secundaria smallint NOT NULL, tipocampo smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT veg_campo_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX veg_campo_a_geom ON edgv.veg_campo_a USING gist (geom); +)# +CREATE INDEX veg_campo_a_geom ON edgv.veg_campo_a USING gist (geom)# -ALTER TABLE edgv.veg_campo_a OWNER TO postgres; +ALTER TABLE edgv.veg_campo_a OWNER TO postgres# ALTER TABLE edgv.veg_campo_a ADD CONSTRAINT veg_campo_a_classificacaoporte_fk FOREIGN KEY (classificacaoporte) REFERENCES dominios.classificacao_porte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.veg_campo_a - ADD CONSTRAINT veg_campo_a_classificacaoporte_check - CHECK (classificacaoporte = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.veg_campo_a ALTER COLUMN classificacaoporte SET DEFAULT 9999; + ADD CONSTRAINT veg_campo_a_classificacaoporte_check + CHECK (classificacaoporte = ANY(ARRAY[0 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.veg_campo_a ALTER COLUMN classificacaoporte SET DEFAULT 9999# ALTER TABLE edgv.veg_campo_a ADD CONSTRAINT veg_campo_a_antropizada_fk FOREIGN KEY (antropizada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_campo_a ALTER COLUMN antropizada SET DEFAULT 9999; +ALTER TABLE edgv.veg_campo_a ALTER COLUMN antropizada SET DEFAULT 9999# ALTER TABLE edgv.veg_campo_a ADD CONSTRAINT veg_campo_a_densidade_fk FOREIGN KEY (densidade) REFERENCES dominios.densidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.veg_campo_a - ADD CONSTRAINT veg_campo_a_densidade_check - CHECK (densidade = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.veg_campo_a ALTER COLUMN densidade SET DEFAULT 9999; + ADD CONSTRAINT veg_campo_a_densidade_check + CHECK (densidade = ANY(ARRAY[2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.veg_campo_a ALTER COLUMN densidade SET DEFAULT 9999# ALTER TABLE edgv.veg_campo_a ADD CONSTRAINT veg_campo_a_secundaria_fk FOREIGN KEY (secundaria) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_campo_a ALTER COLUMN secundaria SET DEFAULT 9999; +ALTER TABLE edgv.veg_campo_a ALTER COLUMN secundaria SET DEFAULT 9999# ALTER TABLE edgv.veg_campo_a ADD CONSTRAINT veg_campo_a_tipocampo_fk FOREIGN KEY (tipocampo) REFERENCES dominios.tipo_campo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_campo_a ALTER COLUMN tipocampo SET DEFAULT 9999; +ALTER TABLE edgv.veg_campo_a ALTER COLUMN tipocampo SET DEFAULT 9999# CREATE TABLE edgv.veg_caatinga_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, classificacaoporte smallint NOT NULL, antropizada smallint NOT NULL, densidade smallint NOT NULL, secundaria smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT veg_caatinga_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX veg_caatinga_a_geom ON edgv.veg_caatinga_a USING gist (geom); +)# +CREATE INDEX veg_caatinga_a_geom ON edgv.veg_caatinga_a USING gist (geom)# -ALTER TABLE edgv.veg_caatinga_a OWNER TO postgres; +ALTER TABLE edgv.veg_caatinga_a OWNER TO postgres# ALTER TABLE edgv.veg_caatinga_a ADD CONSTRAINT veg_caatinga_a_classificacaoporte_fk FOREIGN KEY (classificacaoporte) REFERENCES dominios.classificacao_porte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_caatinga_a ALTER COLUMN classificacaoporte SET DEFAULT 9999; +ALTER TABLE edgv.veg_caatinga_a ALTER COLUMN classificacaoporte SET DEFAULT 9999# ALTER TABLE edgv.veg_caatinga_a ADD CONSTRAINT veg_caatinga_a_antropizada_fk FOREIGN KEY (antropizada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_caatinga_a ALTER COLUMN antropizada SET DEFAULT 9999; +ALTER TABLE edgv.veg_caatinga_a ALTER COLUMN antropizada SET DEFAULT 9999# ALTER TABLE edgv.veg_caatinga_a ADD CONSTRAINT veg_caatinga_a_densidade_fk FOREIGN KEY (densidade) REFERENCES dominios.densidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_caatinga_a ALTER COLUMN densidade SET DEFAULT 9999; +ALTER TABLE edgv.veg_caatinga_a ALTER COLUMN densidade SET DEFAULT 9999# ALTER TABLE edgv.veg_caatinga_a ADD CONSTRAINT veg_caatinga_a_secundaria_fk FOREIGN KEY (secundaria) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_caatinga_a ALTER COLUMN secundaria SET DEFAULT 9999; +ALTER TABLE edgv.veg_caatinga_a ALTER COLUMN secundaria SET DEFAULT 9999# CREATE TABLE edgv.veg_veg_area_contato_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, classificacaoporte smallint NOT NULL, @@ -18523,62 +18987,64 @@ CREATE TABLE edgv.veg_veg_area_contato_a( densidade smallint NOT NULL, secundaria smallint NOT NULL, tipoveg smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT veg_veg_area_contato_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX veg_veg_area_contato_a_geom ON edgv.veg_veg_area_contato_a USING gist (geom); +)# +CREATE INDEX veg_veg_area_contato_a_geom ON edgv.veg_veg_area_contato_a USING gist (geom)# -ALTER TABLE edgv.veg_veg_area_contato_a OWNER TO postgres; +ALTER TABLE edgv.veg_veg_area_contato_a OWNER TO postgres# ALTER TABLE edgv.veg_veg_area_contato_a ADD CONSTRAINT veg_veg_area_contato_a_classificacaoporte_fk FOREIGN KEY (classificacaoporte) REFERENCES dominios.classificacao_porte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_area_contato_a ALTER COLUMN classificacaoporte SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_area_contato_a ALTER COLUMN classificacaoporte SET DEFAULT 9999# ALTER TABLE edgv.veg_veg_area_contato_a ADD CONSTRAINT veg_veg_area_contato_a_antropizada_fk FOREIGN KEY (antropizada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_area_contato_a ALTER COLUMN antropizada SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_area_contato_a ALTER COLUMN antropizada SET DEFAULT 9999# ALTER TABLE edgv.veg_veg_area_contato_a ADD CONSTRAINT veg_veg_area_contato_a_densidade_fk FOREIGN KEY (densidade) REFERENCES dominios.densidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_area_contato_a ALTER COLUMN densidade SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_area_contato_a ALTER COLUMN densidade SET DEFAULT 9999# ALTER TABLE edgv.veg_veg_area_contato_a ADD CONSTRAINT veg_veg_area_contato_a_secundaria_fk FOREIGN KEY (secundaria) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_area_contato_a ALTER COLUMN secundaria SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_area_contato_a ALTER COLUMN secundaria SET DEFAULT 9999# ALTER TABLE edgv.veg_veg_area_contato_a ADD CONSTRAINT veg_veg_area_contato_a_tipoveg_fk FOREIGN KEY (tipoveg) REFERENCES dominios.tipo_vegetacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.veg_veg_area_contato_a ALTER COLUMN tipoveg SET DEFAULT 9999; +ALTER TABLE edgv.veg_veg_area_contato_a ALTER COLUMN tipoveg SET DEFAULT 9999# CREATE TABLE edgv.ver_arvore_isolada_p( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), geometriaaproximada boolean NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT ver_arvore_isolada_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX ver_arvore_isolada_p_geom ON edgv.ver_arvore_isolada_p USING gist (geom); +)# +CREATE INDEX ver_arvore_isolada_p_geom ON edgv.ver_arvore_isolada_p USING gist (geom)# -ALTER TABLE edgv.ver_arvore_isolada_p OWNER TO postgres; +ALTER TABLE edgv.ver_arvore_isolada_p OWNER TO postgres# CREATE TABLE edgv.ver_jardim_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), nome varchar(255), geometriaaproximada boolean NOT NULL, classificacaoporte smallint NOT NULL, @@ -18586,85 +19052,83 @@ CREATE TABLE edgv.ver_jardim_a( finalidade smallint NOT NULL, terreno smallint NOT NULL, cultivopredominante smallint NOT NULL, + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT ver_jardim_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX ver_jardim_a_geom ON edgv.ver_jardim_a USING gist (geom); +)# +CREATE INDEX ver_jardim_a_geom ON edgv.ver_jardim_a USING gist (geom)# -ALTER TABLE edgv.ver_jardim_a OWNER TO postgres; +ALTER TABLE edgv.ver_jardim_a OWNER TO postgres# ALTER TABLE edgv.ver_jardim_a ADD CONSTRAINT ver_jardim_a_classificacaoporte_fk FOREIGN KEY (classificacaoporte) REFERENCES dominios.classificacao_porte (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.ver_jardim_a ALTER COLUMN classificacaoporte SET DEFAULT 9999; +ALTER TABLE edgv.ver_jardim_a ALTER COLUMN classificacaoporte SET DEFAULT 9999# ALTER TABLE edgv.ver_jardim_a ADD CONSTRAINT ver_jardim_a_tipolavoura_fk FOREIGN KEY (tipolavoura) REFERENCES dominios.tipo_lavoura (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.ver_jardim_a - ADD CONSTRAINT ver_jardim_a_tipolavoura_check - CHECK (tipolavoura = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.ver_jardim_a ALTER COLUMN tipolavoura SET DEFAULT 9999; + ADD CONSTRAINT ver_jardim_a_tipolavoura_check + CHECK (tipolavoura = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.ver_jardim_a ALTER COLUMN tipolavoura SET DEFAULT 9999# ALTER TABLE edgv.ver_jardim_a ADD CONSTRAINT ver_jardim_a_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade_cultura (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# ALTER TABLE edgv.ver_jardim_a - ADD CONSTRAINT ver_jardim_a_finalidade_check - CHECK (finalidade = ANY(ARRAY[4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.ver_jardim_a ALTER COLUMN finalidade SET DEFAULT 9999; + ADD CONSTRAINT ver_jardim_a_finalidade_check + CHECK (finalidade = ANY(ARRAY[4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.ver_jardim_a ALTER COLUMN finalidade SET DEFAULT 9999# ALTER TABLE edgv.ver_jardim_a ADD CONSTRAINT ver_jardim_a_terreno_fk FOREIGN KEY (terreno) REFERENCES dominios.condicao_terreno (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.ver_jardim_a ALTER COLUMN terreno SET DEFAULT 9999; +ALTER TABLE edgv.ver_jardim_a ALTER COLUMN terreno SET DEFAULT 9999# ALTER TABLE edgv.ver_jardim_a ADD CONSTRAINT ver_jardim_a_cultivopredominante_fk FOREIGN KEY (cultivopredominante) REFERENCES dominios.cultivo_predominante (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; + ON UPDATE NO ACTION ON DELETE NO ACTION# -ALTER TABLE edgv.ver_jardim_a ALTER COLUMN cultivopredominante SET DEFAULT 9999; - -CREATE TABLE edgv.lml_limite_politico_administrativo_l( - id serial NOT NULL, - nome varchar(255), - geometriaaproximada boolean NOT NULL, - tipolimpol smallint NOT NULL, - geom geometry(MultiLinestring, [epsg]), - CONSTRAINT lml_limite_politico_administrativo_l_pk PRIMARY KEY (id) - WITH (FILLFACTOR = 80) -); -CREATE INDEX lml_limite_politico_administrativo_l_geom ON edgv.lml_limite_politico_administrativo_l USING gist (geom); - -ALTER TABLE edgv.lml_limite_politico_administrativo_l OWNER TO postgres; - -ALTER TABLE edgv.lml_limite_politico_administrativo_l - ADD CONSTRAINT lml_limite_politico_administrativo_l_tipolimpol_fk FOREIGN KEY (tipolimpol) - REFERENCES dominios.tipo_lim_politico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION; - -ALTER TABLE edgv.lml_limite_politico_administrativo_l ALTER COLUMN tipolimpol SET DEFAULT 9999; +ALTER TABLE edgv.ver_jardim_a ALTER COLUMN cultivopredominante SET DEFAULT 9999# CREATE TABLE edgv.aux_moldura_a( - id serial NOT NULL, + id uuid NOT NULL DEFAULT uuid_generate_v4(), escala varchar(255), inom varchar(255), mi varchar(255), nome varchar(255), + observacao VARCHAR(255), geom geometry(MultiPolygon, [epsg]), CONSTRAINT aux_moldura_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -); -CREATE INDEX aux_moldura_a_geom ON edgv.aux_moldura_a USING gist (geom); +)# +CREATE INDEX aux_moldura_a_geom ON edgv.aux_moldura_a USING gist (geom)# + +ALTER TABLE edgv.aux_moldura_a OWNER TO postgres# + +CREATE TABLE edgv.aux_obstaculo_vertical_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + altitude real NOT NULL, + altura real NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT aux_obstaculo_vertical_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_obstaculo_vertical_p_geom ON edgv.aux_obstaculo_vertical_p USING gist (geom)# -ALTER TABLE edgv.aux_moldura_a OWNER TO postgres; +ALTER TABLE edgv.aux_obstaculo_vertical_p OWNER TO postgres# \ No newline at end of file diff --git a/DsgTools/core/DbModels/PostGIS/3_Orto/edgv3_orto.sql b/DsgTools/core/DbModels/PostGIS/3_Orto/edgv3_orto.sql new file mode 100644 index 000000000..ac08b1ab6 --- /dev/null +++ b/DsgTools/core/DbModels/PostGIS/3_Orto/edgv3_orto.sql @@ -0,0 +1,2992 @@ +CREATE SCHEMA edgv# +CREATE SCHEMA dominios# + +CREATE EXTENSION postgis# +CREATE EXTENSION IF NOT EXISTS "uuid-ossp"# +SET search_path TO pg_catalog,public,edgv,dominios# + +CREATE TABLE public.db_metadata( + edgvversion varchar(50) NOT NULL DEFAULT 'EDGV 3.0 Orto', + dbimplversion varchar(50) NOT NULL DEFAULT '2.4.0', + CONSTRAINT edgvversioncheck CHECK (edgvversion = 'EDGV 3.0 Orto') +)# +INSERT INTO public.db_metadata (edgvversion, dbimplversion) VALUES ('EDGV 3.0 Orto','2.4.0')# + +CREATE TABLE dominios.tipo_produto_residuo ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_produto_residuo_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (3,'Petróleo (3)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (5,'Gás (5)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (18,'Cascalho (18)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (22,'Pedra (brita) (22)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (23,'Granito (23)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (24,'Mármore (24)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (25,'Bauxita (25)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (26,'Manganês (26)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (27,'Talco (27)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (32,'Cobre (32)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (33,'Carvão mineral (33)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (34,'Sal (34)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (35,'Ferro (35)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (37,'Ouro (37)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (38,'Diamante (38)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (39,'Prata (39)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (40,'Pedra preciosa (40)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (42,'Areia (42)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (43,'Saibro/piçarra (43)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (45,'Ágata (45)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (47,'Água marinha (47)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (48,'Água mineral (48)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (49,'Alexandrita (49)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (50,'Ametista (50)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (51,'Amianto (51)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (52,'Argila (52)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (53,'Barita (53)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (54,'Bentonita (54)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (55,'Calcário (55)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (56,'Carvão vegetal (56)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (57,'Caulim (57)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (59,'Chumbo (59)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (60,'Citrino (60)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (61,'Crisoberilo (61)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (62,'Cristal de rocha (62)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (63,'Cromo (63)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (64,'Diatomita (64)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (65,'Dolomito (65)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (67,'Esmeralda (67)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (68,'Estanho (68)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (69,'Feldspato (69)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (70,'Fosfato (70)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (71,'Gipsita (71)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (72,'Grafita (72)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (73,'Granada (73)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (74,'Lítio (74)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (78,'Magnesita (78)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (79,'Mica (79)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (80,'Nióbio (80)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (81,'Níquel (81)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (82,'Opala (82)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (83,'Rocha ornamental (83)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (84,'Sal-gema (84)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (85,'Terras raras (85)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (86,'Titânio (86)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (87,'Topázio (87)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (88,'Tório (88)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (89,'Tungstênio (89)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (90,'Turfa (90)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (91,'Turmalina (91)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (92,'Urânio (92)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (93,'Vermiculita (93)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (94,'Zinco (94)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (99,'Outros (99)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (100,'Zircônio (100)')# +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_produto_residuo OWNER TO postgres# + +CREATE TABLE dominios.auxiliar ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT auxiliar_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.auxiliar (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.auxiliar (code,code_name) VALUES (1,'Sim (1)')# +INSERT INTO dominios.auxiliar (code,code_name) VALUES (2,'Não (2)')# +INSERT INTO dominios.auxiliar (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.auxiliar OWNER TO postgres# + +CREATE TABLE dominios.posicao_rotulo ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT posicao_rotulo_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (1,'Na linha (1)')# +INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (2,'Acima da linha (2)')# +INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (3,'Abaixo da linha (3)')# +INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.posicao_rotulo OWNER TO postgres# + +CREATE TABLE dominios.justificativa ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT justificativa_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.justificativa (code,code_name) VALUES (1,'Esquerda (1)')# +INSERT INTO dominios.justificativa (code,code_name) VALUES (2,'Centro (2)')# +INSERT INTO dominios.justificativa (code,code_name) VALUES (3,'Direita (3)')# +INSERT INTO dominios.justificativa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.justificativa OWNER TO postgres# + +CREATE TABLE dominios.ancora_horizontal ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT ancora_horizontal_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (1,'Esquerda (1)')# +INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (2,'Centro (2)')# +INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (3,'Direita (3)')# +INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.ancora_horizontal OWNER TO postgres# + +CREATE TABLE dominios.ancora_vertical ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT ancora_vertical_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (1,'Inferior (1)')# +INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (2,'Meio (2)')# +INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (3,'Superior (3)')# +INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.ancora_vertical OWNER TO postgres# + +CREATE TABLE dominios.material_construcao ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT material_construcao_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.material_construcao (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (1,'Alvenaria (1)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (2,'Concreto (2)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (3,'Metal (3)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (4,'Rocha (4)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (5,'Madeira (5)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (9,'Fibra (9)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (23,'Terra (23)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (97,'Não aplicável (97)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (98,'Outros (98)')# +INSERT INTO dominios.material_construcao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.material_construcao OWNER TO postgres# + +CREATE TABLE dominios.tipo_barragem ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_barragem_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_barragem (code,code_name) VALUES (1,'Barragem (1)')# +INSERT INTO dominios.tipo_barragem (code,code_name) VALUES (2,'Dique (2)')# +INSERT INTO dominios.tipo_barragem (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_barragem OWNER TO postgres# + +CREATE TABLE dominios.tipo_extracao_mineral ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_extracao_mineral_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (1,'Poço / Água subterrânea (1)')# +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (4,'Mina / Pedreira (4)')# +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (5,'Garimpo (5)')# +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (6,'Salina (6)')# +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (8,'Poço / Petróleo (8)')# +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_extracao_mineral OWNER TO postgres# + +CREATE TABLE dominios.tipo_ilha ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_ilha_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (1,'Fluvial (1)')# +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (2,'Marítima (2)')# +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (3,'Lacustre (3)')# +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_ilha OWNER TO postgres# + +CREATE TABLE dominios.tipo_toponimo_fisiografico ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_toponimo_fisiografico_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (1,'Serra (1)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (2,'Morro (2)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (3,'Montanha (3)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (4,'Chapada (4)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (5,'Maciço (5)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (6,'Planalto (6)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (7,'Planície (7)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (9,'Península (9)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (10,'Ponta (10)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (11,'Cabo (11)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (12,'Praia (12)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (17,'Pico (17)')# +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_toponimo_fisiografico OWNER TO postgres# + +CREATE TABLE dominios.tipo_elemento_hidrografico ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_elemento_hidrografico_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (6,'Foz marítima (6)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (9,'Cachoeira (9)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (10,'Salto (10)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (11,'Catarata (11)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (12,'Corredeira (12)')# +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_elemento_hidrografico OWNER TO postgres# + +CREATE TABLE dominios.forma_extracao ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT forma_extracao_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.forma_extracao (code,code_name) VALUES (5,'A céu aberto (5)')# +INSERT INTO dominios.forma_extracao (code,code_name) VALUES (6,'Subterrânea (6)')# +INSERT INTO dominios.forma_extracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.forma_extracao OWNER TO postgres# + +CREATE TABLE dominios.situacao_fisica ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT situacao_fisica_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (1,'Abandonada (1)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (2,'Destruída (2)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (3,'Construída (3)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (4,'Em construção (4)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.situacao_fisica OWNER TO postgres# + +CREATE TABLE dominios.tipo_elemento_energia ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_elemento_energia_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_elemento_energia (code,code_name) VALUES (303,'Linha de transmissão de energia (303)')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name) VALUES (405,'Estação geradora – Eólica (405)')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name) VALUES (408,'Estação geradora – Hidrelétrica (408)')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name) VALUES (407,'Estação geradora – Maré-motriz (407)')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name) VALUES (498,'Estação geradora – Outras (498)')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name) VALUES (406,'Estação geradora – Solar (406)')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name) VALUES (409,'Estação geradora – Termelétrica (409)')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name) VALUES (1801,'Subestação de transmissão de energia elétrica (1801)')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name) VALUES (1802,'Subestação de distribuição de energia elétrica (1802)')# +INSERT INTO dominios.tipo_elemento_energia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_elemento_energia OWNER TO postgres# + +CREATE TABLE dominios.bitola ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT bitola_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.bitola (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (1,'Métrica (1)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (2,'Internacional (2)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (3,'Larga (3)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (4,'Mista métrica internacional (4)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (5,'Mista métrica larga (5)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (6,'Mista internacional larga (6)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.bitola OWNER TO postgres# + +CREATE TABLE dominios.tipo_massa_dagua ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_massa_dagua_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (1,'Rio (com fluxo) (1)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (2,'Canal (com fluxo) (2)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (3,'Oceano (sem fluxo) (3)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (4,'Baía (sem fluxo) (4)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (5,'Enseada (sem fluxo) (5)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (6,'Meando Abandonado (sem fluxo) (6)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (7,'Lago ou Lagoa (sem fluxo) (7)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (9,'Laguna (com fluxo) (9)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (10,'Represa/açude com fluxo (10)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (11,'Represa/açude sem fluxo (11)')# +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_massa_dagua OWNER TO postgres# + +CREATE TABLE dominios.regime ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT regime_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.regime (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.regime (code,code_name) VALUES (1,'Permanente (1)')# +INSERT INTO dominios.regime (code,code_name) VALUES (3,'Temporário (3)')# +INSERT INTO dominios.regime (code,code_name) VALUES (5,'Seco (5)')# +INSERT INTO dominios.regime (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.regime OWNER TO postgres# + +CREATE TABLE dominios.tipo_trecho_drenagem ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_trecho_drenagem_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (1,'Rio (1)')# +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (2,'Canal (2)')# +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (3,'Trecho pluvial (3)')# +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (4,'Canal encoberto (4)')# +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (5,'Canal não operacional (5)')# +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_trecho_drenagem OWNER TO postgres# + +CREATE TABLE dominios.situacao_em_poligono ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT situacao_em_poligono_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (1,'Fora de polígono (1)')# +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (2,'Dentro de polígono - Trecho principal (2)')# +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (3,'Dentro de polígono - Trecho secundário (3)')# +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (4,'Dentro de polígono - Trecho compartilhado (4)')# +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.situacao_em_poligono OWNER TO postgres# + +CREATE TABLE dominios.tipo_limite_especial ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_limite_especial_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (2,'Terra indígena (2)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (5,'Unidade de Conservação (5)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (24,'Área de Proteção Ambiental – APA (24)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (25,'Área de Relevante Interesse Ecológico – ARIE (25)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (26,'Floresta – FLO (26)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (27,'Reserva de Desenvolvimento Sustentável – RDS (27)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (28,'Reserva Extrativista – RESEX (28)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (29,'Reserva de Fauna – REFAU (29)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (30,'Reserva Particular do Patrimônio Natural – RPPN (30)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (31,'Estação Ecológica – ESEC (31)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (32,'Parque – PAR (32)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (33,'Monumento Natural – MONA (33)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (34,'Reserva Biológica – REBIO (34)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (35,'Refúgio de Vida Silvestre – RVS (35)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (36,'Área militar (36)')# +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_limite_especial OWNER TO postgres# + +CREATE TABLE dominios.booleano ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT booleano_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.booleano (code,code_name) VALUES (1,'Sim (1)')# +INSERT INTO dominios.booleano (code,code_name) VALUES (2,'Não (2)')# +INSERT INTO dominios.booleano (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.booleano OWNER TO postgres# + +CREATE TABLE dominios.tipo_localidade ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_localidade_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (1,'Cidade (1)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (2,'Capital estadual (2)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (3,'Capital federal (3)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (4,'Vila (4)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (5,'Aglomerado rural isolado – Núcleo (5)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (6,'Aglomerado rural isolado – Povoado (6)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (7,'Outros aglomerados rurais – Lugarejo (7)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (8,'Nome local (8)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_localidade OWNER TO postgres# + +CREATE TABLE dominios.uso_pista ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT uso_pista_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.uso_pista (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (6,'Particular (6)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (11,'Público (11)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (12,'Militar (12)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (13,'Público/Militar (13)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.uso_pista OWNER TO postgres# + +CREATE TABLE dominios.indice ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT indice_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.indice (code,code_name) VALUES (1,'Mestra (1)')# +INSERT INTO dominios.indice (code,code_name) VALUES (2,'Normal (2)')# +INSERT INTO dominios.indice (code,code_name) VALUES (3,'Auxiliar (3)')# +INSERT INTO dominios.indice (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.indice OWNER TO postgres# + +CREATE TABLE dominios.tipo_pista_pouso ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_pista_pouso_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (9,'Pista de pouso (9)')# +INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (10,'Pista de táxi (10)')# +INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (11,'Heliponto (11)')# +INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_pista_pouso OWNER TO postgres# + +CREATE TABLE dominios.revestimento ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT revestimento_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.revestimento (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (1,'Leito natural (1)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (2,'Revestimento primário (solto) (2)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (3,'Pavimentado (3)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (4,'Calçado (4)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.revestimento OWNER TO postgres# + +CREATE TABLE dominios.tipo_limite_legal ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_limite_legal_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_limite_legal (code,code_name) VALUES (1,'Limite Internacional (1)')# +INSERT INTO dominios.tipo_limite_legal (code,code_name) VALUES (2,'Limite Estadual (2)')# +INSERT INTO dominios.tipo_limite_legal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_limite_legal OWNER TO postgres# + +CREATE TABLE dominios.posicao_relativa ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT posicao_relativa_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (2,'Superfície (2)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (3,'Elevado (3)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (6,'Subterrâneo (6)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.posicao_relativa OWNER TO postgres# + +CREATE TABLE dominios.jurisdicao ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT jurisdicao_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (1,'Federal (1)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (2,'Estadual (2)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (3,'Municipal (3)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (6,'Particular (6)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.jurisdicao OWNER TO postgres# + +CREATE TABLE dominios.administracao ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT administracao_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.administracao (code,code_name) VALUES (0,'Desconhecida (0)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (1,'Federal (1)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (2,'Estadual (2)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (3,'Municipal (3)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (6,'Particular (6)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (7,'Concessionada (7)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.administracao OWNER TO postgres# + +CREATE TABLE dominios.tipo_elemento_infraestrutura ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_elemento_infraestrutura_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name) VALUES (1938,'Atrac - Cais (1938)')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name) VALUES (1939,'Atrac - Cais flutuante (1939)')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name) VALUES (1940,'Atrac - Trapiche (1940)')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name) VALUES (1941,'Atrac - Molhe de atracação (1941)')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name) VALUES (1942,'Atrac - Pier (1942)')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name) VALUES (1943,'Atrac - Dolfim (1943)')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name) VALUES (1944,'Atrac - Desembarcadouro (1944)')# +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_elemento_infraestrutura OWNER TO postgres# + +CREATE TABLE dominios.tipo_via_deslocamento ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_via_deslocamento_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (2,'Estrada/Rodovia (2)')# +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (4,'Auto-estrada (4)')# +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_via_deslocamento OWNER TO postgres# + +CREATE TABLE dominios.tipo_ferrovia ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT tipo_ferrovia_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (5,'Bonde (5)')# +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (6,'Aeromóvel (6)')# +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (7,'Trem (7)')# +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (8,'Metrô (8)')# +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.tipo_ferrovia OWNER TO postgres# + +CREATE TABLE dominios.nr_linhas ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT nr_linhas_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (0,'Desconhecido (0)')# +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (1,'Simples (1)')# +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (2,'Dupla (2)')# +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (3,'Múltipla (3)')# +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.nr_linhas OWNER TO postgres# + +CREATE TABLE dominios.trafego ( + code smallint NOT NULL, + code_name text NOT NULL, + CONSTRAINT trafego_pk PRIMARY KEY (code) +)# + +INSERT INTO dominios.trafego (code,code_name) VALUES (1,'Permanente (1)')# +INSERT INTO dominios.trafego (code,code_name) VALUES (2,'Periódico (2)')# +INSERT INTO dominios.trafego (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# + +ALTER TABLE dominios.trafego OWNER TO postgres# + +CREATE TABLE edgv.cobter_massa_dagua_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + regime smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + apresentar_simbologia smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT cobter_massa_dagua_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX cobter_massa_dagua_a_geom ON edgv.cobter_massa_dagua_a USING gist (geom)# + +ALTER TABLE edgv.cobter_massa_dagua_a OWNER TO postgres# + +ALTER TABLE edgv.cobter_massa_dagua_a + ADD CONSTRAINT cobter_massa_dagua_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_massa_dagua (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.cobter_massa_dagua_a + ADD CONSTRAINT cobter_massa_dagua_a_regime_fk FOREIGN KEY (regime) + REFERENCES dominios.regime (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN regime SET DEFAULT 9999# + +ALTER TABLE edgv.cobter_massa_dagua_a + ADD CONSTRAINT cobter_massa_dagua_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.cobter_massa_dagua_a + ADD CONSTRAINT cobter_massa_dagua_a_apresentar_simbologia_fk FOREIGN KEY (apresentar_simbologia) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN apresentar_simbologia SET DEFAULT 9999# + +ALTER TABLE edgv.cobter_massa_dagua_a + ADD CONSTRAINT cobter_massa_dagua_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.constr_extracao_mineral_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + tipo_produto smallint NOT NULL, + forma_extracao smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT constr_extracao_mineral_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX constr_extracao_mineral_a_geom ON edgv.constr_extracao_mineral_a USING gist (geom)# + +ALTER TABLE edgv.constr_extracao_mineral_a OWNER TO postgres# + +ALTER TABLE edgv.constr_extracao_mineral_a + ADD CONSTRAINT constr_extracao_mineral_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_extracao_mineral (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_a + ADD CONSTRAINT constr_extracao_mineral_a_tipo_produto_fk FOREIGN KEY (tipo_produto) + REFERENCES dominios.tipo_produto_residuo (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN tipo_produto SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_a + ADD CONSTRAINT constr_extracao_mineral_a_forma_extracao_fk FOREIGN KEY (forma_extracao) + REFERENCES dominios.forma_extracao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN forma_extracao SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_a + ADD CONSTRAINT constr_extracao_mineral_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_a + ADD CONSTRAINT constr_extracao_mineral_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_a + ADD CONSTRAINT constr_extracao_mineral_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.constr_extracao_mineral_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + tipo_produto smallint NOT NULL, + forma_extracao smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT constr_extracao_mineral_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX constr_extracao_mineral_p_geom ON edgv.constr_extracao_mineral_p USING gist (geom)# + +ALTER TABLE edgv.constr_extracao_mineral_p OWNER TO postgres# + +ALTER TABLE edgv.constr_extracao_mineral_p + ADD CONSTRAINT constr_extracao_mineral_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_extracao_mineral (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_p + ADD CONSTRAINT constr_extracao_mineral_p_tipo_produto_fk FOREIGN KEY (tipo_produto) + REFERENCES dominios.tipo_produto_residuo (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN tipo_produto SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_p + ADD CONSTRAINT constr_extracao_mineral_p_forma_extracao_fk FOREIGN KEY (forma_extracao) + REFERENCES dominios.forma_extracao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN forma_extracao SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_p + ADD CONSTRAINT constr_extracao_mineral_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_p + ADD CONSTRAINT constr_extracao_mineral_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.constr_extracao_mineral_p + ADD CONSTRAINT constr_extracao_mineral_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_curva_nivel_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + cota integer NOT NULL, + indice smallint NOT NULL, + depressao smallint NOT NULL, + dentro_de_massa_dagua smallint NOT NULL, + texto_edicao varchar(255), + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT elemnat_curva_nivel_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_curva_nivel_l_geom ON edgv.elemnat_curva_nivel_l USING gist (geom)# + +ALTER TABLE edgv.elemnat_curva_nivel_l OWNER TO postgres# + +ALTER TABLE edgv.elemnat_curva_nivel_l + ADD CONSTRAINT elemnat_curva_nivel_l_indice_fk FOREIGN KEY (indice) + REFERENCES dominios.indice (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN indice SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_curva_nivel_l + ADD CONSTRAINT elemnat_curva_nivel_l_depressao_fk FOREIGN KEY (depressao) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN depressao SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_curva_nivel_l + ADD CONSTRAINT elemnat_curva_nivel_l_dentro_de_massa_dagua_fk FOREIGN KEY (dentro_de_massa_dagua) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN dentro_de_massa_dagua SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_curva_nivel_l + ADD CONSTRAINT elemnat_curva_nivel_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_elemento_hidrografico_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT elemnat_elemento_hidrografico_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_elemento_hidrografico_a_geom ON edgv.elemnat_elemento_hidrografico_a USING gist (geom)# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a OWNER TO postgres# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a + ADD CONSTRAINT elemnat_elemento_hidrografico_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_hidrografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a + ADD CONSTRAINT elemnat_elemento_hidrografico_a_tipo_check + CHECK (tipo = ANY(ARRAY[6 :: SMALLINT, 12 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a + ADD CONSTRAINT elemnat_elemento_hidrografico_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a + ADD CONSTRAINT elemnat_elemento_hidrografico_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_a ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_elemento_hidrografico_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT elemnat_elemento_hidrografico_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_elemento_hidrografico_l_geom ON edgv.elemnat_elemento_hidrografico_l USING gist (geom)# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l OWNER TO postgres# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l + ADD CONSTRAINT elemnat_elemento_hidrografico_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_hidrografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l + ADD CONSTRAINT elemnat_elemento_hidrografico_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l + ADD CONSTRAINT elemnat_elemento_hidrografico_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_elemento_hidrografico_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT elemnat_elemento_hidrografico_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_elemento_hidrografico_p_geom ON edgv.elemnat_elemento_hidrografico_p USING gist (geom)# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p OWNER TO postgres# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p + ADD CONSTRAINT elemnat_elemento_hidrografico_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_hidrografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p + ADD CONSTRAINT elemnat_elemento_hidrografico_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p + ADD CONSTRAINT elemnat_elemento_hidrografico_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_elemento_hidrografico_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_ilha_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT elemnat_ilha_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_ilha_p_geom ON edgv.elemnat_ilha_p USING gist (geom)# + +ALTER TABLE edgv.elemnat_ilha_p OWNER TO postgres# + +ALTER TABLE edgv.elemnat_ilha_p + ADD CONSTRAINT elemnat_ilha_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_ilha (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ilha_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ilha_p + ADD CONSTRAINT elemnat_ilha_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ilha_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ilha_p + ADD CONSTRAINT elemnat_ilha_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ilha_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_ilha_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT elemnat_ilha_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_ilha_a_geom ON edgv.elemnat_ilha_a USING gist (geom)# + +ALTER TABLE edgv.elemnat_ilha_a OWNER TO postgres# + +ALTER TABLE edgv.elemnat_ilha_a + ADD CONSTRAINT elemnat_ilha_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_ilha (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ilha_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ilha_a + ADD CONSTRAINT elemnat_ilha_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ilha_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ilha_a + ADD CONSTRAINT elemnat_ilha_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ilha_a ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_ponto_cotado_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + cota real NOT NULL, + cota_comprovada smallint NOT NULL, + cota_mais_alta smallint NOT NULL, + label_x real, + label_y real, + visivel smallint NOT NULL, + ancora_horizontal smallint NOT NULL, + ancora_vertical smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT elemnat_ponto_cotado_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_ponto_cotado_p_geom ON edgv.elemnat_ponto_cotado_p USING gist (geom)# + +ALTER TABLE edgv.elemnat_ponto_cotado_p OWNER TO postgres# + +ALTER TABLE edgv.elemnat_ponto_cotado_p + ADD CONSTRAINT elemnat_ponto_cotado_p_cota_comprovada_fk FOREIGN KEY (cota_comprovada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN cota_comprovada SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ponto_cotado_p + ADD CONSTRAINT elemnat_ponto_cotado_p_cota_mais_alta_fk FOREIGN KEY (cota_mais_alta) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN cota_mais_alta SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ponto_cotado_p + ADD CONSTRAINT elemnat_ponto_cotado_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ponto_cotado_p + ADD CONSTRAINT elemnat_ponto_cotado_p_ancora_horizontal_fk FOREIGN KEY (ancora_horizontal) + REFERENCES dominios.ancora_horizontal (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN ancora_horizontal SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_ponto_cotado_p + ADD CONSTRAINT elemnat_ponto_cotado_p_ancora_vertical_fk FOREIGN KEY (ancora_vertical) + REFERENCES dominios.ancora_vertical (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN ancora_vertical SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_terreno_sujeito_inundacao_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT elemnat_terreno_sujeito_inundacao_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_terreno_sujeito_inundacao_a_geom ON edgv.elemnat_terreno_sujeito_inundacao_a USING gist (geom)# + +ALTER TABLE edgv.elemnat_terreno_sujeito_inundacao_a OWNER TO postgres# + +ALTER TABLE edgv.elemnat_terreno_sujeito_inundacao_a + ADD CONSTRAINT elemnat_terreno_sujeito_inundacao_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_terreno_sujeito_inundacao_a ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_toponimo_fisiografico_natural_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + espacamento real, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT elemnat_toponimo_fisiografico_natural_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_toponimo_fisiografico_natural_p_geom ON edgv.elemnat_toponimo_fisiografico_natural_p USING gist (geom)# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p OWNER TO postgres# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p + ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_toponimo_fisiografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p + ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_p_tipo_check + CHECK (tipo = ANY(ARRAY[2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 17 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p + ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p + ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_toponimo_fisiografico_natural_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + tamanho_txt real, + espacamento real, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT elemnat_toponimo_fisiografico_natural_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_toponimo_fisiografico_natural_l_geom ON edgv.elemnat_toponimo_fisiografico_natural_l USING gist (geom)# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l OWNER TO postgres# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l + ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_toponimo_fisiografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l + ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_l_tipo_check + CHECK (tipo = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 12 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l + ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.elemnat_trecho_drenagem_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_em_poligono smallint NOT NULL, + regime smallint NOT NULL, + texto_edicao varchar(255), + tamanho_txt real, + visivel smallint NOT NULL, + posicao_rotulo smallint NOT NULL, + direcao_fixada smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT elemnat_trecho_drenagem_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX elemnat_trecho_drenagem_l_geom ON edgv.elemnat_trecho_drenagem_l USING gist (geom)# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l OWNER TO postgres# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l + ADD CONSTRAINT elemnat_trecho_drenagem_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_trecho_drenagem (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l + ADD CONSTRAINT elemnat_trecho_drenagem_l_situacao_em_poligono_fk FOREIGN KEY (situacao_em_poligono) + REFERENCES dominios.situacao_em_poligono (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN situacao_em_poligono SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l + ADD CONSTRAINT elemnat_trecho_drenagem_l_regime_fk FOREIGN KEY (regime) + REFERENCES dominios.regime (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN regime SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l + ADD CONSTRAINT elemnat_trecho_drenagem_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l + ADD CONSTRAINT elemnat_trecho_drenagem_l_posicao_rotulo_fk FOREIGN KEY (posicao_rotulo) + REFERENCES dominios.posicao_rotulo (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN posicao_rotulo SET DEFAULT 9999# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l + ADD CONSTRAINT elemnat_trecho_drenagem_l_direcao_fixada_fk FOREIGN KEY (direcao_fixada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN direcao_fixada SET DEFAULT 9999# + +CREATE TABLE edgv.infra_barragem_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + material_construcao smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_barragem_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_barragem_l_geom ON edgv.infra_barragem_l USING gist (geom)# + +ALTER TABLE edgv.infra_barragem_l OWNER TO postgres# + +ALTER TABLE edgv.infra_barragem_l + ADD CONSTRAINT infra_barragem_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_barragem (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_barragem_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_barragem_l + ADD CONSTRAINT infra_barragem_l_material_construcao_fk FOREIGN KEY (material_construcao) + REFERENCES dominios.material_construcao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_barragem_l + ADD CONSTRAINT infra_barragem_l_material_construcao_check + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_barragem_l ALTER COLUMN material_construcao SET DEFAULT 9999# + +CREATE TABLE edgv.infra_barragem_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + material_construcao smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT infra_barragem_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_barragem_a_geom ON edgv.infra_barragem_a USING gist (geom)# + +ALTER TABLE edgv.infra_barragem_a OWNER TO postgres# + +ALTER TABLE edgv.infra_barragem_a + ADD CONSTRAINT infra_barragem_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_barragem (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_barragem_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_barragem_a + ADD CONSTRAINT infra_barragem_a_material_construcao_fk FOREIGN KEY (material_construcao) + REFERENCES dominios.material_construcao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_barragem_a + ADD CONSTRAINT infra_barragem_a_material_construcao_check + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_barragem_a ALTER COLUMN material_construcao SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_energia_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT infra_elemento_energia_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_energia_p_geom ON edgv.infra_elemento_energia_p USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_energia_p OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_energia_p + ADD CONSTRAINT infra_elemento_energia_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_energia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_p + ADD CONSTRAINT infra_elemento_energia_p_tipo_check + CHECK (tipo = ANY(ARRAY[1801 :: SMALLINT, 1802 :: SMALLINT, 405 :: SMALLINT, 408 :: SMALLINT, 407 :: SMALLINT, 498 :: SMALLINT, 406 :: SMALLINT, 409 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_p + ADD CONSTRAINT infra_elemento_energia_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_p + ADD CONSTRAINT infra_elemento_energia_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_p + ADD CONSTRAINT infra_elemento_energia_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_energia_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT infra_elemento_energia_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_energia_a_geom ON edgv.infra_elemento_energia_a USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_energia_a OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_energia_a + ADD CONSTRAINT infra_elemento_energia_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_energia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_a + ADD CONSTRAINT infra_elemento_energia_a_tipo_check + CHECK (tipo = ANY(ARRAY[1801 :: SMALLINT, 1802 :: SMALLINT, 405 :: SMALLINT, 408 :: SMALLINT, 407 :: SMALLINT, 498 :: SMALLINT, 406 :: SMALLINT, 409 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_a + ADD CONSTRAINT infra_elemento_energia_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_a + ADD CONSTRAINT infra_elemento_energia_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_a + ADD CONSTRAINT infra_elemento_energia_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_energia_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_elemento_energia_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_energia_l_geom ON edgv.infra_elemento_energia_l USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_energia_l OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_energia_l + ADD CONSTRAINT infra_elemento_energia_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_energia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_l + ADD CONSTRAINT infra_elemento_energia_l_tipo_check + CHECK (tipo = ANY(ARRAY[303 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_elemento_energia_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_l + ADD CONSTRAINT infra_elemento_energia_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_energia_l + ADD CONSTRAINT infra_elemento_energia_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_energia_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_infraestrutura_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT infra_elemento_infraestrutura_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_infraestrutura_a_geom ON edgv.infra_elemento_infraestrutura_a USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a + ADD CONSTRAINT infra_elemento_infraestrutura_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_infraestrutura (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a + ADD CONSTRAINT infra_elemento_infraestrutura_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a + ADD CONSTRAINT infra_elemento_infraestrutura_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a + ADD CONSTRAINT infra_elemento_infraestrutura_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_infraestrutura_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_elemento_infraestrutura_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_infraestrutura_l_geom ON edgv.infra_elemento_infraestrutura_l USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l + ADD CONSTRAINT infra_elemento_infraestrutura_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_infraestrutura (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l + ADD CONSTRAINT infra_elemento_infraestrutura_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l + ADD CONSTRAINT infra_elemento_infraestrutura_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l + ADD CONSTRAINT infra_elemento_infraestrutura_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_elemento_infraestrutura_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT infra_elemento_infraestrutura_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_elemento_infraestrutura_p_geom ON edgv.infra_elemento_infraestrutura_p USING gist (geom)# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p OWNER TO postgres# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p + ADD CONSTRAINT infra_elemento_infraestrutura_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_infraestrutura (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p + ADD CONSTRAINT infra_elemento_infraestrutura_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p + ADD CONSTRAINT infra_elemento_infraestrutura_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p + ADD CONSTRAINT infra_elemento_infraestrutura_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_ferrovia_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + situacao_fisica smallint NOT NULL, + posicao_relativa smallint NOT NULL, + nr_linhas smallint NOT NULL, + eletrificada smallint NOT NULL, + bitola smallint NOT NULL, + em_arruamento smallint NOT NULL, + jurisdicao smallint NOT NULL, + administracao smallint NOT NULL, + concessionaria varchar(255), + texto_edicao varchar(255), + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_ferrovia_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_ferrovia_l_geom ON edgv.infra_ferrovia_l USING gist (geom)# + +ALTER TABLE edgv.infra_ferrovia_l OWNER TO postgres# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_ferrovia (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_posicao_relativa_fk FOREIGN KEY (posicao_relativa) + REFERENCES dominios.posicao_relativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN posicao_relativa SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_nr_linhas_fk FOREIGN KEY (nr_linhas) + REFERENCES dominios.nr_linhas (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN nr_linhas SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_eletrificada_fk FOREIGN KEY (eletrificada) + REFERENCES dominios.auxiliar (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN eletrificada SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_bitola_fk FOREIGN KEY (bitola) + REFERENCES dominios.bitola (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN bitola SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_em_arruamento_fk FOREIGN KEY (em_arruamento) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN em_arruamento SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_jurisdicao_fk FOREIGN KEY (jurisdicao) + REFERENCES dominios.jurisdicao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN jurisdicao SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_administracao_fk FOREIGN KEY (administracao) + REFERENCES dominios.administracao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN administracao SET DEFAULT 9999# + +ALTER TABLE edgv.infra_ferrovia_l + ADD CONSTRAINT infra_ferrovia_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.infra_pista_pouso_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + revestimento smallint NOT NULL, + uso_pista smallint NOT NULL, + situacao_fisica smallint NOT NULL, + altitude real, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT infra_pista_pouso_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_pista_pouso_a_geom ON edgv.infra_pista_pouso_a USING gist (geom)# + +ALTER TABLE edgv.infra_pista_pouso_a OWNER TO postgres# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_pista_pouso (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_tipo_check + CHECK (tipo = ANY(ARRAY[9 :: SMALLINT, 10 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_revestimento_fk FOREIGN KEY (revestimento) + REFERENCES dominios.revestimento (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_revestimento_check + CHECK (revestimento = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN revestimento SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_uso_pista_fk FOREIGN KEY (uso_pista) + REFERENCES dominios.uso_pista (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN uso_pista SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_a + ADD CONSTRAINT infra_pista_pouso_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.infra_pista_pouso_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + revestimento smallint NOT NULL, + uso_pista smallint NOT NULL, + situacao_fisica smallint NOT NULL, + altitude real, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_pista_pouso_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_pista_pouso_l_geom ON edgv.infra_pista_pouso_l USING gist (geom)# + +ALTER TABLE edgv.infra_pista_pouso_l OWNER TO postgres# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_pista_pouso (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_tipo_check + CHECK (tipo = ANY(ARRAY[9 :: SMALLINT, 10 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_revestimento_fk FOREIGN KEY (revestimento) + REFERENCES dominios.revestimento (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_revestimento_check + CHECK (revestimento = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN revestimento SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_uso_pista_fk FOREIGN KEY (uso_pista) + REFERENCES dominios.uso_pista (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN uso_pista SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_l + ADD CONSTRAINT infra_pista_pouso_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.infra_pista_pouso_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + revestimento smallint NOT NULL, + uso_pista smallint NOT NULL, + situacao_fisica smallint NOT NULL, + altitude real, + visivel smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + simb_rot real, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT infra_pista_pouso_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_pista_pouso_p_geom ON edgv.infra_pista_pouso_p USING gist (geom)# + +ALTER TABLE edgv.infra_pista_pouso_p OWNER TO postgres# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_pista_pouso (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_tipo_check + CHECK (tipo = ANY(ARRAY[9 :: SMALLINT, 11 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_revestimento_fk FOREIGN KEY (revestimento) + REFERENCES dominios.revestimento (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_revestimento_check + CHECK (revestimento = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN revestimento SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_uso_pista_fk FOREIGN KEY (uso_pista) + REFERENCES dominios.uso_pista (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN uso_pista SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.infra_pista_pouso_p + ADD CONSTRAINT infra_pista_pouso_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.infra_via_deslocamento_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + revestimento smallint NOT NULL, + trafego smallint NOT NULL, + nr_faixas varchar(255), + nr_pistas varchar(255), + canteiro_divisorio smallint NOT NULL, + situacao_fisica smallint NOT NULL, + jurisdicao smallint NOT NULL, + sigla varchar(255), + administracao smallint NOT NULL, + concessionaria varchar(255), + texto_edicao varchar(255), + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT infra_via_deslocamento_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX infra_via_deslocamento_l_geom ON edgv.infra_via_deslocamento_l USING gist (geom)# + +ALTER TABLE edgv.infra_via_deslocamento_l OWNER TO postgres# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_via_deslocamento (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_revestimento_fk FOREIGN KEY (revestimento) + REFERENCES dominios.revestimento (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_revestimento_check + CHECK (revestimento = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN revestimento SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_trafego_fk FOREIGN KEY (trafego) + REFERENCES dominios.trafego (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN trafego SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_canteiro_divisorio_fk FOREIGN KEY (canteiro_divisorio) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN canteiro_divisorio SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) + REFERENCES dominios.situacao_fisica (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_jurisdicao_fk FOREIGN KEY (jurisdicao) + REFERENCES dominios.jurisdicao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN jurisdicao SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_administracao_fk FOREIGN KEY (administracao) + REFERENCES dominios.administracao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_administracao_check + CHECK (administracao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 7 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN administracao SET DEFAULT 9999# + +ALTER TABLE edgv.infra_via_deslocamento_l + ADD CONSTRAINT infra_via_deslocamento_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.llp_aglomerado_rural_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT llp_aglomerado_rural_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX llp_aglomerado_rural_p_geom ON edgv.llp_aglomerado_rural_p USING gist (geom)# + +ALTER TABLE edgv.llp_aglomerado_rural_p OWNER TO postgres# + +ALTER TABLE edgv.llp_aglomerado_rural_p + ADD CONSTRAINT llp_aglomerado_rural_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_localidade (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_aglomerado_rural_p + ADD CONSTRAINT llp_aglomerado_rural_p_tipo_check + CHECK (tipo = ANY(ARRAY[5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.llp_aglomerado_rural_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.llp_aglomerado_rural_p + ADD CONSTRAINT llp_aglomerado_rural_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_aglomerado_rural_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.llp_aglomerado_rural_p + ADD CONSTRAINT llp_aglomerado_rural_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_aglomerado_rural_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.llp_area_pub_militar_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + geometria_aproximada smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT llp_area_pub_militar_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX llp_area_pub_militar_a_geom ON edgv.llp_area_pub_militar_a USING gist (geom)# + +ALTER TABLE edgv.llp_area_pub_militar_a OWNER TO postgres# + +ALTER TABLE edgv.llp_area_pub_militar_a + ADD CONSTRAINT llp_area_pub_militar_a_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_area_pub_militar_a ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +ALTER TABLE edgv.llp_area_pub_militar_a + ADD CONSTRAINT llp_area_pub_militar_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_area_pub_militar_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.llp_area_pub_militar_a + ADD CONSTRAINT llp_area_pub_militar_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_area_pub_militar_a ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.llp_localidade_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + populacao integer, + texto_edicao varchar(255), + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT llp_localidade_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX llp_localidade_p_geom ON edgv.llp_localidade_p USING gist (geom)# + +ALTER TABLE edgv.llp_localidade_p OWNER TO postgres# + +ALTER TABLE edgv.llp_localidade_p + ADD CONSTRAINT llp_localidade_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_localidade (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_localidade_p + ADD CONSTRAINT llp_localidade_p_tipo_check + CHECK (tipo = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.llp_localidade_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.llp_localidade_p + ADD CONSTRAINT llp_localidade_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_localidade_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.llp_localidade_p + ADD CONSTRAINT llp_localidade_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_localidade_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.llp_nome_local_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + texto_edicao varchar(255), + visivel smallint NOT NULL, + label_x real, + label_y real, + justificativa_txt smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT llp_nome_local_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX llp_nome_local_p_geom ON edgv.llp_nome_local_p USING gist (geom)# + +ALTER TABLE edgv.llp_nome_local_p OWNER TO postgres# + +ALTER TABLE edgv.llp_nome_local_p + ADD CONSTRAINT llp_nome_local_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_nome_local_p ALTER COLUMN visivel SET DEFAULT 9999# + +ALTER TABLE edgv.llp_nome_local_p + ADD CONSTRAINT llp_nome_local_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_nome_local_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.llp_terra_indigena_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + geometria_aproximada smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT llp_terra_indigena_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX llp_terra_indigena_a_geom ON edgv.llp_terra_indigena_a USING gist (geom)# + +ALTER TABLE edgv.llp_terra_indigena_a OWNER TO postgres# + +ALTER TABLE edgv.llp_terra_indigena_a + ADD CONSTRAINT llp_terra_indigena_a_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_terra_indigena_a ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +ALTER TABLE edgv.llp_terra_indigena_a + ADD CONSTRAINT llp_terra_indigena_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_terra_indigena_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.llp_terra_indigena_a + ADD CONSTRAINT llp_terra_indigena_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_terra_indigena_a ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.llp_unidade_conservacao_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + geometria_aproximada smallint NOT NULL, + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT llp_unidade_conservacao_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX llp_unidade_conservacao_a_geom ON edgv.llp_unidade_conservacao_a USING gist (geom)# + +ALTER TABLE edgv.llp_unidade_conservacao_a OWNER TO postgres# + +ALTER TABLE edgv.llp_unidade_conservacao_a + ADD CONSTRAINT llp_unidade_conservacao_a_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_limite_especial (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_unidade_conservacao_a + ADD CONSTRAINT llp_unidade_conservacao_a_tipo_check + CHECK (tipo = ANY(ARRAY[5 :: SMALLINT, 24 :: SMALLINT, 25 :: SMALLINT, 26 :: SMALLINT, 27 :: SMALLINT, 28 :: SMALLINT, 29 :: SMALLINT, 30 :: SMALLINT, 31 :: SMALLINT, 32 :: SMALLINT, 33 :: SMALLINT, 34 :: SMALLINT, 35 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.llp_unidade_conservacao_a ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.llp_unidade_conservacao_a + ADD CONSTRAINT llp_unidade_conservacao_a_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_unidade_conservacao_a ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +ALTER TABLE edgv.llp_unidade_conservacao_a + ADD CONSTRAINT llp_unidade_conservacao_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_unidade_conservacao_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +ALTER TABLE edgv.llp_unidade_conservacao_a + ADD CONSTRAINT llp_unidade_conservacao_a_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_unidade_conservacao_a ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.llp_unidade_federacao_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + sigla varchar(255), + geometria_aproximada smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT llp_unidade_federacao_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX llp_unidade_federacao_a_geom ON edgv.llp_unidade_federacao_a USING gist (geom)# + +ALTER TABLE edgv.llp_unidade_federacao_a OWNER TO postgres# + +ALTER TABLE edgv.llp_unidade_federacao_a + ADD CONSTRAINT llp_unidade_federacao_a_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.llp_unidade_federacao_a ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_area_pub_militar_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + geometria_aproximada smallint NOT NULL, + sobreposto smallint NOT NULL, + exibir_rotulo_aproximado smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT edicao_area_pub_militar_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_area_pub_militar_l_geom ON edgv.edicao_area_pub_militar_l USING gist (geom)# + +ALTER TABLE edgv.edicao_area_pub_militar_l OWNER TO postgres# + +ALTER TABLE edgv.edicao_area_pub_militar_l + ADD CONSTRAINT edicao_area_pub_militar_l_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_area_pub_militar_l ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_area_pub_militar_l + ADD CONSTRAINT edicao_area_pub_militar_l_sobreposto_fk FOREIGN KEY (sobreposto) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_area_pub_militar_l ALTER COLUMN sobreposto SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_area_pub_militar_l + ADD CONSTRAINT edicao_area_pub_militar_l_exibir_rotulo_aproximado_fk FOREIGN KEY (exibir_rotulo_aproximado) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_area_pub_militar_l ALTER COLUMN exibir_rotulo_aproximado SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_area_pub_militar_l + ADD CONSTRAINT edicao_area_pub_militar_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_area_pub_militar_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_terra_indigena_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + geometria_aproximada smallint NOT NULL, + sobreposto smallint NOT NULL, + exibir_rotulo_aproximado smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT edicao_terra_indigena_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_terra_indigena_l_geom ON edgv.edicao_terra_indigena_l USING gist (geom)# + +ALTER TABLE edgv.edicao_terra_indigena_l OWNER TO postgres# + +ALTER TABLE edgv.edicao_terra_indigena_l + ADD CONSTRAINT edicao_terra_indigena_l_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_terra_indigena_l ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_terra_indigena_l + ADD CONSTRAINT edicao_terra_indigena_l_sobreposto_fk FOREIGN KEY (sobreposto) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_terra_indigena_l ALTER COLUMN sobreposto SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_terra_indigena_l + ADD CONSTRAINT edicao_terra_indigena_l_exibir_rotulo_aproximado_fk FOREIGN KEY (exibir_rotulo_aproximado) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_terra_indigena_l ALTER COLUMN exibir_rotulo_aproximado SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_terra_indigena_l + ADD CONSTRAINT edicao_terra_indigena_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_terra_indigena_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_unidade_conservacao_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + geometria_aproximada smallint NOT NULL, + sobreposto smallint NOT NULL, + exibir_rotulo_aproximado smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT edicao_unidade_conservacao_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_unidade_conservacao_l_geom ON edgv.edicao_unidade_conservacao_l USING gist (geom)# + +ALTER TABLE edgv.edicao_unidade_conservacao_l OWNER TO postgres# + +ALTER TABLE edgv.edicao_unidade_conservacao_l + ADD CONSTRAINT edicao_unidade_conservacao_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_limite_especial (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_unidade_conservacao_l + ADD CONSTRAINT edicao_unidade_conservacao_l_tipo_check + CHECK (tipo = ANY(ARRAY[5 :: SMALLINT, 24 :: SMALLINT, 25 :: SMALLINT, 26 :: SMALLINT, 27 :: SMALLINT, 28 :: SMALLINT, 29 :: SMALLINT, 30 :: SMALLINT, 31 :: SMALLINT, 32 :: SMALLINT, 33 :: SMALLINT, 34 :: SMALLINT, 35 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edicao_unidade_conservacao_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_unidade_conservacao_l + ADD CONSTRAINT edicao_unidade_conservacao_l_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_unidade_conservacao_l ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_unidade_conservacao_l + ADD CONSTRAINT edicao_unidade_conservacao_l_sobreposto_fk FOREIGN KEY (sobreposto) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_unidade_conservacao_l ALTER COLUMN sobreposto SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_unidade_conservacao_l + ADD CONSTRAINT edicao_unidade_conservacao_l_exibir_rotulo_aproximado_fk FOREIGN KEY (exibir_rotulo_aproximado) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_unidade_conservacao_l ALTER COLUMN exibir_rotulo_aproximado SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_unidade_conservacao_l + ADD CONSTRAINT edicao_unidade_conservacao_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_unidade_conservacao_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_limite_legal_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + geometria_aproximada smallint NOT NULL, + texto_edicao varchar(255), + sobreposto smallint NOT NULL, + exibir_rotulo_aproximado smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT edicao_limite_legal_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_limite_legal_l_geom ON edgv.edicao_limite_legal_l USING gist (geom)# + +ALTER TABLE edgv.edicao_limite_legal_l OWNER TO postgres# + +ALTER TABLE edgv.edicao_limite_legal_l + ADD CONSTRAINT edicao_limite_legal_l_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_limite_legal (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_limite_legal_l + ADD CONSTRAINT edicao_limite_legal_l_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_limite_legal_l + ADD CONSTRAINT edicao_limite_legal_l_sobreposto_fk FOREIGN KEY (sobreposto) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN sobreposto SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_limite_legal_l + ADD CONSTRAINT edicao_limite_legal_l_exibir_rotulo_aproximado_fk FOREIGN KEY (exibir_rotulo_aproximado) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN exibir_rotulo_aproximado SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_limite_legal_l + ADD CONSTRAINT edicao_limite_legal_l_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_grid_edicao_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT edicao_grid_edicao_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_grid_edicao_l_geom ON edgv.edicao_grid_edicao_l USING gist (geom)# + +ALTER TABLE edgv.edicao_grid_edicao_l OWNER TO postgres# + +CREATE TABLE edgv.edicao_articulacao_imagem_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome_sensor varchar(255), + nome_abrev_sensor varchar(255), + data varchar(255), + tipo varchar(255), + plataforma varchar(255), + resolucao varchar(255), + bandas varchar(255), + nivel_produto varchar(255), + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT edicao_articulacao_imagem_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_articulacao_imagem_a_geom ON edgv.edicao_articulacao_imagem_a USING gist (geom)# + +ALTER TABLE edgv.edicao_articulacao_imagem_a OWNER TO postgres# + +CREATE TABLE edgv.edicao_area_sem_dados_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + texto_edicao varchar(255), + label_x real, + label_y real, + tamanho_txt real, + justificativa_txt smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT edicao_area_sem_dados_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_area_sem_dados_a_geom ON edgv.edicao_area_sem_dados_a USING gist (geom)# + +ALTER TABLE edgv.edicao_area_sem_dados_a OWNER TO postgres# + +ALTER TABLE edgv.edicao_area_sem_dados_a + ADD CONSTRAINT edicao_area_sem_dados_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_area_sem_dados_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.delimitador_area_sem_dados_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT delimitador_area_sem_dados_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX delimitador_area_sem_dados_l_geom ON edgv.delimitador_area_sem_dados_l USING gist (geom)# + +ALTER TABLE edgv.delimitador_area_sem_dados_l OWNER TO postgres# + +CREATE TABLE edgv.aux_validacao_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + subfase_id integer, + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT aux_validacao_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_validacao_a_geom ON edgv.aux_validacao_a USING gist (geom)# + +ALTER TABLE edgv.aux_validacao_a OWNER TO postgres# + +CREATE TABLE edgv.aux_validacao_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + subfase_id integer, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT aux_validacao_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_validacao_l_geom ON edgv.aux_validacao_l USING gist (geom)# + +ALTER TABLE edgv.aux_validacao_l OWNER TO postgres# + +CREATE TABLE edgv.aux_validacao_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + subfase_id integer, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT aux_validacao_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_validacao_p_geom ON edgv.aux_validacao_p USING gist (geom)# + +ALTER TABLE edgv.aux_validacao_p OWNER TO postgres# + +CREATE TABLE edgv.aux_revisao_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + subfase_id integer, + corrigido smallint NOT NULL, + justificativa varchar(255), + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT aux_revisao_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_revisao_a_geom ON edgv.aux_revisao_a USING gist (geom)# + +ALTER TABLE edgv.aux_revisao_a OWNER TO postgres# + +ALTER TABLE edgv.aux_revisao_a + ADD CONSTRAINT aux_revisao_a_corrigido_fk FOREIGN KEY (corrigido) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.aux_revisao_a ALTER COLUMN corrigido SET DEFAULT 9999# + +CREATE TABLE edgv.aux_revisao_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + subfase_id integer, + corrigido smallint NOT NULL, + justificativa varchar(255), + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT aux_revisao_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_revisao_l_geom ON edgv.aux_revisao_l USING gist (geom)# + +ALTER TABLE edgv.aux_revisao_l OWNER TO postgres# + +ALTER TABLE edgv.aux_revisao_l + ADD CONSTRAINT aux_revisao_l_corrigido_fk FOREIGN KEY (corrigido) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.aux_revisao_l ALTER COLUMN corrigido SET DEFAULT 9999# + +CREATE TABLE edgv.aux_revisao_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + descricao varchar(255), + subfase_id integer, + corrigido smallint NOT NULL, + justificativa varchar(255), + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT aux_revisao_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_revisao_p_geom ON edgv.aux_revisao_p USING gist (geom)# + +ALTER TABLE edgv.aux_revisao_p OWNER TO postgres# + +ALTER TABLE edgv.aux_revisao_p + ADD CONSTRAINT aux_revisao_p_corrigido_fk FOREIGN KEY (corrigido) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.aux_revisao_p ALTER COLUMN corrigido SET DEFAULT 9999# + +CREATE TABLE edgv.aux_moldura_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + mi varchar(255), + inom varchar(255), + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT aux_moldura_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_moldura_a_geom ON edgv.aux_moldura_a USING gist (geom)# + +ALTER TABLE edgv.aux_moldura_a OWNER TO postgres# + +CREATE TABLE edgv.aux_moldura_area_continua_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT aux_moldura_area_continua_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_moldura_area_continua_a_geom ON edgv.aux_moldura_area_continua_a USING gist (geom)# + +ALTER TABLE edgv.aux_moldura_area_continua_a OWNER TO postgres# + +CREATE TABLE edgv.delimitador_massa_dagua_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT delimitador_massa_dagua_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX delimitador_massa_dagua_l_geom ON edgv.delimitador_massa_dagua_l USING gist (geom)# + +ALTER TABLE edgv.delimitador_massa_dagua_l OWNER TO postgres# + +CREATE TABLE edgv.delimitador_elemento_hidrografico_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT delimitador_elemento_hidrografico_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX delimitador_elemento_hidrografico_l_geom ON edgv.delimitador_elemento_hidrografico_l USING gist (geom)# + +ALTER TABLE edgv.delimitador_elemento_hidrografico_l OWNER TO postgres# + +CREATE TABLE edgv.centroide_massa_dagua_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + regime smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT centroide_massa_dagua_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX centroide_massa_dagua_p_geom ON edgv.centroide_massa_dagua_p USING gist (geom)# + +ALTER TABLE edgv.centroide_massa_dagua_p OWNER TO postgres# + +ALTER TABLE edgv.centroide_massa_dagua_p + ADD CONSTRAINT centroide_massa_dagua_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_massa_dagua (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_massa_dagua_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.centroide_massa_dagua_p + ADD CONSTRAINT centroide_massa_dagua_p_regime_fk FOREIGN KEY (regime) + REFERENCES dominios.regime (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_massa_dagua_p ALTER COLUMN regime SET DEFAULT 9999# + +CREATE TABLE edgv.centroide_ilha_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT centroide_ilha_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX centroide_ilha_p_geom ON edgv.centroide_ilha_p USING gist (geom)# + +ALTER TABLE edgv.centroide_ilha_p OWNER TO postgres# + +ALTER TABLE edgv.centroide_ilha_p + ADD CONSTRAINT centroide_ilha_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_ilha (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_ilha_p ALTER COLUMN tipo SET DEFAULT 9999# + +CREATE TABLE edgv.centroide_elemento_hidrografico_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT centroide_elemento_hidrografico_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX centroide_elemento_hidrografico_p_geom ON edgv.centroide_elemento_hidrografico_p USING gist (geom)# + +ALTER TABLE edgv.centroide_elemento_hidrografico_p OWNER TO postgres# + +ALTER TABLE edgv.centroide_elemento_hidrografico_p + ADD CONSTRAINT centroide_elemento_hidrografico_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_elemento_hidrografico (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_elemento_hidrografico_p + ADD CONSTRAINT centroide_elemento_hidrografico_p_tipo_check + CHECK (tipo = ANY(ARRAY[6 :: SMALLINT, 12 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.centroide_elemento_hidrografico_p ALTER COLUMN tipo SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_identificador_trecho_rod_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + sigla varchar(255), + tipo smallint NOT NULL, + jurisdicao smallint NOT NULL, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT edicao_identificador_trecho_rod_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_identificador_trecho_rod_p_geom ON edgv.edicao_identificador_trecho_rod_p USING gist (geom)# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p OWNER TO postgres# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p + ADD CONSTRAINT edicao_identificador_trecho_rod_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_via_deslocamento (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p + ADD CONSTRAINT edicao_identificador_trecho_rod_p_jurisdicao_fk FOREIGN KEY (jurisdicao) + REFERENCES dominios.jurisdicao (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p + ADD CONSTRAINT edicao_identificador_trecho_rod_p_jurisdicao_check + CHECK (jurisdicao = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT]))# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p ALTER COLUMN jurisdicao SET DEFAULT 9999# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p + ADD CONSTRAINT edicao_identificador_trecho_rod_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_simb_torre_energia_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + simb_rot real, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT edicao_simb_torre_energia_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_simb_torre_energia_p_geom ON edgv.edicao_simb_torre_energia_p USING gist (geom)# + +ALTER TABLE edgv.edicao_simb_torre_energia_p OWNER TO postgres# + +ALTER TABLE edgv.edicao_simb_torre_energia_p + ADD CONSTRAINT edicao_simb_torre_energia_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_simb_torre_energia_p ALTER COLUMN visivel SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_simb_cota_mestra_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + texto_edicao varchar(255), + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT edicao_simb_cota_mestra_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_simb_cota_mestra_l_geom ON edgv.edicao_simb_cota_mestra_l USING gist (geom)# + +ALTER TABLE edgv.edicao_simb_cota_mestra_l OWNER TO postgres# + +CREATE TABLE edgv.edicao_texto_generico_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + texto_edicao varchar(255), + label_x real, + label_y real, + estilo_fonte varchar(255), + tamanho_txt real, + justificativa_txt smallint NOT NULL, + espacamento real, + cor varchar(255), + cor_buffer varchar(255), + tamanho_buffer real, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT edicao_texto_generico_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_texto_generico_p_geom ON edgv.edicao_texto_generico_p USING gist (geom)# + +ALTER TABLE edgv.edicao_texto_generico_p OWNER TO postgres# + +ALTER TABLE edgv.edicao_texto_generico_p + ADD CONSTRAINT edicao_texto_generico_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) + REFERENCES dominios.justificativa (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_texto_generico_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# + +CREATE TABLE edgv.edicao_texto_generico_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + texto_edicao varchar(255), + estilo_fonte varchar(255), + tamanho_txt real, + espacamento real, + cor varchar(255), + cor_buffer varchar(255), + tamanho_buffer real, + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT edicao_texto_generico_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_texto_generico_l_geom ON edgv.edicao_texto_generico_l USING gist (geom)# + +ALTER TABLE edgv.edicao_texto_generico_l OWNER TO postgres# + +CREATE TABLE edgv.delimitador_limite_especial_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT delimitador_limite_especial_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX delimitador_limite_especial_l_geom ON edgv.delimitador_limite_especial_l USING gist (geom)# + +ALTER TABLE edgv.delimitador_limite_especial_l OWNER TO postgres# + +CREATE TABLE edgv.centroide_area_sem_dados_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT centroide_area_sem_dados_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX centroide_area_sem_dados_p_geom ON edgv.centroide_area_sem_dados_p USING gist (geom)# + +ALTER TABLE edgv.centroide_area_sem_dados_p OWNER TO postgres# + +CREATE TABLE edgv.centroide_limite_especial_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + tipo smallint NOT NULL, + geometria_aproximada smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT centroide_limite_especial_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX centroide_limite_especial_p_geom ON edgv.centroide_limite_especial_p USING gist (geom)# + +ALTER TABLE edgv.centroide_limite_especial_p OWNER TO postgres# + +ALTER TABLE edgv.centroide_limite_especial_p + ADD CONSTRAINT centroide_limite_especial_p_tipo_fk FOREIGN KEY (tipo) + REFERENCES dominios.tipo_limite_especial (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_limite_especial_p ALTER COLUMN tipo SET DEFAULT 9999# + +ALTER TABLE edgv.centroide_limite_especial_p + ADD CONSTRAINT centroide_limite_especial_p_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.centroide_limite_especial_p ALTER COLUMN geometria_aproximada SET DEFAULT 9999# + +CREATE TABLE edgv.aux_insumo_externo_a( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + fonte varchar(255), + observacao VARCHAR(255), + geom geometry(MultiPolygon, [epsg]), + CONSTRAINT aux_insumo_externo_a_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_insumo_externo_a_geom ON edgv.aux_insumo_externo_a USING gist (geom)# + +ALTER TABLE edgv.aux_insumo_externo_a OWNER TO postgres# + +CREATE TABLE edgv.aux_insumo_externo_l( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + fonte varchar(255), + observacao VARCHAR(255), + geom geometry(MultiLinestring, [epsg]), + CONSTRAINT aux_insumo_externo_l_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_insumo_externo_l_geom ON edgv.aux_insumo_externo_l USING gist (geom)# + +ALTER TABLE edgv.aux_insumo_externo_l OWNER TO postgres# + +CREATE TABLE edgv.aux_insumo_externo_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + nome varchar(255), + fonte varchar(255), + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT aux_insumo_externo_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX aux_insumo_externo_p_geom ON edgv.aux_insumo_externo_p USING gist (geom)# + +ALTER TABLE edgv.aux_insumo_externo_p OWNER TO postgres# + +CREATE TABLE edgv.edicao_ponto_mudanca_p( + id uuid NOT NULL DEFAULT uuid_generate_v4(), + simb_rot real, + desloc real, + visivel smallint NOT NULL, + observacao VARCHAR(255), + geom geometry(MultiPoint, [epsg]), + CONSTRAINT edicao_ponto_mudanca_p_pk PRIMARY KEY (id) + WITH (FILLFACTOR = 80) +)# +CREATE INDEX edicao_ponto_mudanca_p_geom ON edgv.edicao_ponto_mudanca_p USING gist (geom)# + +ALTER TABLE edgv.edicao_ponto_mudanca_p OWNER TO postgres# + +ALTER TABLE edgv.edicao_ponto_mudanca_p + ADD CONSTRAINT edicao_ponto_mudanca_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION# + +ALTER TABLE edgv.edicao_ponto_mudanca_p ALTER COLUMN visivel SET DEFAULT 9999# \ No newline at end of file diff --git a/DsgTools/core/DbModels/PostGIS/3_Pro/edgv3_pro.sql b/DsgTools/core/DbModels/PostGIS/3_Pro/edgv3_pro.sql index 6f98cf2f8..8c8c7f50b 100644 --- a/DsgTools/core/DbModels/PostGIS/3_Pro/edgv3_pro.sql +++ b/DsgTools/core/DbModels/PostGIS/3_Pro/edgv3_pro.sql @@ -1,1400 +1,1400 @@ -CREATE SCHEMA edgv# -CREATE SCHEMA dominios# +CREATE SCHEMA edgv; +CREATE SCHEMA dominios; -CREATE EXTENSION postgis# -CREATE EXTENSION IF NOT EXISTS "uuid-ossp"# -SET search_path TO pg_catalog,public,edgv,dominios# +CREATE EXTENSION postgis; +CREATE EXTENSION IF NOT EXISTS "uuid-ossp"; +SET search_path TO pg_catalog,public,edgv,dominios; CREATE TABLE public.db_metadata( edgvversion varchar(50) NOT NULL DEFAULT 'EDGV 3.0 Pro', - dbimplversion varchar(50) NOT NULL DEFAULT '1.3.1', + dbimplversion varchar(50) NOT NULL DEFAULT '1.3.2', CONSTRAINT edgvversioncheck CHECK (edgvversion = 'EDGV 3.0 Pro') -)# -INSERT INTO public.db_metadata (edgvversion, dbimplversion) VALUES ('EDGV 3.0 Pro','1.3.1')# +); +INSERT INTO public.db_metadata (edgvversion, dbimplversion) VALUES ('EDGV 3.0 Pro','1.3.2'); CREATE TABLE dominios.exibir_lado_simbologia ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT exibir_lado_simbologia_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.exibir_lado_simbologia (code,code_name) VALUES (1,'Exibir ambos os lados (1)')# -INSERT INTO dominios.exibir_lado_simbologia (code,code_name) VALUES (2,'Exibir lado esquerdo (2)')# -INSERT INTO dominios.exibir_lado_simbologia (code,code_name) VALUES (3,'Exibir lado direito (3)')# -INSERT INTO dominios.exibir_lado_simbologia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.exibir_lado_simbologia (code,code_name) VALUES (1,'Exibir ambos os lados (1)'); +INSERT INTO dominios.exibir_lado_simbologia (code,code_name) VALUES (2,'Exibir lado esquerdo (2)'); +INSERT INTO dominios.exibir_lado_simbologia (code,code_name) VALUES (3,'Exibir lado direito (3)'); +INSERT INTO dominios.exibir_lado_simbologia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.exibir_lado_simbologia OWNER TO postgres# +ALTER TABLE dominios.exibir_lado_simbologia OWNER TO postgres; CREATE TABLE dominios.exibir_ponta_simbologia ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT exibir_ponta_simbologia_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.exibir_ponta_simbologia (code,code_name) VALUES (1,'Exibir ambos as pontas (1)')# -INSERT INTO dominios.exibir_ponta_simbologia (code,code_name) VALUES (2,'Exibir ponta inicial (2)')# -INSERT INTO dominios.exibir_ponta_simbologia (code,code_name) VALUES (3,'Exibir ponta final (3)')# -INSERT INTO dominios.exibir_ponta_simbologia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.exibir_ponta_simbologia (code,code_name) VALUES (1,'Exibir ambos as pontas (1)'); +INSERT INTO dominios.exibir_ponta_simbologia (code,code_name) VALUES (2,'Exibir ponta inicial (2)'); +INSERT INTO dominios.exibir_ponta_simbologia (code,code_name) VALUES (3,'Exibir ponta final (3)'); +INSERT INTO dominios.exibir_ponta_simbologia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.exibir_ponta_simbologia OWNER TO postgres# +ALTER TABLE dominios.exibir_ponta_simbologia OWNER TO postgres; CREATE TABLE dominios.tipo_area_uso_especifico ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_area_uso_especifico_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (1,'Área de propriedade particular (1)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (2,'Área habitacional (2)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (3,'Área relacionada a dutos (3)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (4,'Área relacionada a edificação agropecuária ou extrativismo vegetal ou pesca (4)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (5,'Área relacionada a edificação de comércio ou serviços (5)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (6,'Área relacinada a edificação de ensino (6)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (7,'Área relacionada a edificação de saúde (7)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (8,'Área relacionada a edificação industrial (8)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (9,'Área relacionada a edificação religiosa (9)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (10,'Área relacionada a energia elétrica (10)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (11,'Área relacionada a equipamentos de desenvolvimento social (11)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (12,'Área relacionada a estação de medição de fenômenos (12)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (13,'Área relacionada ao extrativismo mineral (13)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (14,'Área relacionada a instalação de abastecimento de água (14)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (15,'Área relacionada a instalação de comunicações (15)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (16,'Área relacionada a instalação de estrutura de transporte (16)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (17,'Área relacionada a instalação de saneamento (17)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (18,'Área relacionada ao lazer (18)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (19,'Área relacionada a ruinas de valor histórico (19)')# -INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_area_uso_especifico OWNER TO postgres# +); + +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (1,'Área de propriedade particular (1)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (2,'Área habitacional (2)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (3,'Área relacionada a dutos (3)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (4,'Área relacionada a edificação agropecuária ou extrativismo vegetal ou pesca (4)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (5,'Área relacionada a edificação de comércio ou serviços (5)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (6,'Área relacinada a edificação de ensino (6)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (7,'Área relacionada a edificação de saúde (7)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (8,'Área relacionada a edificação industrial (8)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (9,'Área relacionada a edificação religiosa (9)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (10,'Área relacionada a energia elétrica (10)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (11,'Área relacionada a equipamentos de desenvolvimento social (11)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (12,'Área relacionada a estação de medição de fenômenos (12)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (13,'Área relacionada ao extrativismo mineral (13)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (14,'Área relacionada a instalação de abastecimento de água (14)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (15,'Área relacionada a instalação de comunicações (15)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (16,'Área relacionada a instalação de estrutura de transporte (16)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (17,'Área relacionada a instalação de saneamento (17)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (18,'Área relacionada ao lazer (18)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (19,'Área relacionada a ruinas de valor histórico (19)'); +INSERT INTO dominios.tipo_area_uso_especifico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_area_uso_especifico OWNER TO postgres; CREATE TABLE dominios.ancora_horizontal ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT ancora_horizontal_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (1,'Esquerda (1)')# -INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (2,'Centro (2)')# -INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (3,'Direita (3)')# -INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (1,'Esquerda (1)'); +INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (2,'Centro (2)'); +INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (3,'Direita (3)'); +INSERT INTO dominios.ancora_horizontal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.ancora_horizontal OWNER TO postgres# +ALTER TABLE dominios.ancora_horizontal OWNER TO postgres; CREATE TABLE dominios.ancora_vertical ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT ancora_vertical_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (1,'Inferior (1)')# -INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (2,'Meio (2)')# -INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (3,'Superior (3)')# -INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (1,'Inferior (1)'); +INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (2,'Meio (2)'); +INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (3,'Superior (3)'); +INSERT INTO dominios.ancora_vertical (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.ancora_vertical OWNER TO postgres# +ALTER TABLE dominios.ancora_vertical OWNER TO postgres; CREATE TABLE dominios.bitola ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT bitola_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.bitola (code,code_name) VALUES (0,'Desconhecida (0)')# -INSERT INTO dominios.bitola (code,code_name) VALUES (1,'Métrica (1)')# -INSERT INTO dominios.bitola (code,code_name) VALUES (2,'Internacional (2)')# -INSERT INTO dominios.bitola (code,code_name) VALUES (3,'Larga (3)')# -INSERT INTO dominios.bitola (code,code_name) VALUES (4,'Mista métrica internacional (4)')# -INSERT INTO dominios.bitola (code,code_name) VALUES (5,'Mista métrica larga (5)')# -INSERT INTO dominios.bitola (code,code_name) VALUES (6,'Mista internacional larga (6)')# -INSERT INTO dominios.bitola (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.bitola (code,code_name) VALUES (0,'Desconhecida (0)'); +INSERT INTO dominios.bitola (code,code_name) VALUES (1,'Métrica (1)'); +INSERT INTO dominios.bitola (code,code_name) VALUES (2,'Internacional (2)'); +INSERT INTO dominios.bitola (code,code_name) VALUES (3,'Larga (3)'); +INSERT INTO dominios.bitola (code,code_name) VALUES (4,'Mista métrica internacional (4)'); +INSERT INTO dominios.bitola (code,code_name) VALUES (5,'Mista métrica larga (5)'); +INSERT INTO dominios.bitola (code,code_name) VALUES (6,'Mista internacional larga (6)'); +INSERT INTO dominios.bitola (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.bitola OWNER TO postgres# +ALTER TABLE dominios.bitola OWNER TO postgres; CREATE TABLE dominios.tipo_produto_residuo ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_produto_residuo_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (0,'Desconhecido (0)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (3,'Petróleo (3)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (5,'Gás (5)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (18,'Cascalho (18)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (22,'Pedra (brita) (22)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (23,'Granito (23)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (24,'Mármore (24)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (25,'Bauxita (25)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (26,'Manganês (26)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (27,'Talco (27)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (32,'Cobre (32)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (33,'Carvão mineral (33)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (34,'Sal (34)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (35,'Ferro (35)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (37,'Ouro (37)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (38,'Diamante (38)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (39,'Prata (39)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (40,'Pedra preciosa (40)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (42,'Areia (42)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (43,'Saibro/piçarra (43)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (45,'Ágata (45)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (47,'Água marinha (47)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (48,'Água mineral (48)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (49,'Alexandrita (49)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (50,'Ametista (50)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (51,'Amianto (51)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (52,'Argila (52)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (53,'Barita (53)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (54,'Bentonita (54)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (55,'Calcário (55)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (56,'Carvão vegetal (56)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (57,'Caulim (57)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (59,'Chumbo (59)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (60,'Citrino (60)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (61,'Crisoberilo (61)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (62,'Cristal de rocha (62)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (63,'Cromo (63)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (64,'Diatomita (64)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (65,'Dolomito (65)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (67,'Esmeralda (67)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (68,'Estanho (68)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (69,'Feldspato (69)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (70,'Fosfato (70)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (71,'Gipsita (71)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (72,'Grafita (72)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (73,'Granada (73)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (74,'Lítio (74)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (78,'Magnesita (78)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (79,'Mica (79)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (80,'Nióbio (80)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (81,'Níquel (81)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (82,'Opala (82)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (83,'Rocha ornamental (83)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (84,'Sal-gema (84)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (85,'Terras raras (85)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (86,'Titânio (86)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (87,'Topázio (87)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (88,'Tório (88)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (89,'Tungstênio (89)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (90,'Turfa (90)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (91,'Turmalina (91)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (92,'Urânio (92)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (93,'Vermiculita (93)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (94,'Zinco (94)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (99,'Outros (99)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (100,'Zircônio (100)')# -INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_produto_residuo OWNER TO postgres# +); + +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (0,'Desconhecido (0)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (3,'Petróleo (3)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (5,'Gás (5)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (18,'Cascalho (18)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (22,'Pedra (brita) (22)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (23,'Granito (23)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (24,'Mármore (24)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (25,'Bauxita (25)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (26,'Manganês (26)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (27,'Talco (27)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (32,'Cobre (32)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (33,'Carvão mineral (33)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (34,'Sal (34)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (35,'Ferro (35)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (37,'Ouro (37)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (38,'Diamante (38)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (39,'Prata (39)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (40,'Pedra preciosa (40)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (42,'Areia (42)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (43,'Saibro/piçarra (43)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (45,'Ágata (45)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (47,'Água marinha (47)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (48,'Água mineral (48)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (49,'Alexandrita (49)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (50,'Ametista (50)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (51,'Amianto (51)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (52,'Argila (52)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (53,'Barita (53)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (54,'Bentonita (54)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (55,'Calcário (55)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (56,'Carvão vegetal (56)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (57,'Caulim (57)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (59,'Chumbo (59)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (60,'Citrino (60)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (61,'Crisoberilo (61)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (62,'Cristal de rocha (62)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (63,'Cromo (63)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (64,'Diatomita (64)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (65,'Dolomito (65)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (67,'Esmeralda (67)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (68,'Estanho (68)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (69,'Feldspato (69)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (70,'Fosfato (70)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (71,'Gipsita (71)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (72,'Grafita (72)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (73,'Granada (73)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (74,'Lítio (74)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (78,'Magnesita (78)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (79,'Mica (79)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (80,'Nióbio (80)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (81,'Níquel (81)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (82,'Opala (82)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (83,'Rocha ornamental (83)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (84,'Sal-gema (84)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (85,'Terras raras (85)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (86,'Titânio (86)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (87,'Topázio (87)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (88,'Tório (88)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (89,'Tungstênio (89)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (90,'Turfa (90)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (91,'Turmalina (91)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (92,'Urânio (92)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (93,'Vermiculita (93)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (94,'Zinco (94)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (99,'Outros (99)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (100,'Zircônio (100)'); +INSERT INTO dominios.tipo_produto_residuo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_produto_residuo OWNER TO postgres; CREATE TABLE dominios.tipo_borda_elemento_hidrografico ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_borda_elemento_hidrografico_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_borda_elemento_hidrografico (code,code_name) VALUES (1,'Rocha em água (1)')# -INSERT INTO dominios.tipo_borda_elemento_hidrografico (code,code_name) VALUES (2,'Recife (2)')# -INSERT INTO dominios.tipo_borda_elemento_hidrografico (code,code_name) VALUES (3,'Limite entre oceano e mangue (3)')# -INSERT INTO dominios.tipo_borda_elemento_hidrografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_borda_elemento_hidrografico (code,code_name) VALUES (1,'Rocha em água (1)'); +INSERT INTO dominios.tipo_borda_elemento_hidrografico (code,code_name) VALUES (2,'Recife (2)'); +INSERT INTO dominios.tipo_borda_elemento_hidrografico (code,code_name) VALUES (3,'Limite entre oceano e mangue (3)'); +INSERT INTO dominios.tipo_borda_elemento_hidrografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_borda_elemento_hidrografico OWNER TO postgres# +ALTER TABLE dominios.tipo_borda_elemento_hidrografico OWNER TO postgres; CREATE TABLE dominios.posicao_rotulo ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT posicao_rotulo_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (1,'Na linha (1)')# -INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (2,'Acima da linha (2)')# -INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (3,'Abaixo da linha (3)')# -INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (1,'Na linha (1)'); +INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (2,'Acima da linha (2)'); +INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (3,'Abaixo da linha (3)'); +INSERT INTO dominios.posicao_rotulo (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.posicao_rotulo OWNER TO postgres# +ALTER TABLE dominios.posicao_rotulo OWNER TO postgres; CREATE TABLE dominios.tipo_simbolo_area ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_simbolo_area_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (1,'Subestação de energia (1)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (2,'Extração mineral (2)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (3,'Extração mineral não operacional (3)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (4,'Extração mineral - salina (4)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (5,'Plataforma (5)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (6,'Cemitério - Cristã (6)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (7,'Cemitério - Israelita (7)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (8,'Cemitério - Muçulmana (8)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (9,'Cemitério - Outros (9)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (10,'Estacionamento (10)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (11,'Edificação de ensino (11)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (12,'Edificação religiosa (12)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (13,'Edificação religiosa - mesquita (13)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (14,'Edificação religiosa - sinagoga (14)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (19,'Edificação religiosa - cristã (19)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (20,'Edificação religiosa - templo (20)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (15,'Edificação saúde (15)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (16,'Posto de combustível (16)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (17,'Representação diplomática (17)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (18,'Campo/quadra (18)')# -INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_simbolo_area OWNER TO postgres# +); + +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (1,'Subestação de energia (1)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (2,'Extração mineral (2)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (3,'Extração mineral não operacional (3)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (4,'Extração mineral - salina (4)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (5,'Plataforma (5)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (6,'Cemitério - Cristã (6)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (7,'Cemitério - Israelita (7)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (8,'Cemitério - Muçulmana (8)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (9,'Cemitério - Outros (9)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (10,'Estacionamento (10)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (11,'Edificação de ensino (11)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (12,'Edificação religiosa (12)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (13,'Edificação religiosa - mesquita (13)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (14,'Edificação religiosa - sinagoga (14)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (19,'Edificação religiosa - cristã (19)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (20,'Edificação religiosa - templo (20)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (15,'Edificação saúde (15)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (16,'Posto de combustível (16)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (17,'Representação diplomática (17)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (18,'Campo/quadra (18)'); +INSERT INTO dominios.tipo_simbolo_area (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_simbolo_area OWNER TO postgres; CREATE TABLE dominios.justificativa ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT justificativa_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.justificativa (code,code_name) VALUES (1,'Esquerda (1)')# -INSERT INTO dominios.justificativa (code,code_name) VALUES (2,'Centro (2)')# -INSERT INTO dominios.justificativa (code,code_name) VALUES (3,'Direita (3)')# -INSERT INTO dominios.justificativa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.justificativa (code,code_name) VALUES (1,'Esquerda (1)'); +INSERT INTO dominios.justificativa (code,code_name) VALUES (2,'Centro (2)'); +INSERT INTO dominios.justificativa (code,code_name) VALUES (3,'Direita (3)'); +INSERT INTO dominios.justificativa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.justificativa OWNER TO postgres# +ALTER TABLE dominios.justificativa OWNER TO postgres; CREATE TABLE dominios.auxiliar ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT auxiliar_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.auxiliar (code,code_name) VALUES (0,'Desconhecido (0)')# -INSERT INTO dominios.auxiliar (code,code_name) VALUES (1,'Sim (1)')# -INSERT INTO dominios.auxiliar (code,code_name) VALUES (2,'Não (2)')# -INSERT INTO dominios.auxiliar (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.auxiliar (code,code_name) VALUES (0,'Desconhecido (0)'); +INSERT INTO dominios.auxiliar (code,code_name) VALUES (1,'Sim (1)'); +INSERT INTO dominios.auxiliar (code,code_name) VALUES (2,'Não (2)'); +INSERT INTO dominios.auxiliar (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.auxiliar OWNER TO postgres# +ALTER TABLE dominios.auxiliar OWNER TO postgres; CREATE TABLE dominios.administracao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT administracao_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.administracao (code,code_name) VALUES (0,'Desconhecida (0)')# -INSERT INTO dominios.administracao (code,code_name) VALUES (1,'Federal (1)')# -INSERT INTO dominios.administracao (code,code_name) VALUES (2,'Estadual (2)')# -INSERT INTO dominios.administracao (code,code_name) VALUES (3,'Municipal (3)')# -INSERT INTO dominios.administracao (code,code_name) VALUES (6,'Particular (6)')# -INSERT INTO dominios.administracao (code,code_name) VALUES (7,'Concessionada (7)')# -INSERT INTO dominios.administracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.administracao (code,code_name) VALUES (0,'Desconhecida (0)'); +INSERT INTO dominios.administracao (code,code_name) VALUES (1,'Federal (1)'); +INSERT INTO dominios.administracao (code,code_name) VALUES (2,'Estadual (2)'); +INSERT INTO dominios.administracao (code,code_name) VALUES (3,'Municipal (3)'); +INSERT INTO dominios.administracao (code,code_name) VALUES (6,'Particular (6)'); +INSERT INTO dominios.administracao (code,code_name) VALUES (7,'Concessionada (7)'); +INSERT INTO dominios.administracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.administracao OWNER TO postgres# +ALTER TABLE dominios.administracao OWNER TO postgres; CREATE TABLE dominios.booleano ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT booleano_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.booleano (code,code_name) VALUES (1,'Sim (1)')# -INSERT INTO dominios.booleano (code,code_name) VALUES (2,'Não (2)')# -INSERT INTO dominios.booleano (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.booleano (code,code_name) VALUES (1,'Sim (1)'); +INSERT INTO dominios.booleano (code,code_name) VALUES (2,'Não (2)'); +INSERT INTO dominios.booleano (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.booleano OWNER TO postgres# +ALTER TABLE dominios.booleano OWNER TO postgres; CREATE TABLE dominios.booleano_estendido ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT booleano_estendido_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.booleano_estendido (code,code_name) VALUES (0,'Desconhecido (0)')# -INSERT INTO dominios.booleano_estendido (code,code_name) VALUES (1,'Sim (1)')# -INSERT INTO dominios.booleano_estendido (code,code_name) VALUES (2,'Não (2)')# -INSERT INTO dominios.booleano_estendido (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.booleano_estendido (code,code_name) VALUES (0,'Desconhecido (0)'); +INSERT INTO dominios.booleano_estendido (code,code_name) VALUES (1,'Sim (1)'); +INSERT INTO dominios.booleano_estendido (code,code_name) VALUES (2,'Não (2)'); +INSERT INTO dominios.booleano_estendido (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.booleano_estendido OWNER TO postgres# +ALTER TABLE dominios.booleano_estendido OWNER TO postgres; CREATE TABLE dominios.tipo_sumidouro_vertedouro ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_sumidouro_vertedouro_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_sumidouro_vertedouro (code,code_name) VALUES (4,'Sumidouro (4)')# -INSERT INTO dominios.tipo_sumidouro_vertedouro (code,code_name) VALUES (5,'Vertedouro (5)')# -INSERT INTO dominios.tipo_sumidouro_vertedouro (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_sumidouro_vertedouro (code,code_name) VALUES (4,'Sumidouro (4)'); +INSERT INTO dominios.tipo_sumidouro_vertedouro (code,code_name) VALUES (5,'Vertedouro (5)'); +INSERT INTO dominios.tipo_sumidouro_vertedouro (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_sumidouro_vertedouro OWNER TO postgres# +ALTER TABLE dominios.tipo_sumidouro_vertedouro OWNER TO postgres; CREATE TABLE dominios.finalidade ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT finalidade_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.finalidade (code,code_name) VALUES (0,'Desconhecida (0)')# -INSERT INTO dominios.finalidade (code,code_name) VALUES (2,'Tratamento (2)')# -INSERT INTO dominios.finalidade (code,code_name) VALUES (3,'Recalque (3)')# -INSERT INTO dominios.finalidade (code,code_name) VALUES (4,'Distribuição (4)')# -INSERT INTO dominios.finalidade (code,code_name) VALUES (8,'Armazenamento (8)')# -INSERT INTO dominios.finalidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.finalidade (code,code_name) VALUES (0,'Desconhecida (0)'); +INSERT INTO dominios.finalidade (code,code_name) VALUES (2,'Tratamento (2)'); +INSERT INTO dominios.finalidade (code,code_name) VALUES (3,'Recalque (3)'); +INSERT INTO dominios.finalidade (code,code_name) VALUES (4,'Distribuição (4)'); +INSERT INTO dominios.finalidade (code,code_name) VALUES (8,'Armazenamento (8)'); +INSERT INTO dominios.finalidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.finalidade OWNER TO postgres# +ALTER TABLE dominios.finalidade OWNER TO postgres; CREATE TABLE dominios.situacao_em_poligono ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT situacao_em_poligono_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (1,'Fora de polígono (1)')# -INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (2,'Dentro de polígono - Trecho principal (2)')# -INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (3,'Dentro de polígono - Trecho secundário (3)')# -INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (4,'Dentro de polígono - Trecho compartilhado (4)')# -INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (1,'Fora de polígono (1)'); +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (2,'Dentro de polígono - Trecho principal (2)'); +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (3,'Dentro de polígono - Trecho secundário (3)'); +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (4,'Dentro de polígono - Trecho compartilhado (4)'); +INSERT INTO dominios.situacao_em_poligono (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.situacao_em_poligono OWNER TO postgres# +ALTER TABLE dominios.situacao_em_poligono OWNER TO postgres; CREATE TABLE dominios.forma_extracao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT forma_extracao_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.forma_extracao (code,code_name) VALUES (5,'A céu aberto (5)')# -INSERT INTO dominios.forma_extracao (code,code_name) VALUES (6,'Subterrânea (6)')# -INSERT INTO dominios.forma_extracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.forma_extracao (code,code_name) VALUES (5,'A céu aberto (5)'); +INSERT INTO dominios.forma_extracao (code,code_name) VALUES (6,'Subterrânea (6)'); +INSERT INTO dominios.forma_extracao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.forma_extracao OWNER TO postgres# +ALTER TABLE dominios.forma_extracao OWNER TO postgres; CREATE TABLE dominios.indice ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT indice_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.indice (code,code_name) VALUES (1,'Mestra (1)')# -INSERT INTO dominios.indice (code,code_name) VALUES (2,'Normal (2)')# -INSERT INTO dominios.indice (code,code_name) VALUES (3,'Auxiliar (3)')# -INSERT INTO dominios.indice (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.indice (code,code_name) VALUES (1,'Mestra (1)'); +INSERT INTO dominios.indice (code,code_name) VALUES (2,'Normal (2)'); +INSERT INTO dominios.indice (code,code_name) VALUES (3,'Auxiliar (3)'); +INSERT INTO dominios.indice (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.indice OWNER TO postgres# +ALTER TABLE dominios.indice OWNER TO postgres; CREATE TABLE dominios.jurisdicao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT jurisdicao_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.jurisdicao (code,code_name) VALUES (0,'Desconhecida (0)')# -INSERT INTO dominios.jurisdicao (code,code_name) VALUES (1,'Federal (1)')# -INSERT INTO dominios.jurisdicao (code,code_name) VALUES (2,'Estadual (2)')# -INSERT INTO dominios.jurisdicao (code,code_name) VALUES (3,'Municipal (3)')# -INSERT INTO dominios.jurisdicao (code,code_name) VALUES (6,'Particular (6)')# -INSERT INTO dominios.jurisdicao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (0,'Desconhecida (0)'); +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (1,'Federal (1)'); +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (2,'Estadual (2)'); +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (3,'Municipal (3)'); +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (6,'Particular (6)'); +INSERT INTO dominios.jurisdicao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.jurisdicao OWNER TO postgres# +ALTER TABLE dominios.jurisdicao OWNER TO postgres; CREATE TABLE dominios.tipo_barragem ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_barragem_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_barragem (code,code_name) VALUES (1,'Barragem (1)')# -INSERT INTO dominios.tipo_barragem (code,code_name) VALUES (2,'Dique (2)')# -INSERT INTO dominios.tipo_barragem (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_barragem (code,code_name) VALUES (1,'Barragem (1)'); +INSERT INTO dominios.tipo_barragem (code,code_name) VALUES (2,'Dique (2)'); +INSERT INTO dominios.tipo_barragem (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_barragem OWNER TO postgres# +ALTER TABLE dominios.tipo_barragem OWNER TO postgres; CREATE TABLE dominios.material_construcao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT material_construcao_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.material_construcao (code,code_name) VALUES (0,'Desconhecido (0)')# -INSERT INTO dominios.material_construcao (code,code_name) VALUES (1,'Alvenaria (1)')# -INSERT INTO dominios.material_construcao (code,code_name) VALUES (2,'Concreto (2)')# -INSERT INTO dominios.material_construcao (code,code_name) VALUES (3,'Metal (3)')# -INSERT INTO dominios.material_construcao (code,code_name) VALUES (4,'Rocha (4)')# -INSERT INTO dominios.material_construcao (code,code_name) VALUES (5,'Madeira (5)')# -INSERT INTO dominios.material_construcao (code,code_name) VALUES (9,'Fibra (9)')# -INSERT INTO dominios.material_construcao (code,code_name) VALUES (23,'Terra (23)')# -INSERT INTO dominios.material_construcao (code,code_name) VALUES (97,'Não aplicável (97)')# -INSERT INTO dominios.material_construcao (code,code_name) VALUES (98,'Outros (98)')# -INSERT INTO dominios.material_construcao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.material_construcao OWNER TO postgres# +); + +INSERT INTO dominios.material_construcao (code,code_name) VALUES (0,'Desconhecido (0)'); +INSERT INTO dominios.material_construcao (code,code_name) VALUES (1,'Alvenaria (1)'); +INSERT INTO dominios.material_construcao (code,code_name) VALUES (2,'Concreto (2)'); +INSERT INTO dominios.material_construcao (code,code_name) VALUES (3,'Metal (3)'); +INSERT INTO dominios.material_construcao (code,code_name) VALUES (4,'Rocha (4)'); +INSERT INTO dominios.material_construcao (code,code_name) VALUES (5,'Madeira (5)'); +INSERT INTO dominios.material_construcao (code,code_name) VALUES (9,'Fibra (9)'); +INSERT INTO dominios.material_construcao (code,code_name) VALUES (23,'Terra (23)'); +INSERT INTO dominios.material_construcao (code,code_name) VALUES (97,'Não aplicável (97)'); +INSERT INTO dominios.material_construcao (code,code_name) VALUES (98,'Outros (98)'); +INSERT INTO dominios.material_construcao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.material_construcao OWNER TO postgres; CREATE TABLE dominios.modal_uso ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT modal_uso_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.modal_uso (code,code_name) VALUES (4,'Rodoviário (4)')# -INSERT INTO dominios.modal_uso (code,code_name) VALUES (5,'Ferroviário (5)')# -INSERT INTO dominios.modal_uso (code,code_name) VALUES (6,'Metroviário (6)')# -INSERT INTO dominios.modal_uso (code,code_name) VALUES (7,'Dutos (7)')# -INSERT INTO dominios.modal_uso (code,code_name) VALUES (9,'Aeroportuário (9)')# -INSERT INTO dominios.modal_uso (code,code_name) VALUES (10,'Hidroviário (10)')# -INSERT INTO dominios.modal_uso (code,code_name) VALUES (14,'Portuário (14)')# -INSERT INTO dominios.modal_uso (code,code_name) VALUES (97,'Não aplicável (97)')# -INSERT INTO dominios.modal_uso (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.modal_uso (code,code_name) VALUES (4,'Rodoviário (4)'); +INSERT INTO dominios.modal_uso (code,code_name) VALUES (5,'Ferroviário (5)'); +INSERT INTO dominios.modal_uso (code,code_name) VALUES (6,'Metroviário (6)'); +INSERT INTO dominios.modal_uso (code,code_name) VALUES (7,'Dutos (7)'); +INSERT INTO dominios.modal_uso (code,code_name) VALUES (9,'Aeroportuário (9)'); +INSERT INTO dominios.modal_uso (code,code_name) VALUES (10,'Hidroviário (10)'); +INSERT INTO dominios.modal_uso (code,code_name) VALUES (14,'Portuário (14)'); +INSERT INTO dominios.modal_uso (code,code_name) VALUES (97,'Não aplicável (97)'); +INSERT INTO dominios.modal_uso (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.modal_uso OWNER TO postgres# +ALTER TABLE dominios.modal_uso OWNER TO postgres; CREATE TABLE dominios.nr_linhas ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT nr_linhas_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.nr_linhas (code,code_name) VALUES (0,'Desconhecido (0)')# -INSERT INTO dominios.nr_linhas (code,code_name) VALUES (1,'Simples (1)')# -INSERT INTO dominios.nr_linhas (code,code_name) VALUES (2,'Dupla (2)')# -INSERT INTO dominios.nr_linhas (code,code_name) VALUES (3,'Múltipla (3)')# -INSERT INTO dominios.nr_linhas (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (0,'Desconhecido (0)'); +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (1,'Simples (1)'); +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (2,'Dupla (2)'); +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (3,'Múltipla (3)'); +INSERT INTO dominios.nr_linhas (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.nr_linhas OWNER TO postgres# +ALTER TABLE dominios.nr_linhas OWNER TO postgres; CREATE TABLE dominios.posicao_pista ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT posicao_pista_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.posicao_pista (code,code_name) VALUES (12,'Adjacentes (12)')# -INSERT INTO dominios.posicao_pista (code,code_name) VALUES (13,'Superpostas (13)')# -INSERT INTO dominios.posicao_pista (code,code_name) VALUES (97,'Não aplicável (97)')# -INSERT INTO dominios.posicao_pista (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.posicao_pista (code,code_name) VALUES (12,'Adjacentes (12)'); +INSERT INTO dominios.posicao_pista (code,code_name) VALUES (13,'Superpostas (13)'); +INSERT INTO dominios.posicao_pista (code,code_name) VALUES (97,'Não aplicável (97)'); +INSERT INTO dominios.posicao_pista (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.posicao_pista OWNER TO postgres# +ALTER TABLE dominios.posicao_pista OWNER TO postgres; CREATE TABLE dominios.posicao_relativa ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT posicao_relativa_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (2,'Superfície (2)')# -INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (3,'Elevado (3)')# -INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (4,'Emerso (4)')# -INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (5,'Submerso (5)')# -INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (6,'Subterrâneo (6)')# -INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (2,'Superfície (2)'); +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (3,'Elevado (3)'); +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (4,'Emerso (4)'); +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (5,'Submerso (5)'); +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (6,'Subterrâneo (6)'); +INSERT INTO dominios.posicao_relativa (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.posicao_relativa OWNER TO postgres# +ALTER TABLE dominios.posicao_relativa OWNER TO postgres; CREATE TABLE dominios.referencial_altim ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT referencial_altim_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.referencial_altim (code,code_name) VALUES (1,'Torres (1)')# -INSERT INTO dominios.referencial_altim (code,code_name) VALUES (2,'Imbituba (2)')# -INSERT INTO dominios.referencial_altim (code,code_name) VALUES (3,'Santana (3)')# -INSERT INTO dominios.referencial_altim (code,code_name) VALUES (4,'Local (4)')# -INSERT INTO dominios.referencial_altim (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (1,'Torres (1)'); +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (2,'Imbituba (2)'); +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (3,'Santana (3)'); +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (4,'Local (4)'); +INSERT INTO dominios.referencial_altim (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.referencial_altim OWNER TO postgres# +ALTER TABLE dominios.referencial_altim OWNER TO postgres; CREATE TABLE dominios.referencial_grav ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT referencial_grav_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (1,'Postdam 1930 (1)')# -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (2,'IGSN71 (2)')# -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (3,'Absoluto (3)')# -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (4,'Local (4)')# -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (5,'RGFB (5)')# -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (97,'Não aplicável (97)')# -INSERT INTO dominios.referencial_grav (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (1,'Postdam 1930 (1)'); +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (2,'IGSN71 (2)'); +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (3,'Absoluto (3)'); +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (4,'Local (4)'); +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (5,'RGFB (5)'); +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (97,'Não aplicável (97)'); +INSERT INTO dominios.referencial_grav (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.referencial_grav OWNER TO postgres# +ALTER TABLE dominios.referencial_grav OWNER TO postgres; CREATE TABLE dominios.regime ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT regime_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.regime (code,code_name) VALUES (0,'Desconhecido (0)')# -INSERT INTO dominios.regime (code,code_name) VALUES (1,'Permanente (1)')# -INSERT INTO dominios.regime (code,code_name) VALUES (3,'Temporário (3)')# -INSERT INTO dominios.regime (code,code_name) VALUES (5,'Seco (5)')# -INSERT INTO dominios.regime (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.regime (code,code_name) VALUES (0,'Desconhecido (0)'); +INSERT INTO dominios.regime (code,code_name) VALUES (1,'Permanente (1)'); +INSERT INTO dominios.regime (code,code_name) VALUES (3,'Temporário (3)'); +INSERT INTO dominios.regime (code,code_name) VALUES (5,'Seco (5)'); +INSERT INTO dominios.regime (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.regime OWNER TO postgres# +ALTER TABLE dominios.regime OWNER TO postgres; CREATE TABLE dominios.revestimento ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT revestimento_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.revestimento (code,code_name) VALUES (0,'Desconhecido (0)')# -INSERT INTO dominios.revestimento (code,code_name) VALUES (1,'Leito natural (1)')# -INSERT INTO dominios.revestimento (code,code_name) VALUES (2,'Revestimento primário (solto) (2)')# -INSERT INTO dominios.revestimento (code,code_name) VALUES (3,'Pavimentado (3)')# -INSERT INTO dominios.revestimento (code,code_name) VALUES (4,'Calçado (4)')# -INSERT INTO dominios.revestimento (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.revestimento (code,code_name) VALUES (0,'Desconhecido (0)'); +INSERT INTO dominios.revestimento (code,code_name) VALUES (1,'Leito natural (1)'); +INSERT INTO dominios.revestimento (code,code_name) VALUES (2,'Revestimento primário (solto) (2)'); +INSERT INTO dominios.revestimento (code,code_name) VALUES (3,'Pavimentado (3)'); +INSERT INTO dominios.revestimento (code,code_name) VALUES (4,'Calçado (4)'); +INSERT INTO dominios.revestimento (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.revestimento OWNER TO postgres# +ALTER TABLE dominios.revestimento OWNER TO postgres; CREATE TABLE dominios.sistema_geodesico ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT sistema_geodesico_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (1,'SAD 69 (1)')# -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (2,'SIRGAS 2000 (2)')# -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (3,'WGS-84 (3)')# -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (4,'Córrego Alegre (4)')# -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (5,'Astro Chuá (5)')# -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (6,'SAD-69 (96) (6)')# -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (98,'Outra referência (98)')# -INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (1,'SAD 69 (1)'); +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (2,'SIRGAS 2000 (2)'); +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (3,'WGS-84 (3)'); +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (4,'Córrego Alegre (4)'); +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (5,'Astro Chuá (5)'); +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (6,'SAD-69 (96) (6)'); +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (98,'Outra referência (98)'); +INSERT INTO dominios.sistema_geodesico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.sistema_geodesico OWNER TO postgres# +ALTER TABLE dominios.sistema_geodesico OWNER TO postgres; CREATE TABLE dominios.situacao_fisica ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT situacao_fisica_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (0,'Desconhecida (0)')# -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (1,'Abandonada (1)')# -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (2,'Destruída (2)')# -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (3,'Construída (3)')# -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (4,'Em construção (4)')# -INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (0,'Desconhecida (0)'); +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (1,'Abandonada (1)'); +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (2,'Destruída (2)'); +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (3,'Construída (3)'); +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (4,'Em construção (4)'); +INSERT INTO dominios.situacao_fisica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.situacao_fisica OWNER TO postgres# +ALTER TABLE dominios.situacao_fisica OWNER TO postgres; CREATE TABLE dominios.situacao_marco ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT situacao_marco_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (1,'Bom (1)')# -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (2,'Destruído (2)')# -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (3,'Destruído sem chapa (3)')# -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (4,'Destruído com chapa danificada (4)')# -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (5,'Não encontrado (5)')# -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (6,'Não visitado (6)')# -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (97,'Não aplicável (97)')# -INSERT INTO dominios.situacao_marco (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (1,'Bom (1)'); +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (2,'Destruído (2)'); +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (3,'Destruído sem chapa (3)'); +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (4,'Destruído com chapa danificada (4)'); +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (5,'Não encontrado (5)'); +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (6,'Não visitado (6)'); +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (97,'Não aplicável (97)'); +INSERT INTO dominios.situacao_marco (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.situacao_marco OWNER TO postgres# +ALTER TABLE dominios.situacao_marco OWNER TO postgres; CREATE TABLE dominios.tipo_massa_dagua ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_massa_dagua_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (1,'Rio (com fluxo) (1)')# -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (2,'Canal (com fluxo) (2)')# -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (3,'Oceano (sem fluxo) (3)')# -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (4,'Baía (sem fluxo) (4)')# -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (5,'Enseada (sem fluxo) (5)')# -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (6,'Meando Abandonado (sem fluxo) (6)')# -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (7,'Lago ou Lagoa (sem fluxo) (7)')# -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (9,'Laguna (com fluxo) (9)')# -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (10,'Represa/açude com fluxo (10)')# -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (11,'Represa/açude sem fluxo (11)')# -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (12,'Canal não operacional (sem fluxo) (12)')# -INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_massa_dagua OWNER TO postgres# +); + +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (1,'Rio (com fluxo) (1)'); +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (2,'Canal (com fluxo) (2)'); +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (3,'Oceano (sem fluxo) (3)'); +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (4,'Baía (sem fluxo) (4)'); +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (5,'Enseada (sem fluxo) (5)'); +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (6,'Meando Abandonado (sem fluxo) (6)'); +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (7,'Lago ou Lagoa (sem fluxo) (7)'); +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (9,'Laguna (com fluxo) (9)'); +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (10,'Represa/açude com fluxo (10)'); +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (11,'Represa/açude sem fluxo (11)'); +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (12,'Canal não operacional (sem fluxo) (12)'); +INSERT INTO dominios.tipo_massa_dagua (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_massa_dagua OWNER TO postgres; CREATE TABLE dominios.tipo_delimitacao_fisica ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_delimitacao_fisica_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_delimitacao_fisica (code,code_name) VALUES (1,'Cerca (1)')# -INSERT INTO dominios.tipo_delimitacao_fisica (code,code_name) VALUES (2,'Muro (2)')# -INSERT INTO dominios.tipo_delimitacao_fisica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_delimitacao_fisica (code,code_name) VALUES (1,'Cerca (1)'); +INSERT INTO dominios.tipo_delimitacao_fisica (code,code_name) VALUES (2,'Muro (2)'); +INSERT INTO dominios.tipo_delimitacao_fisica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_delimitacao_fisica OWNER TO postgres# +ALTER TABLE dominios.tipo_delimitacao_fisica OWNER TO postgres; CREATE TABLE dominios.tipo_deposito ( code smallint NOT NULL, code_name text NOT NULL, filter text NOT NULL, CONSTRAINT tipo_deposito_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (101,'Geral - Cisterna (101)','Depósito geral')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (108,'Geral - Galpão (108)','Depósito geral')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (109,'Geral - Silo (109)','Depósito geral')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (110,'Geral - Composteira (110)','Depósito geral')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (111,'Geral - Depósito frigorífico (111)','Depósito geral')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (112,'Geral - Barracão industrial (112)','Depósito geral')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (113,'Geral - Reservatório (113)','Depósito geral')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (132,'Geral - Armazém (132)','Depósito geral')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (198,'Geral - Outros (198)','Depósito geral')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (201,'Abast água - Tanque de água (201)','Depósito de abastecimento de água')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (202,'Abast água - Caixa de água (202)','Depósito de abastecimento de água')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (203,'Abast água - Cisterna (203)','Depósito de abastecimento de água')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (204,'Abast água - Reservatório (204)','Depósito de abastecimento de água')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (298,'Abast água - Outros (298)','Depósito de abastecimento de água')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (301,'San - Tanque de saneamento (301)','Depósito de saneamento')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (304,'San - Depósito de lixo (304)','Depósito de saneamento')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (305,'San - Aterro sanitário (305)','Depósito de saneamento')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (306,'San - Aterro controlado (306)','Depósito de saneamento')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (398,'San - Outros (398)','Depósito de saneamento')# -INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_deposito OWNER TO postgres# +); + +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (101,'Geral - Cisterna (101)','Depósito geral'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (108,'Geral - Galpão (108)','Depósito geral'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (109,'Geral - Silo (109)','Depósito geral'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (110,'Geral - Composteira (110)','Depósito geral'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (111,'Geral - Depósito frigorífico (111)','Depósito geral'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (112,'Geral - Barracão industrial (112)','Depósito geral'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (113,'Geral - Reservatório (113)','Depósito geral'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (132,'Geral - Armazém (132)','Depósito geral'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (198,'Geral - Outros (198)','Depósito geral'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (201,'Abast água - Tanque de água (201)','Depósito de abastecimento de água'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (202,'Abast água - Caixa de água (202)','Depósito de abastecimento de água'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (203,'Abast água - Cisterna (203)','Depósito de abastecimento de água'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (204,'Abast água - Reservatório (204)','Depósito de abastecimento de água'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (298,'Abast água - Outros (298)','Depósito de abastecimento de água'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (301,'San - Tanque de saneamento (301)','Depósito de saneamento'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (304,'San - Depósito de lixo (304)','Depósito de saneamento'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (305,'San - Aterro sanitário (305)','Depósito de saneamento'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (306,'San - Aterro controlado (306)','Depósito de saneamento'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (398,'San - Outros (398)','Depósito de saneamento'); +INSERT INTO dominios.tipo_deposito (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_deposito OWNER TO postgres; CREATE TABLE dominios.tipo_edificacao ( code smallint NOT NULL, code_name text NOT NULL, filter text NOT NULL, CONSTRAINT tipo_edificacao_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (0,'Edificação genérica (0)','Edificação genérica')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3,'Edif. Flutuante / Palafita (3)','Edificação genérica')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (101,'Com - Centro de operações de comunicação (101)','Edificação de comunicação')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (102,'Com - Central de comutação e transmissão (102)','Edificação de comunicação')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (103,'Com - Estação rádio-base (103)','Edificação de comunicação')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (104,'Com - Estação repetidora (104)','Edificação de comunicação')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (105,'Com - Administrativo (105)','Edificação de comunicação')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (201,'Edificação de energia (201)','Edificação de energia')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (301,'Abast - Edificação de captação de água (301)','Edificação de abastecimento de água')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (302,'Abast - Edificação de tratamento de água (302)','Edificação de abastecimento de água')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (303,'Abast - Edificação de recalque de água (303)','Edificação de abastecimento de água')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (304,'Abast - Administrativa (304)','Edificação de abastecimento de água')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (395,'Abast - Mista (395)','Edificação de abastecimento de água')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (398,'Abast - Outros (398)','Edificação de abastecimento de água')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (403,'Saneam - Edificação de recalque de resíduos (403)','Edificação de saneamento')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (405,'Saneam - Edificação de tratamento de esgoto (405)','Edificação de saneamento')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (406,'Saneam - Usina de reciclagem (406)','Edificação de saneamento')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (407,'Saneam - Incinerador de resíduos (407)','Edificação de saneamento')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (408,'Saneam - Administração (408)','Edificação de saneamento')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (498,'Saneam - Outros (498)','Edificação de saneamento')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (516,'Ens - Edificação de educação infantil – creche (516)','Edificação de ensino')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (517,'Ens - Edificação de educação infantil - pré-escola (517)','Edificação de ensino')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (518,'Ens - Edificação de ensino fundamental (518)','Edificação de ensino')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (519,'Ens - Edificação de ensino médio (519)','Edificação de ensino')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (520,'Ens - Edificação de educação superior – Graduação (520)','Edificação de ensino')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (521,'Ens - Edificação de educação superior – graduação e pós-graduação (521)','Edificação de ensino')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (522,'Ens - Edificação de educação superior – pós-graduação e extensão (522)','Edificação de ensino')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (523,'Ens - Edificação de educação professional de nível técnico (523)','Edificação de ensino')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (524,'Ens - Edificação de educação profissional de nível tecnológico (524)','Edificação de ensino')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (525,'Ens - Outras atividades de ensino (525)','Edificação de ensino')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (601,'Rel - Igreja cristã (601)','Edificação religiosa')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (602,'Rel - Templo (602)','Edificação religiosa')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (603,'Rel - Centro religioso (603)','Edificação religiosa')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (604,'Rel - Mosteiro (604)','Edificação religiosa')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (605,'Rel - Convento (605)','Edificação religiosa')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (606,'Rel - Mesquita (606)','Edificação religiosa')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (607,'Rel - Sinagoga (607)','Edificação religiosa')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (608,'Rel - Capela Mortuária (608)','Edificação religiosa')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (609,'Rel - Terreiro (609)','Edificação religiosa')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (610,'Rel - Administração (610)','Edificação religiosa')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (611,'Rel - Igreja não cristã (611)','Edificação religiosa')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (698,'Rel - Outros (698)','Edificação religiosa')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (709,'Tur - Cruzeiro (709)','Edificação ou construção turística')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (710,'Tur - Estátua (710)','Edificação ou construção turística')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (711,'Tur - Mirante (711)','Edificação ou construção turística')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (712,'Tur - Monumento (712)','Edificação ou construção turística')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (713,'Tur - Panteão (713)','Edificação ou construção turística')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (798,'Tur - Outros (798)','Edificação ou construção turística')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (801,'Laz - Estádio (801)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (802,'Laz - Ginásio (802)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (803,'Laz - Museu (803)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (804,'Laz - Teatro (804)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (805,'Laz - Anfiteatro (805)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (806,'Laz - Espaço de exibição de filmes (806)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (807,'Laz - Centro cultural (807)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (808,'Laz - Plataforma de pesca (808)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (809,'Laz - Arquivo (809)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (810,'Laz - Biblioteca (810)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (811,'Laz - Centro de documentação (811)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (812,'Laz - Circo (812)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (813,'Laz - Concha acústica (813)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (814,'Laz - Conservatório (814)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (815,'Laz - Coreto ou tribuna (815)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (817,'Laz - Equipamentos culturais diversos (817)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (818,'Laz - Espaço de eventos e/ou cultural (818)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (819,'Laz - Galeria (819)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (898,'Laz - Outros (898)','Edificação de lazer')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (903,'Comerc - Centro comercial (903)','Edificação de comércio e serviço')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (904,'Comerc - Mercado (904)','Edificação de comércio e serviço')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (905,'Comerc - Centro de convenções (905)','Edificação de comércio e serviço')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (907,'Comerc - Hotel / motel / pousada (907)','Edificação de comércio e serviço')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (908,'Comerc - Banco (908)','Edificação de comércio e serviço')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (909,'Comerc - Centro de exposições (909)','Edificação de comércio e serviço')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (910,'Comerc - Mercado público (910)','Edificação de comércio e serviço')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (998,'Comerc - Outros (998)','Edificação de comércio e serviço')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1015,'Ind - Fabricação alimentícia e bebidas (1015)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1016,'Ind - Fabricação de produtos do fumo (1016)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1017,'Ind - Fabricação de produtos têxteis (1017)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1018,'Ind - Confecção de artigos de vestuário e acessórios (1018)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1019,'Ind - Preparação de couros, artefatos de couro, artigos de viagem e calçados (1019)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1020,'Ind - Fabricação de produtos de madeira e celulose (1020)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1021,'Ind - Fabricação de celulose, papel e produtos de papel (1021)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1022,'Ind - Industria de edição, impressão e reprodução de gravações (1022)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1023,'Ind - Fabricação de coque, refino de petróleo, elaboração de combustíveis nucleares e produção de álcool (1023)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1024,'Ind - Fabricação de produtos químicos (1024)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1025,'Ind - Fabricação de artigos de borracha e material plástico (1025)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1026,'Ind - Fabricação de produtos de minerais não-metálicos (1026)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1027,'Ind - Indústria de metalurgia básica (1027)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1028,'Ind - Fabricação de produtos de metal (1028)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1029,'Ind - Fabricação de máquinas e equipamentos (1029)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1030,'Ind - Fabriação de máquinas de escritório e equipamentos de informática (1030)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1031,'Ind - Fabricação de máquinas, aparelhos e materiais elétricos (1031)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1032,'Ind - Fabricação de material eletrônico, de aparelhos e equipamentos de comunicações (1032)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1033,'Ind - Fabricação de equipamentos de instrumentação médico-hospitalares, instrumentos de precisão e ópticos, automação industrial, cronômetros e relógios (1033)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1034,'Ind - Fabricação e montagem de veículos automotores, reboques e carrocerias (1034)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1035,'Ind - Fabricação de outros equipamentos de transporte (1035)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1036,'Ind - Fabricação de móveis e indústrias diversas (1036)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1037,'Ind - Indústria reciclagem (1037)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1045,'Ind - Indústria de construção (1045)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1046,'Ind - Chaminé (1046)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1098,'Ind - Outros (1098)','Edificação industrial')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1110,'Ext Min - Extração de carvão mineral (1110)','Edificação de extração mineral')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1111,'Ext Min - Extração de petróleo e serviços relacionados (1111)','Edificação de extração mineral')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1113,'Ext Min - Extração de minerais metálicos (1113)','Edificação de extração mineral')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1114,'Ext Min - Extração de minerais não-metálicos (1114)','Edificação de extração mineral')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1198,'Ext Min - Outros (1198)','Edificação de extração mineral')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1212,'Agro - Sede operacional de fazenda (1212)','Edificação agropecuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1213,'Agro - Aviário (1213)','Edificação agropecuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1214,'Agro - Apiário (1214)','Edificação agropecuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1215,'Agro - Viveiro de plantas (1215)','Edificação agropecuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1216,'Agro - Viveiro para aquicultura (1216)','Edificação agropecuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1217,'Agro - Pocilga (1217)','Edificação agropecuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1218,'Agro - Curral (1218)','Edificação agropecuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1298,'Agro - Outros (1298)','Edificação agropecuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1303,'Pub Civ - Cartorial (1303)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1304,'Pub Civ - Gestão pública (1304)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1305,'Pub Civ - Eleitoral (1305)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1306,'Pub Civ - Produção ou pequisa pública (1306)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1307,'Pub Civ - Seguridade social (1307)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1308,'Pub Civ - Câmara municipal (1308)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1309,'Pub Civ - Assembléia legislativa (1309)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1310,'Pub Civ - Autarquia (1310)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1313,'Pub Civ - Fórum (1313)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1314,'Pub Civ - Fundação (1314)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1315,'Pub Civ - Procuradoria (1315)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1316,'Pub Civ - Secretaria (1316)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1322,'Pub Civ - Prefeitura (1322)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1398,'Pub Civ - Outros (1398)','Edificação pública civil')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1401,'Habitacão indigena isolada (1401)','Habitacão indigena')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1402,'Habitacão indigena coletiva (1402)','Habitacão indigena')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1501,'Edificação de medição de fenômenos (1501)','Medição de fenômenos')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1712,'Pub Mil - Aquartelamento (1712)','Edificação militar')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1717,'Pub Mil - Hotel de trânsito (1717)','Edificação militar')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1718,'Pub Mil - Delegacia de serviço militar (1718)','Edificação militar')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1724,'Pub Mil - Capitania dos portos (1724)','Edificação militar')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1798,'Pub Mil - Outros (1798)','Edificação militar')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1910,'Posto Fisc - Tributação (1910)','Posto fiscal')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1912,'Posto Fisc - Fiscalização sanitária (1912)','Posto fiscal')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1913,'Posto Fisc - Posto de pesagem (1913)','Posto fiscal')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1995,'Posto Fisc - Misto (1995)','Posto fiscal')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1998,'Posto Fisc - Outros (1998)','Posto fiscal')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2025,'Sau - Atendimento hospitalar (2025)','Edificação de saúde')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2026,'Sau - Atendimento hospitalar especializado (2026)','Edificação de saúde')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2027,'Sau - Atendimento a urgência e emergências (pronto socorro) (2027)','Edificação de saúde')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2028,'Sau - Atenção ambulatorial (posto e centro de saúde) (2028)','Edificação de saúde')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2029,'Sau - Serviços de complementação diagnóstica ou terapêutica (2029)','Edificação de saúde')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2030,'Sau - Outras atividades relacionadas com a atenção à saúde (instituto de pesquisa) (2030)','Edificação de saúde')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2031,'Sau - Serviços veterinários (2031)','Edificação de saúde')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2101,'Ssoc – Serviço Social (2101)','Edificação de desenvolvimento social')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2208,'Rod - Terminal interestadual (2208)','Edificação rodoviária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2209,'Rod - Terminal urbano (2209)','Edificação rodoviária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2210,'Rod - Parada interestadual (2210)','Edificação rodoviária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2213,'Rod - Posto de pedágio (2213)','Edificação rodoviária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2298,'Rod - Outros (2298)','Edificação rodoviária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2316,'Ferrov - Estação ferroviária de passageiros (2316)','Edificação ferroviária ou metroviária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2317,'Ferrov - Estação metroviária (2317)','Edificação ferroviária ou metroviária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2318,'Ferrov - Terminal ferroviário de cargas (2318)','Edificação ferroviária ou metroviária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2319,'Ferrov - Terminal ferroviário de passageiros e cargas (2319)','Edificação ferroviária ou metroviária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2320,'Ferrov - Oficina de manutenção (2320)','Edificação ferroviária ou metroviária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2321,'Ferrov - Administração (2321)','Edificação ferroviária ou metroviária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2398,'Ferrov - Outros (2398)','Edificação ferroviária ou metroviária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2426,'Aero - Terminal de passageiros (2426)','Edificação aeroportuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2427,'Aero - Terminal de cargas (2427)','Edificação aeroportuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2428,'Aero - Torre de controle (2428)','Edificação aeroportuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2429,'Aero - Hangar (2429)','Edificação aeroportuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2430,'Aero - Serviço de Combate à incendios (SCI) (2430)','Edificação aeroportuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2431,'Aero - Administração (2431)','Edificação aeroportuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2498,'Aero - Outros (2498)','Edificação aeroportuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2501,'Port - Edificação portuária (2501)','Edificação portuária')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2601,'Posto de combustivel (2601)','Posto de combustivel')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2901,'Dip – Consulado (2901)','Representação diplomática')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2902,'Dip – Embaixada (2902)','Representação diplomática')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3001,'Seg – Delegacia de polícia civil (3001)','Edificação de segurança pública')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3002,'Seg – Posto policia militar (3002)','Edificação de segurança pública')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3003,'Seg – Posto guarda municipal (3003)','Edificação de segurança pública')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3004,'Seg – Posto de polícia rodoviária federal (3004)','Edificação de segurança pública')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3005,'Seg – Polícia militar (3005)','Edificação de segurança pública')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3006,'Seg - Prisional (3006)','Edificação de segurança pública')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3007,'Seg - Bombeiros Militar (3007)','Edificação de segurança pública')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3008,'Seg - Bombeiros Civil (3008)','Edificação de segurança pública')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3098,'Seg – Outras polícias (3098)','Edificação de segurança pública')# -INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_edificacao OWNER TO postgres# +); + +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (0,'Edificação genérica (0)','Edificação genérica'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3,'Edif. Flutuante / Palafita (3)','Edificação genérica'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (101,'Com - Centro de operações de comunicação (101)','Edificação de comunicação'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (102,'Com - Central de comutação e transmissão (102)','Edificação de comunicação'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (103,'Com - Estação rádio-base (103)','Edificação de comunicação'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (104,'Com - Estação repetidora (104)','Edificação de comunicação'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (105,'Com - Administrativo (105)','Edificação de comunicação'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (201,'Edificação de energia (201)','Edificação de energia'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (301,'Abast - Edificação de captação de água (301)','Edificação de abastecimento de água'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (302,'Abast - Edificação de tratamento de água (302)','Edificação de abastecimento de água'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (303,'Abast - Edificação de recalque de água (303)','Edificação de abastecimento de água'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (304,'Abast - Administrativa (304)','Edificação de abastecimento de água'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (395,'Abast - Mista (395)','Edificação de abastecimento de água'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (398,'Abast - Outros (398)','Edificação de abastecimento de água'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (403,'Saneam - Edificação de recalque de resíduos (403)','Edificação de saneamento'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (405,'Saneam - Edificação de tratamento de esgoto (405)','Edificação de saneamento'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (406,'Saneam - Usina de reciclagem (406)','Edificação de saneamento'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (407,'Saneam - Incinerador de resíduos (407)','Edificação de saneamento'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (408,'Saneam - Administração (408)','Edificação de saneamento'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (498,'Saneam - Outros (498)','Edificação de saneamento'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (516,'Ens - Edificação de educação infantil – creche (516)','Edificação de ensino'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (517,'Ens - Edificação de educação infantil - pré-escola (517)','Edificação de ensino'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (518,'Ens - Edificação de ensino fundamental (518)','Edificação de ensino'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (519,'Ens - Edificação de ensino médio (519)','Edificação de ensino'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (520,'Ens - Edificação de educação superior – Graduação (520)','Edificação de ensino'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (521,'Ens - Edificação de educação superior – graduação e pós-graduação (521)','Edificação de ensino'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (522,'Ens - Edificação de educação superior – pós-graduação e extensão (522)','Edificação de ensino'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (523,'Ens - Edificação de educação professional de nível técnico (523)','Edificação de ensino'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (524,'Ens - Edificação de educação profissional de nível tecnológico (524)','Edificação de ensino'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (525,'Ens - Outras atividades de ensino (525)','Edificação de ensino'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (601,'Rel - Igreja cristã (601)','Edificação religiosa'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (602,'Rel - Templo (602)','Edificação religiosa'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (603,'Rel - Centro religioso (603)','Edificação religiosa'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (604,'Rel - Mosteiro (604)','Edificação religiosa'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (605,'Rel - Convento (605)','Edificação religiosa'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (606,'Rel - Mesquita (606)','Edificação religiosa'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (607,'Rel - Sinagoga (607)','Edificação religiosa'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (608,'Rel - Capela Mortuária (608)','Edificação religiosa'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (609,'Rel - Terreiro (609)','Edificação religiosa'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (610,'Rel - Administração (610)','Edificação religiosa'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (611,'Rel - Igreja não cristã (611)','Edificação religiosa'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (698,'Rel - Outros (698)','Edificação religiosa'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (709,'Tur - Cruzeiro (709)','Edificação ou construção turística'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (710,'Tur - Estátua (710)','Edificação ou construção turística'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (711,'Tur - Mirante (711)','Edificação ou construção turística'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (712,'Tur - Monumento (712)','Edificação ou construção turística'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (713,'Tur - Panteão (713)','Edificação ou construção turística'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (798,'Tur - Outros (798)','Edificação ou construção turística'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (801,'Laz - Estádio (801)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (802,'Laz - Ginásio (802)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (803,'Laz - Museu (803)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (804,'Laz - Teatro (804)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (805,'Laz - Anfiteatro (805)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (806,'Laz - Espaço de exibição de filmes (806)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (807,'Laz - Centro cultural (807)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (808,'Laz - Plataforma de pesca (808)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (809,'Laz - Arquivo (809)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (810,'Laz - Biblioteca (810)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (811,'Laz - Centro de documentação (811)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (812,'Laz - Circo (812)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (813,'Laz - Concha acústica (813)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (814,'Laz - Conservatório (814)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (815,'Laz - Coreto ou tribuna (815)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (817,'Laz - Equipamentos culturais diversos (817)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (818,'Laz - Espaço de eventos e/ou cultural (818)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (819,'Laz - Galeria (819)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (898,'Laz - Outros (898)','Edificação de lazer'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (903,'Comerc - Centro comercial (903)','Edificação de comércio e serviço'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (904,'Comerc - Mercado (904)','Edificação de comércio e serviço'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (905,'Comerc - Centro de convenções (905)','Edificação de comércio e serviço'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (907,'Comerc - Hotel / motel / pousada (907)','Edificação de comércio e serviço'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (908,'Comerc - Banco (908)','Edificação de comércio e serviço'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (909,'Comerc - Centro de exposições (909)','Edificação de comércio e serviço'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (910,'Comerc - Mercado público (910)','Edificação de comércio e serviço'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (998,'Comerc - Outros (998)','Edificação de comércio e serviço'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1015,'Ind - Fabricação alimentícia e bebidas (1015)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1016,'Ind - Fabricação de produtos do fumo (1016)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1017,'Ind - Fabricação de produtos têxteis (1017)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1018,'Ind - Confecção de artigos de vestuário e acessórios (1018)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1019,'Ind - Preparação de couros, artefatos de couro, artigos de viagem e calçados (1019)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1020,'Ind - Fabricação de produtos de madeira e celulose (1020)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1021,'Ind - Fabricação de celulose, papel e produtos de papel (1021)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1022,'Ind - Industria de edição, impressão e reprodução de gravações (1022)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1023,'Ind - Fabricação de coque, refino de petróleo, elaboração de combustíveis nucleares e produção de álcool (1023)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1024,'Ind - Fabricação de produtos químicos (1024)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1025,'Ind - Fabricação de artigos de borracha e material plástico (1025)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1026,'Ind - Fabricação de produtos de minerais não-metálicos (1026)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1027,'Ind - Indústria de metalurgia básica (1027)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1028,'Ind - Fabricação de produtos de metal (1028)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1029,'Ind - Fabricação de máquinas e equipamentos (1029)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1030,'Ind - Fabriação de máquinas de escritório e equipamentos de informática (1030)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1031,'Ind - Fabricação de máquinas, aparelhos e materiais elétricos (1031)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1032,'Ind - Fabricação de material eletrônico, de aparelhos e equipamentos de comunicações (1032)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1033,'Ind - Fabricação de equipamentos de instrumentação médico-hospitalares, instrumentos de precisão e ópticos, automação industrial, cronômetros e relógios (1033)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1034,'Ind - Fabricação e montagem de veículos automotores, reboques e carrocerias (1034)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1035,'Ind - Fabricação de outros equipamentos de transporte (1035)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1036,'Ind - Fabricação de móveis e indústrias diversas (1036)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1037,'Ind - Indústria reciclagem (1037)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1045,'Ind - Indústria de construção (1045)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1046,'Ind - Chaminé (1046)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1098,'Ind - Outros (1098)','Edificação industrial'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1110,'Ext Min - Extração de carvão mineral (1110)','Edificação de extração mineral'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1111,'Ext Min - Extração de petróleo e serviços relacionados (1111)','Edificação de extração mineral'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1113,'Ext Min - Extração de minerais metálicos (1113)','Edificação de extração mineral'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1114,'Ext Min - Extração de minerais não-metálicos (1114)','Edificação de extração mineral'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1198,'Ext Min - Outros (1198)','Edificação de extração mineral'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1212,'Agro - Sede operacional de fazenda (1212)','Edificação agropecuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1213,'Agro - Aviário (1213)','Edificação agropecuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1214,'Agro - Apiário (1214)','Edificação agropecuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1215,'Agro - Viveiro de plantas (1215)','Edificação agropecuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1216,'Agro - Viveiro para aquicultura (1216)','Edificação agropecuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1217,'Agro - Pocilga (1217)','Edificação agropecuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1218,'Agro - Curral (1218)','Edificação agropecuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1298,'Agro - Outros (1298)','Edificação agropecuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1303,'Pub Civ - Cartorial (1303)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1304,'Pub Civ - Gestão pública (1304)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1305,'Pub Civ - Eleitoral (1305)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1306,'Pub Civ - Produção ou pequisa pública (1306)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1307,'Pub Civ - Seguridade social (1307)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1308,'Pub Civ - Câmara municipal (1308)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1309,'Pub Civ - Assembléia legislativa (1309)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1310,'Pub Civ - Autarquia (1310)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1313,'Pub Civ - Fórum (1313)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1314,'Pub Civ - Fundação (1314)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1315,'Pub Civ - Procuradoria (1315)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1316,'Pub Civ - Secretaria (1316)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1322,'Pub Civ - Prefeitura (1322)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1398,'Pub Civ - Outros (1398)','Edificação pública civil'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1401,'Habitacão indigena isolada (1401)','Habitacão indigena'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1402,'Habitacão indigena coletiva (1402)','Habitacão indigena'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1501,'Edificação de medição de fenômenos (1501)','Medição de fenômenos'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1712,'Pub Mil - Aquartelamento (1712)','Edificação militar'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1717,'Pub Mil - Hotel de trânsito (1717)','Edificação militar'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1718,'Pub Mil - Delegacia de serviço militar (1718)','Edificação militar'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1724,'Pub Mil - Capitania dos portos (1724)','Edificação militar'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1798,'Pub Mil - Outros (1798)','Edificação militar'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1910,'Posto Fisc - Tributação (1910)','Posto fiscal'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1912,'Posto Fisc - Fiscalização sanitária (1912)','Posto fiscal'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1913,'Posto Fisc - Posto de pesagem (1913)','Posto fiscal'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1995,'Posto Fisc - Misto (1995)','Posto fiscal'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (1998,'Posto Fisc - Outros (1998)','Posto fiscal'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2025,'Sau - Atendimento hospitalar (2025)','Edificação de saúde'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2026,'Sau - Atendimento hospitalar especializado (2026)','Edificação de saúde'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2027,'Sau - Atendimento a urgência e emergências (pronto socorro) (2027)','Edificação de saúde'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2028,'Sau - Atenção ambulatorial (posto e centro de saúde) (2028)','Edificação de saúde'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2029,'Sau - Serviços de complementação diagnóstica ou terapêutica (2029)','Edificação de saúde'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2030,'Sau - Outras atividades relacionadas com a atenção à saúde (instituto de pesquisa) (2030)','Edificação de saúde'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2031,'Sau - Serviços veterinários (2031)','Edificação de saúde'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2101,'Ssoc – Serviço Social (2101)','Edificação de desenvolvimento social'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2208,'Rod - Terminal interestadual (2208)','Edificação rodoviária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2209,'Rod - Terminal urbano (2209)','Edificação rodoviária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2210,'Rod - Parada interestadual (2210)','Edificação rodoviária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2213,'Rod - Posto de pedágio (2213)','Edificação rodoviária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2298,'Rod - Outros (2298)','Edificação rodoviária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2316,'Ferrov - Estação ferroviária de passageiros (2316)','Edificação ferroviária ou metroviária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2317,'Ferrov - Estação metroviária (2317)','Edificação ferroviária ou metroviária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2318,'Ferrov - Terminal ferroviário de cargas (2318)','Edificação ferroviária ou metroviária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2319,'Ferrov - Terminal ferroviário de passageiros e cargas (2319)','Edificação ferroviária ou metroviária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2320,'Ferrov - Oficina de manutenção (2320)','Edificação ferroviária ou metroviária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2321,'Ferrov - Administração (2321)','Edificação ferroviária ou metroviária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2398,'Ferrov - Outros (2398)','Edificação ferroviária ou metroviária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2426,'Aero - Terminal de passageiros (2426)','Edificação aeroportuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2427,'Aero - Terminal de cargas (2427)','Edificação aeroportuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2428,'Aero - Torre de controle (2428)','Edificação aeroportuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2429,'Aero - Hangar (2429)','Edificação aeroportuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2430,'Aero - Serviço de Combate à incendios (SCI) (2430)','Edificação aeroportuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2431,'Aero - Administração (2431)','Edificação aeroportuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2498,'Aero - Outros (2498)','Edificação aeroportuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2501,'Port - Edificação portuária (2501)','Edificação portuária'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2601,'Posto de combustivel (2601)','Posto de combustivel'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2901,'Dip – Consulado (2901)','Representação diplomática'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (2902,'Dip – Embaixada (2902)','Representação diplomática'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3001,'Seg – Delegacia de polícia civil (3001)','Edificação de segurança pública'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3002,'Seg – Posto policia militar (3002)','Edificação de segurança pública'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3003,'Seg – Posto guarda municipal (3003)','Edificação de segurança pública'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3004,'Seg – Posto de polícia rodoviária federal (3004)','Edificação de segurança pública'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3005,'Seg – Polícia militar (3005)','Edificação de segurança pública'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3006,'Seg - Prisional (3006)','Edificação de segurança pública'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3007,'Seg - Bombeiros Militar (3007)','Edificação de segurança pública'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3008,'Seg - Bombeiros Civil (3008)','Edificação de segurança pública'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (3098,'Seg – Outras polícias (3098)','Edificação de segurança pública'); +INSERT INTO dominios.tipo_edificacao (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_edificacao OWNER TO postgres; CREATE TABLE dominios.tipo_alteracao_fisiografica ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_alteracao_fisiografica_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_alteracao_fisiografica (code,code_name) VALUES (26,'Corte (26)')# -INSERT INTO dominios.tipo_alteracao_fisiografica (code,code_name) VALUES (27,'Aterro (27)')# -INSERT INTO dominios.tipo_alteracao_fisiografica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_alteracao_fisiografica (code,code_name) VALUES (26,'Corte (26)'); +INSERT INTO dominios.tipo_alteracao_fisiografica (code,code_name) VALUES (27,'Aterro (27)'); +INSERT INTO dominios.tipo_alteracao_fisiografica (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_alteracao_fisiografica OWNER TO postgres# +ALTER TABLE dominios.tipo_alteracao_fisiografica OWNER TO postgres; CREATE TABLE dominios.tipo_elemento_fisiografico ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_elemento_fisiografico_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (8,'Escarpa (8)')# -INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (13,'Falésia (13)')# -INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (14,'Talude (14)')# -INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (15,'Dolina (15)')# -INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (16,'Duna (16)')# -INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (19,'Gruta (19)')# -INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (20,'Caverna (20)')# -INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (21,'Rocha - Matacão/pedra (21)')# -INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (22,'Rocha - Penedo isolado (22)')# -INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (23,'Rocha - Area rochosa/lajedo (23)')# -INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_elemento_fisiografico OWNER TO postgres# +); + +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (8,'Escarpa (8)'); +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (13,'Falésia (13)'); +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (14,'Talude (14)'); +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (15,'Dolina (15)'); +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (16,'Duna (16)'); +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (19,'Gruta (19)'); +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (20,'Caverna (20)'); +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (21,'Rocha - Matacão/pedra (21)'); +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (22,'Rocha - Penedo isolado (22)'); +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (23,'Rocha - Area rochosa/lajedo (23)'); +INSERT INTO dominios.tipo_elemento_fisiografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_elemento_fisiografico OWNER TO postgres; CREATE TABLE dominios.tipo_toponimo_fisiografico ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_toponimo_fisiografico_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (1,'Serra (1)')# -INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (2,'Morro (2)')# -INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (3,'Montanha (3)')# -INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (4,'Chapada (4)')# -INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (5,'Maciço (5)')# -INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (6,'Planalto (6)')# -INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (7,'Planície (7)')# -INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (9,'Península (9)')# -INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (10,'Ponta (10)')# -INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (11,'Cabo (11)')# -INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (12,'Praia (12)')# -INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (17,'Pico (17)')# -INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_toponimo_fisiografico OWNER TO postgres# +); + +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (1,'Serra (1)'); +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (2,'Morro (2)'); +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (3,'Montanha (3)'); +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (4,'Chapada (4)'); +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (5,'Maciço (5)'); +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (6,'Planalto (6)'); +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (7,'Planície (7)'); +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (9,'Península (9)'); +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (10,'Ponta (10)'); +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (11,'Cabo (11)'); +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (12,'Praia (12)'); +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (17,'Pico (17)'); +INSERT INTO dominios.tipo_toponimo_fisiografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_toponimo_fisiografico OWNER TO postgres; CREATE TABLE dominios.tipo_ilha ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_ilha_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (1,'Fluvial (1)')# -INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (2,'Marítima (2)')# -INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (3,'Lacustre (3)')# -INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (1,'Fluvial (1)'); +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (2,'Marítima (2)'); +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (3,'Lacustre (3)'); +INSERT INTO dominios.tipo_ilha (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_ilha OWNER TO postgres# +ALTER TABLE dominios.tipo_ilha OWNER TO postgres; CREATE TABLE dominios.tipo_elemento_hidrografico ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_elemento_hidrografico_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (1,'Poço dágua (1)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (2,'Poço artesiano (2)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (3,'Olho dágua (3)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (6,'Foz marítima (6)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (8,'Rocha em água (8)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (9,'Cachoeira (9)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (10,'Salto (10)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (11,'Catarata (11)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (12,'Corredeira (12)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (14,'Banco de areia fluvial (14)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (15,'Banco de areia marítimo (15)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (16,'Banco de areia lacustre (16)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (17,'Banco de areia cordão arenoso (17)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (18,'Recife contiguo (18)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (19,'Recife afastado (19)')# -INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_elemento_hidrografico OWNER TO postgres# +); + +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (1,'Poço dágua (1)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (2,'Poço artesiano (2)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (3,'Olho dágua (3)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (6,'Foz marítima (6)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (8,'Rocha em água (8)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (9,'Cachoeira (9)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (10,'Salto (10)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (11,'Catarata (11)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (12,'Corredeira (12)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (14,'Banco de areia fluvial (14)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (15,'Banco de areia marítimo (15)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (16,'Banco de areia lacustre (16)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (17,'Banco de areia cordão arenoso (17)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (18,'Recife contiguo (18)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (19,'Recife afastado (19)'); +INSERT INTO dominios.tipo_elemento_hidrografico (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_elemento_hidrografico OWNER TO postgres; CREATE TABLE dominios.tipo_elemento_energia ( code smallint NOT NULL, code_name text NOT NULL, filter text NOT NULL, CONSTRAINT tipo_elemento_energia_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (302,'Linha de distribuição de energia (302)','Linha de energia')# -INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (303,'Linha de transmissão de energia (303)','Linha de energia')# -INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (405,'Estação geradora – Eólica (405)','Estação geradora de energia')# -INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (408,'Estação geradora – Hidrelétrica (408)','Estação geradora de energia')# -INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (407,'Estação geradora – Maré-motriz (407)','Estação geradora de energia')# -INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (498,'Estação geradora – Outras (498)','Estação geradora de energia')# -INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (406,'Estação geradora – Solar (406)','Estação geradora de energia')# -INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (409,'Estação geradora – Termelétrica (409)','Estação geradora de energia')# -INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (1401,'Torre de energia (1401)','Torre de energia')# -INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (1701,'Aerogerador (1701)','Aerogerador')# -INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (1801,'Subestação de transmissão de energia elétrica (1801)','Subestação de energia')# -INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (1802,'Subestação de distribuição de energia elétrica (1802)','Subestação de energia')# -INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_elemento_energia OWNER TO postgres# +); + +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (302,'Linha de distribuição de energia (302)','Linha de energia'); +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (303,'Linha de transmissão de energia (303)','Linha de energia'); +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (405,'Estação geradora – Eólica (405)','Estação geradora de energia'); +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (408,'Estação geradora – Hidrelétrica (408)','Estação geradora de energia'); +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (407,'Estação geradora – Maré-motriz (407)','Estação geradora de energia'); +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (498,'Estação geradora – Outras (498)','Estação geradora de energia'); +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (406,'Estação geradora – Solar (406)','Estação geradora de energia'); +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (409,'Estação geradora – Termelétrica (409)','Estação geradora de energia'); +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (1401,'Torre de energia (1401)','Torre de energia'); +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (1701,'Aerogerador (1701)','Aerogerador'); +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (1801,'Subestação de transmissão de energia elétrica (1801)','Subestação de energia'); +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (1802,'Subestação de distribuição de energia elétrica (1802)','Subestação de energia'); +INSERT INTO dominios.tipo_elemento_energia (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_elemento_energia OWNER TO postgres; CREATE TABLE dominios.tipo_elemento_infraestrutura ( code smallint NOT NULL, code_name text NOT NULL, filter text NOT NULL, CONSTRAINT tipo_elemento_infraestrutura_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (701,'Quebramar (701)','Quebramar')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (801,'Molhe (801)','Molhe')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (901,'Comporta (901)','Comporta')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1001,'Eclusa (1001)','Eclusa')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1201,'Torre de comunicação (1201)','Torre de comunicação')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1301,'Antena de comunicação (1301)','Antena de comunicação')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1400,'Plataforma- Desconhecido (1400)','Plataforma')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1401,'Plataforma- Petróleo (1401)','Plataforma')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1402,'Plataforma- Gás (1402)','Plataforma')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1495,'Plataforma- Mista (1495)','Plataforma')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1501,'Funicular (1501)','Funicular')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1601,'Cremalheira (1601)','Cremalheira')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1701,'Girador Ferroviário (1701)','Girador Ferroviário')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1801,'Fundeadouro (1801)','Fundeadouro')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1938,'Atrac - Cais (1938)','Atracadouro Terminal')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1939,'Atrac - Cais flutuante (1939)','Atracadouro Terminal')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1940,'Atrac - Trapiche (1940)','Atracadouro Terminal')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1941,'Atrac - Molhe de atracação (1941)','Atracadouro Terminal')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1942,'Atrac - Pier (1942)','Atracadouro Terminal')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1943,'Atrac - Dolfim (1943)','Atracadouro Terminal')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1944,'Atrac - Desembarcadouro (1944)','Atracadouro Terminal')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (2001,'Caminho Aéreo – Teleférico (2001)','Caminho Aéreo')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (2098,'Caminho Aéreo – Outros (2098)','Caminho Aéreo')# -INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_elemento_infraestrutura OWNER TO postgres# +); + +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (701,'Quebramar (701)','Quebramar'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (801,'Molhe (801)','Molhe'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (901,'Comporta (901)','Comporta'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1001,'Eclusa (1001)','Eclusa'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1201,'Torre de comunicação (1201)','Torre de comunicação'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1301,'Antena de comunicação (1301)','Antena de comunicação'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1400,'Plataforma- Desconhecido (1400)','Plataforma'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1401,'Plataforma- Petróleo (1401)','Plataforma'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1402,'Plataforma- Gás (1402)','Plataforma'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1495,'Plataforma- Mista (1495)','Plataforma'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1501,'Funicular (1501)','Funicular'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1601,'Cremalheira (1601)','Cremalheira'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1701,'Girador Ferroviário (1701)','Girador Ferroviário'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1801,'Fundeadouro (1801)','Fundeadouro'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1938,'Atrac - Cais (1938)','Atracadouro Terminal'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1939,'Atrac - Cais flutuante (1939)','Atracadouro Terminal'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1940,'Atrac - Trapiche (1940)','Atracadouro Terminal'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1941,'Atrac - Molhe de atracação (1941)','Atracadouro Terminal'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1942,'Atrac - Pier (1942)','Atracadouro Terminal'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1943,'Atrac - Dolfim (1943)','Atracadouro Terminal'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (1944,'Atrac - Desembarcadouro (1944)','Atracadouro Terminal'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (2001,'Caminho Aéreo – Teleférico (2001)','Caminho Aéreo'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (2098,'Caminho Aéreo – Outros (2098)','Caminho Aéreo'); +INSERT INTO dominios.tipo_elemento_infraestrutura (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_elemento_infraestrutura OWNER TO postgres; CREATE TABLE dominios.tipo_mobilidade_urbana ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_mobilidade_urbana_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_mobilidade_urbana (code,code_name) VALUES (1,'Calçadão / Rua pedestre (1)')# -INSERT INTO dominios.tipo_mobilidade_urbana (code,code_name) VALUES (2,'Ciclovia (2)')# -INSERT INTO dominios.tipo_mobilidade_urbana (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_mobilidade_urbana (code,code_name) VALUES (1,'Calçadão / Rua pedestre (1)'); +INSERT INTO dominios.tipo_mobilidade_urbana (code,code_name) VALUES (2,'Ciclovia (2)'); +INSERT INTO dominios.tipo_mobilidade_urbana (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_mobilidade_urbana OWNER TO postgres# +ALTER TABLE dominios.tipo_mobilidade_urbana OWNER TO postgres; CREATE TABLE dominios.tipo_trecho_duto ( code smallint NOT NULL, code_name text NOT NULL, filter text NOT NULL, CONSTRAINT tipo_trecho_duto_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (101,'Calha - Água pluvial (101)','Calha')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (201,'Correia transp - Minério (201)','Correia transportadora')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (202,'Correia transp - Grãos (202)','Correia transportadora')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (298,'Correia transp - Outros (298)','Correia transportadora')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (300,'Duto – Desconhecido (300)','Duto')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (301,'Duto – Água (301)','Duto')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (302,'Duto – Óleo (302)','Duto')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (303,'Duto – Gasolina (303)','Duto')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (304,'Duto – Álcool (304)','Duto')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (305,'Duto – Querosene (305)','Duto')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (306,'Duto – Petróleo (306)','Duto')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (307,'Duto – Nafta (307)','Duto')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (308,'Duto – Gás (308)','Duto')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (309,'Duto – Efluentes (309)','Duto')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (310,'Duto – Esgoto (310)','Duto')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (398,'Duto – Outros (398)','Duto')# -INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_trecho_duto OWNER TO postgres# +); + +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (101,'Calha - Água pluvial (101)','Calha'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (201,'Correia transp - Minério (201)','Correia transportadora'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (202,'Correia transp - Grãos (202)','Correia transportadora'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (298,'Correia transp - Outros (298)','Correia transportadora'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (300,'Duto – Desconhecido (300)','Duto'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (301,'Duto – Água (301)','Duto'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (302,'Duto – Óleo (302)','Duto'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (303,'Duto – Gasolina (303)','Duto'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (304,'Duto – Álcool (304)','Duto'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (305,'Duto – Querosene (305)','Duto'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (306,'Duto – Petróleo (306)','Duto'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (307,'Duto – Nafta (307)','Duto'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (308,'Duto – Gás (308)','Duto'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (309,'Duto – Efluentes (309)','Duto'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (310,'Duto – Esgoto (310)','Duto'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (398,'Duto – Outros (398)','Duto'); +INSERT INTO dominios.tipo_trecho_duto (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_trecho_duto OWNER TO postgres; CREATE TABLE dominios.tipo_travessia ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_travessia_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (1,'Balsa (1)')# -INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (2,'Bote transportador (2)')# -INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (1,'Balsa (1)'); +INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (2,'Bote transportador (2)'); +INSERT INTO dominios.tipo_travessia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_travessia OWNER TO postgres# +ALTER TABLE dominios.tipo_travessia OWNER TO postgres; CREATE TABLE dominios.tipo_elemento_viario ( code smallint NOT NULL, code_name text NOT NULL, filter text NOT NULL, CONSTRAINT tipo_elemento_viario_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (101,'Túnel (101)','Túnel')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (102,'Túnel - Passagem subterrânea sob via (102)','Túnel')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (201,'Ponte móvel (201)','Ponte')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (202,'Ponte pênsil (202)','Ponte')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (203,'Ponte fixa (203)','Ponte')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (204,'Ponte estaiada (204)','Ponte')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (301,'Passagem elevada (301)','Passagem elevada / Viaduto')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (302,'Viaduto (302)','Passagem elevada / Viaduto')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (401,'Travessia - Vau natural (401)','Travessia')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (402,'Travessia - Vau construído (402)','Travessia')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (501,'Galeria/Bueiro (501)','Galeria/Bueiro')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (607,'Pedestre - Passagem subterrânea (607)','Travessia pedestre')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (608,'Pedestre - Passarela (608)','Travessia pedestre')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (609,'Pedestre - Pinguela (609)','Travessia pedestre')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (701,'Ferrov - Passagem em nível (701)','Cruzamento ferroviário')# -INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_elemento_viario OWNER TO postgres# +); + +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (101,'Túnel (101)','Túnel'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (102,'Túnel - Passagem subterrânea sob via (102)','Túnel'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (201,'Ponte móvel (201)','Ponte'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (202,'Ponte pênsil (202)','Ponte'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (203,'Ponte fixa (203)','Ponte'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (204,'Ponte estaiada (204)','Ponte'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (301,'Passagem elevada (301)','Passagem elevada / Viaduto'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (302,'Viaduto (302)','Passagem elevada / Viaduto'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (401,'Travessia - Vau natural (401)','Travessia'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (402,'Travessia - Vau construído (402)','Travessia'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (501,'Galeria/Bueiro (501)','Galeria/Bueiro'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (607,'Pedestre - Passagem subterrânea (607)','Travessia pedestre'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (608,'Pedestre - Passarela (608)','Travessia pedestre'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (609,'Pedestre - Pinguela (609)','Travessia pedestre'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (701,'Ferrov - Passagem em nível (701)','Cruzamento ferroviário'); +INSERT INTO dominios.tipo_elemento_viario (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_elemento_viario OWNER TO postgres; CREATE TABLE dominios.tipo_exposicao ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_exposicao_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (0,'Desconhecido (0)')# -INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (3,'Fechado (3)')# -INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (4,'Coberto (4)')# -INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (5,'Céu aberto (5)')# -INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (97,'Não aplicável (97)')# -INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (0,'Desconhecido (0)'); +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (3,'Fechado (3)'); +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (4,'Coberto (4)'); +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (5,'Céu aberto (5)'); +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (97,'Não aplicável (97)'); +INSERT INTO dominios.tipo_exposicao (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_exposicao OWNER TO postgres# +ALTER TABLE dominios.tipo_exposicao OWNER TO postgres; CREATE TABLE dominios.tipo_extracao_mineral ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_extracao_mineral_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (1,'Poço - água subterrânea (1)')# -INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (4,'Mina / Pedreira (4)')# -INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (5,'Garimpo (5)')# -INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (6,'Salina (6)')# -INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (8,'Poço - petróleo (8)')# -INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (1,'Poço - água subterrânea (1)'); +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (4,'Mina / Pedreira (4)'); +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (5,'Garimpo (5)'); +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (6,'Salina (6)'); +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (8,'Poço - petróleo (8)'); +INSERT INTO dominios.tipo_extracao_mineral (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_extracao_mineral OWNER TO postgres# +ALTER TABLE dominios.tipo_extracao_mineral OWNER TO postgres; CREATE TABLE dominios.tipo_ferrovia ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_ferrovia_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (5,'Bonde (5)')# -INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (6,'Aeromóvel (6)')# -INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (7,'Trem (7)')# -INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (8,'Metrô (8)')# -INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (5,'Bonde (5)'); +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (6,'Aeromóvel (6)'); +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (7,'Trem (7)'); +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (8,'Metrô (8)'); +INSERT INTO dominios.tipo_ferrovia (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_ferrovia OWNER TO postgres# +ALTER TABLE dominios.tipo_ferrovia OWNER TO postgres; CREATE TABLE dominios.tipo_limite_especial ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_limite_especial_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (2,'Terra indígena (2)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (5,'Unidade de Conservação (5)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (24,'Área de Proteção Ambiental – APA (24)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (25,'Área de Relevante Interesse Ecológico – ARIE (25)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (26,'Floresta – FLO (26)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (27,'Reserva de Desenvolvimento Sustentável – RDS (27)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (28,'Reserva Extrativista – RESEX (28)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (29,'Reserva de Fauna – REFAU (29)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (30,'Reserva Particular do Patrimônio Natural – RPPN (30)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (31,'Estação Ecológica – ESEC (31)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (32,'Parque – PAR (32)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (33,'Monumento Natural – MONA (33)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (34,'Reserva Biológica – REBIO (34)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (35,'Refúgio de Vida Silvestre – RVS (35)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (36,'Área militar (36)')# -INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_limite_especial OWNER TO postgres# +); + +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (2,'Terra indígena (2)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (5,'Unidade de Conservação (5)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (24,'Área de Proteção Ambiental – APA (24)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (25,'Área de Relevante Interesse Ecológico – ARIE (25)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (26,'Floresta – FLO (26)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (27,'Reserva de Desenvolvimento Sustentável – RDS (27)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (28,'Reserva Extrativista – RESEX (28)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (29,'Reserva de Fauna – REFAU (29)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (30,'Reserva Particular do Patrimônio Natural – RPPN (30)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (31,'Estação Ecológica – ESEC (31)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (32,'Parque – PAR (32)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (33,'Monumento Natural – MONA (33)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (34,'Reserva Biológica – REBIO (34)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (35,'Refúgio de Vida Silvestre – RVS (35)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (36,'Área militar (36)'); +INSERT INTO dominios.tipo_limite_especial (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_limite_especial OWNER TO postgres; CREATE TABLE dominios.tipo_limite_legal ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_limite_legal_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_limite_legal (code,code_name) VALUES (1,'Limite Internacional (1)')# -INSERT INTO dominios.tipo_limite_legal (code,code_name) VALUES (2,'Limite Estadual (2)')# -INSERT INTO dominios.tipo_limite_legal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_limite_legal (code,code_name) VALUES (1,'Limite Internacional (1)'); +INSERT INTO dominios.tipo_limite_legal (code,code_name) VALUES (2,'Limite Estadual (2)'); +INSERT INTO dominios.tipo_limite_legal (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_limite_legal OWNER TO postgres# +ALTER TABLE dominios.tipo_limite_legal OWNER TO postgres; CREATE TABLE dominios.tipo_localidade ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_localidade_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (1,'Cidade (1)')# -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (2,'Capital estadual (2)')# -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (3,'Capital federal (3)')# -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (4,'Vila (4)')# -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (5,'Aglomerado rural isolado – Núcleo (5)')# -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (6,'Aglomerado rural isolado – Povoado (6)')# -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (7,'Outros aglomerados rurais – Lugarejo (7)')# -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (8,'Nome local (8)')# -INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (1,'Cidade (1)'); +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (2,'Capital estadual (2)'); +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (3,'Capital federal (3)'); +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (4,'Vila (4)'); +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (5,'Aglomerado rural isolado – Núcleo (5)'); +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (6,'Aglomerado rural isolado – Povoado (6)'); +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (7,'Outros aglomerados rurais – Lugarejo (7)'); +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (8,'Nome local (8)'); +INSERT INTO dominios.tipo_localidade (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_localidade OWNER TO postgres# +ALTER TABLE dominios.tipo_localidade OWNER TO postgres; CREATE TABLE dominios.tipo_ocupacao_solo ( code smallint NOT NULL, code_name text NOT NULL, filter text NOT NULL, CONSTRAINT tipo_ocupacao_solo_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (101,'Cemitério - Crematório (101)','Cemitério')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (102,'Cemitério Parque (102)','Cemitério')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (103,'Cemitério Vertical (103)','Cemitério')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (104,'Cemitério Comum - Cristã (104)','Cemitério')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (105,'Cemitério - Túmulo isolado (105)','Cemitério')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (106,'Cemitério Comum - Muçulmana (106)','Cemitério')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (107,'Cemitério Comum - Israelita (107)','Cemitério')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (108,'Cemitério Comum - Outras religiões (108)','Cemitério')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (201,'Campo/Quadra de futebol (201)','Campo ou quadra')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (202,'Campo/Quadra de basquete (202)','Campo ou quadra')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (203,'Campo/Quadra de vôlei (203)','Campo ou quadra')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (204,'Campo/Quadra de pólo (204)','Campo ou quadra')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (205,'Campo/Quadra de hipismo (205)','Campo ou quadra')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (206,'Campo/Quadra poliesportiva (206)','Campo ou quadra')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (207,'Campo/Quadra de tênis (207)','Campo ou quadra')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (298,'Campo/Quadra - Outras quadras esportivas (298)','Campo ou quadra')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (301,'Pista de atletismo (301)','Pista competição')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (302,'Pista de ciclismo (302)','Pista competição')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (303,'Pista de motociclismo (303)','Pista competição')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (304,'Pista de automobilismo (304)','Pista competição')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (305,'Pista de corrida de cavalos (305)','Pista competição')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (306,'Pista de bicicross (306)','Pista competição')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (307,'Pista de motocross (307)','Pista competição')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (398,'Pista - Outras pistas de competição (398)','Pista competição')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (404,'Pátio rodoviário (404)','Pátio')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (405,'Pátio ferroviário (405)','Pátio')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (406,'Pátio metroviário (406)','Pátio')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (409,'Pátio aeroportuário (409)','Pátio')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (414,'Pátio portuário (414)','Pátio')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (415,'Pátio hidroviário (415)','Pátio')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (416,'Pátio de dutos (416)','Pátio')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (501,'Piscina (501)','Piscina')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (601,'Sítio Arqueológico (601)','Sítio Arqueológico')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (701,'Ruína (701)','Ruína')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (801,'Moega (801)','Equipamento agropecuário')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (802,'Moinho (802)','Equipamento agropecuário')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (803,'Secador (803)','Equipamento agropecuário')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (804,'Tombador (804)','Equipamento agropecuário')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (805,'Elevador de grãos (805)','Equipamento agropecuário')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (806,'Pivô central (806)','Equipamento agropecuário')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (901,'Estacionamento (901)','Estacionamento')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1001,'Arquibancada (1001)','Arquibancada')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1101,'Farol ou farolete (1101)','Farol')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1601,'Estação climatológica principal (1601)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1602,'Estação climatológica auxiliar (1602)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1603,'Estação agroclimatológica (1603)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1604,'Estação pluviométrica (1604)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1605,'Estação eólica (1605)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1606,'Estação evaporimétrica (1606)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1607,'Estação solarimétrica (1607)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1608,'Estação de radar meteorológico (1608)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1609,'Estação de rádiosonda (1609)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1610,'Estação fluviométrica (1610)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1611,'Estação maregráfica (1611)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1612,'Estação mares terrestres - crosta (1612)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1613,'Estação Metero-maregráfica (1613)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1614,'Estação Hidrológica (1614)','Ponto de estacão de medição de fenômenos')# -INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_ocupacao_solo OWNER TO postgres# +); + +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (101,'Cemitério - Crematório (101)','Cemitério'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (102,'Cemitério Parque (102)','Cemitério'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (103,'Cemitério Vertical (103)','Cemitério'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (104,'Cemitério Comum - Cristã (104)','Cemitério'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (105,'Cemitério - Túmulo isolado (105)','Cemitério'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (106,'Cemitério Comum - Muçulmana (106)','Cemitério'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (107,'Cemitério Comum - Israelita (107)','Cemitério'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (108,'Cemitério Comum - Outras religiões (108)','Cemitério'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (201,'Campo/Quadra de futebol (201)','Campo ou quadra'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (202,'Campo/Quadra de basquete (202)','Campo ou quadra'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (203,'Campo/Quadra de vôlei (203)','Campo ou quadra'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (204,'Campo/Quadra de pólo (204)','Campo ou quadra'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (205,'Campo/Quadra de hipismo (205)','Campo ou quadra'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (206,'Campo/Quadra poliesportiva (206)','Campo ou quadra'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (207,'Campo/Quadra de tênis (207)','Campo ou quadra'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (298,'Campo/Quadra - Outras quadras esportivas (298)','Campo ou quadra'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (301,'Pista de atletismo (301)','Pista competição'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (302,'Pista de ciclismo (302)','Pista competição'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (303,'Pista de motociclismo (303)','Pista competição'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (304,'Pista de automobilismo (304)','Pista competição'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (305,'Pista de corrida de cavalos (305)','Pista competição'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (306,'Pista de bicicross (306)','Pista competição'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (307,'Pista de motocross (307)','Pista competição'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (398,'Pista - Outras pistas de competição (398)','Pista competição'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (404,'Pátio rodoviário (404)','Pátio'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (405,'Pátio ferroviário (405)','Pátio'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (406,'Pátio metroviário (406)','Pátio'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (409,'Pátio aeroportuário (409)','Pátio'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (414,'Pátio portuário (414)','Pátio'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (415,'Pátio hidroviário (415)','Pátio'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (416,'Pátio de dutos (416)','Pátio'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (501,'Piscina (501)','Piscina'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (601,'Sítio Arqueológico (601)','Sítio Arqueológico'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (701,'Ruína (701)','Ruína'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (801,'Moega (801)','Equipamento agropecuário'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (802,'Moinho (802)','Equipamento agropecuário'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (803,'Secador (803)','Equipamento agropecuário'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (804,'Tombador (804)','Equipamento agropecuário'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (805,'Elevador de grãos (805)','Equipamento agropecuário'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (806,'Pivô central (806)','Equipamento agropecuário'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (901,'Estacionamento (901)','Estacionamento'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1001,'Arquibancada (1001)','Arquibancada'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1101,'Farol ou farolete (1101)','Farol'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1601,'Estação climatológica principal (1601)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1602,'Estação climatológica auxiliar (1602)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1603,'Estação agroclimatológica (1603)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1604,'Estação pluviométrica (1604)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1605,'Estação eólica (1605)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1606,'Estação evaporimétrica (1606)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1607,'Estação solarimétrica (1607)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1608,'Estação de radar meteorológico (1608)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1609,'Estação de rádiosonda (1609)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1610,'Estação fluviométrica (1610)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1611,'Estação maregráfica (1611)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1612,'Estação mares terrestres - crosta (1612)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1613,'Estação Metero-maregráfica (1613)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (1614,'Estação Hidrológica (1614)','Ponto de estacão de medição de fenômenos'); +INSERT INTO dominios.tipo_ocupacao_solo (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_ocupacao_solo OWNER TO postgres; CREATE TABLE dominios.tipo_pista_pouso ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_pista_pouso_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (9,'Pista de pouso (9)')# -INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (10,'Pista de táxi (10)')# -INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (11,'Heliponto (11)')# -INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (9,'Pista de pouso (9)'); +INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (10,'Pista de táxi (10)'); +INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (11,'Heliponto (11)'); +INSERT INTO dominios.tipo_pista_pouso (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_pista_pouso OWNER TO postgres# +ALTER TABLE dominios.tipo_pista_pouso OWNER TO postgres; CREATE TABLE dominios.tipo_pto ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_pto_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (1,'Vértice de Triangulação – VT (1)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (2,'Referëncia de Nível – RN (2)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (3,'Estação Gravimétrica – EG (3)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (4,'Estação de Poligonal – EP (4)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (5,'Ponto Astronômico – PA (5)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (6,'Ponto Barométrico – B (6)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (7,'Ponto Trigonométrico – RV (7)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (8,'Ponto de Satélite – SAT (8)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (9,'Ponto de controle (9)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (12,'Centro perspectivo (12)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (13,'Ponto fotogramétrico (13)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (14,'Marco internacional (14)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (15,'Marco estadual (15)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (16,'Marco municipal (16)')# -INSERT INTO dominios.tipo_pto (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_pto OWNER TO postgres# +); + +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (1,'Vértice de Triangulação – VT (1)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (2,'Referëncia de Nível – RN (2)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (3,'Estação Gravimétrica – EG (3)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (4,'Estação de Poligonal – EP (4)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (5,'Ponto Astronômico – PA (5)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (6,'Ponto Barométrico – B (6)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (7,'Ponto Trigonométrico – RV (7)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (8,'Ponto de Satélite – SAT (8)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (9,'Ponto de controle (9)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (12,'Centro perspectivo (12)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (13,'Ponto fotogramétrico (13)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (14,'Marco internacional (14)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (15,'Marco estadual (15)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (16,'Marco municipal (16)'); +INSERT INTO dominios.tipo_pto (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_pto OWNER TO postgres; CREATE TABLE dominios.tipo_ref ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_ref_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_ref (code,code_name) VALUES (1,'Altimétrico (1)')# -INSERT INTO dominios.tipo_ref (code,code_name) VALUES (2,'Planimétrico (2)')# -INSERT INTO dominios.tipo_ref (code,code_name) VALUES (3,'Planialtimétrico (3)')# -INSERT INTO dominios.tipo_ref (code,code_name) VALUES (4,'Gravimétrico (4)')# -INSERT INTO dominios.tipo_ref (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (1,'Altimétrico (1)'); +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (2,'Planimétrico (2)'); +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (3,'Planialtimétrico (3)'); +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (4,'Gravimétrico (4)'); +INSERT INTO dominios.tipo_ref (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_ref OWNER TO postgres# +ALTER TABLE dominios.tipo_ref OWNER TO postgres; CREATE TABLE dominios.tipo_trecho_drenagem ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_trecho_drenagem_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (1,'Rio (1)')# -INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (2,'Canal (2)')# -INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (3,'Trecho pluvial (3)')# -INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (4,'Canal encoberto (4)')# -INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (5,'Canal não operacional (5)')# -INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (1,'Rio (1)'); +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (2,'Canal (2)'); +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (3,'Trecho pluvial (3)'); +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (4,'Canal encoberto (4)'); +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (5,'Canal não operacional (5)'); +INSERT INTO dominios.tipo_trecho_drenagem (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_trecho_drenagem OWNER TO postgres# +ALTER TABLE dominios.tipo_trecho_drenagem OWNER TO postgres; CREATE TABLE dominios.tipo_hid ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_hid_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_hid (code,code_name) VALUES (1,'Rio (1)')# -INSERT INTO dominios.tipo_hid (code,code_name) VALUES (2,'Canal (2)')# -INSERT INTO dominios.tipo_hid (code,code_name) VALUES (3,'Oceano (3)')# -INSERT INTO dominios.tipo_hid (code,code_name) VALUES (4,'Baía (4)')# -INSERT INTO dominios.tipo_hid (code,code_name) VALUES (5,'Enseada (5)')# -INSERT INTO dominios.tipo_hid (code,code_name) VALUES (6,'Meando Abandonado (6)')# -INSERT INTO dominios.tipo_hid (code,code_name) VALUES (7,'Lago ou Lagoa (7)')# -INSERT INTO dominios.tipo_hid (code,code_name) VALUES (9,'Laguna (9)')# -INSERT INTO dominios.tipo_hid (code,code_name) VALUES (10,'Represa (10)')# -INSERT INTO dominios.tipo_hid (code,code_name) VALUES (11,'Açude (11)')# -INSERT INTO dominios.tipo_hid (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_hid OWNER TO postgres# +); + +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (1,'Rio (1)'); +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (2,'Canal (2)'); +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (3,'Oceano (3)'); +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (4,'Baía (4)'); +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (5,'Enseada (5)'); +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (6,'Meando Abandonado (6)'); +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (7,'Lago ou Lagoa (7)'); +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (9,'Laguna (9)'); +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (10,'Represa (10)'); +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (11,'Açude (11)'); +INSERT INTO dominios.tipo_hid (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_hid OWNER TO postgres; CREATE TABLE dominios.tipo_veg ( code smallint NOT NULL, code_name text NOT NULL, filter text NOT NULL, CONSTRAINT tipo_veg_pk PRIMARY KEY (code) -)# - -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (150,'Cult - Arroz de inundação (150)','Vegetação Cultivada')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (194,'Cult - Perene (194)','Vegetação Cultivada')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (196,'Cult - Anual irrigado (196)','Vegetação Cultivada')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (197,'Cult - Anual não irrigado (197)','Vegetação Cultivada')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (201,'Mangue (201)','Mangue')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (301,'Brejo/pântano (301)','Brejo ou pântano')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (401,'Restinga (401)','Restinga')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (501,'Campinarana (501)','Campinarana')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (601,'Floresta densa (601)','Floresta')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (602,'Floresta esparsa (602)','Floresta')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (701,'Cerrado/Cerradão (701)','Cerrado/Cerradão')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (801,'Caatinga (801)','Caatinga')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (901,'Campo (901)','Campo')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1000,'Terreno exposto - desconhecido (1000)','Terreno Exposto')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1001,'Terreno exposto - cascalho (1001)','Terreno Exposto')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1002,'Terreno exposto - areia (1002)','Terreno Exposto')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1003,'Terreno exposto - pedregoso (1003)','Terreno Exposto')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1296,'Reflorestamento (1296)','Reflorestamento')# -INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)')# - -ALTER TABLE dominios.tipo_veg OWNER TO postgres# +); + +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (150,'Cult - Arroz de inundação (150)','Vegetação Cultivada'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (194,'Cult - Perene (194)','Vegetação Cultivada'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (196,'Cult - Anual irrigado (196)','Vegetação Cultivada'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (197,'Cult - Anual não irrigado (197)','Vegetação Cultivada'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (201,'Mangue (201)','Mangue'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (301,'Brejo/pântano (301)','Brejo ou pântano'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (401,'Restinga (401)','Restinga'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (501,'Campinarana (501)','Campinarana'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (601,'Floresta densa (601)','Floresta'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (602,'Floresta esparsa (602)','Floresta'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (701,'Cerrado/Cerradão (701)','Cerrado/Cerradão'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (801,'Caatinga (801)','Caatinga'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (901,'Campo (901)','Campo'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1000,'Terreno exposto - desconhecido (1000)','Terreno Exposto'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1001,'Terreno exposto - cascalho (1001)','Terreno Exposto'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1002,'Terreno exposto - areia (1002)','Terreno Exposto'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1003,'Terreno exposto - pedregoso (1003)','Terreno Exposto'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (1296,'Reflorestamento (1296)','Reflorestamento'); +INSERT INTO dominios.tipo_veg (code,code_name, filter) VALUES (9999,'A SER PREENCHIDO (9999)','A SER PREENCHIDO (9999)'); + +ALTER TABLE dominios.tipo_veg OWNER TO postgres; CREATE TABLE dominios.tipo_via_deslocamento ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT tipo_via_deslocamento_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (2,'Estrada/Rodovia (2)')# -INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (3,'Caminho carroçável (3)')# -INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (4,'Auto-estrada (4)')# -INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (5,'Arruamento (5)')# -INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (6,'Trilha ou Picada (6)')# -INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (2,'Estrada/Rodovia (2)'); +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (3,'Caminho carroçável (3)'); +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (4,'Auto-estrada (4)'); +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (5,'Arruamento (5)'); +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (6,'Trilha ou Picada (6)'); +INSERT INTO dominios.tipo_via_deslocamento (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.tipo_via_deslocamento OWNER TO postgres# +ALTER TABLE dominios.tipo_via_deslocamento OWNER TO postgres; CREATE TABLE dominios.trafego ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT trafego_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.trafego (code,code_name) VALUES (0,'Desconhecido (0)')# -INSERT INTO dominios.trafego (code,code_name) VALUES (1,'Permanente (1)')# -INSERT INTO dominios.trafego (code,code_name) VALUES (2,'Periódico (2)')# -INSERT INTO dominios.trafego (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.trafego (code,code_name) VALUES (0,'Desconhecido (0)'); +INSERT INTO dominios.trafego (code,code_name) VALUES (1,'Permanente (1)'); +INSERT INTO dominios.trafego (code,code_name) VALUES (2,'Periódico (2)'); +INSERT INTO dominios.trafego (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.trafego OWNER TO postgres# +ALTER TABLE dominios.trafego OWNER TO postgres; CREATE TABLE dominios.uso_pista ( code smallint NOT NULL, code_name text NOT NULL, CONSTRAINT uso_pista_pk PRIMARY KEY (code) -)# +); -INSERT INTO dominios.uso_pista (code,code_name) VALUES (0,'Desconhecido (0)')# -INSERT INTO dominios.uso_pista (code,code_name) VALUES (6,'Particular (6)')# -INSERT INTO dominios.uso_pista (code,code_name) VALUES (11,'Público (11)')# -INSERT INTO dominios.uso_pista (code,code_name) VALUES (12,'Militar (12)')# -INSERT INTO dominios.uso_pista (code,code_name) VALUES (13,'Público/Militar (13)')# -INSERT INTO dominios.uso_pista (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)')# +INSERT INTO dominios.uso_pista (code,code_name) VALUES (0,'Desconhecido (0)'); +INSERT INTO dominios.uso_pista (code,code_name) VALUES (6,'Particular (6)'); +INSERT INTO dominios.uso_pista (code,code_name) VALUES (11,'Público (11)'); +INSERT INTO dominios.uso_pista (code,code_name) VALUES (12,'Militar (12)'); +INSERT INTO dominios.uso_pista (code,code_name) VALUES (13,'Público/Militar (13)'); +INSERT INTO dominios.uso_pista (code,code_name) VALUES (9999,'A SER PREENCHIDO (9999)'); -ALTER TABLE dominios.uso_pista OWNER TO postgres# +ALTER TABLE dominios.uso_pista OWNER TO postgres; CREATE TABLE edgv.cobter_area_construida_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -1405,24 +1405,24 @@ CREATE TABLE edgv.cobter_area_construida_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT cobter_area_construida_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX cobter_area_construida_a_geom ON edgv.cobter_area_construida_a USING gist (geom)# +); +CREATE INDEX cobter_area_construida_a_geom ON edgv.cobter_area_construida_a USING gist (geom); -ALTER TABLE edgv.cobter_area_construida_a OWNER TO postgres# +ALTER TABLE edgv.cobter_area_construida_a OWNER TO postgres; ALTER TABLE edgv.cobter_area_construida_a ADD CONSTRAINT cobter_area_construida_a_densamente_edificada_fk FOREIGN KEY (densamente_edificada) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.cobter_area_construida_a ALTER COLUMN densamente_edificada SET DEFAULT 9999# +ALTER TABLE edgv.cobter_area_construida_a ALTER COLUMN densamente_edificada SET DEFAULT 9999; ALTER TABLE edgv.cobter_area_construida_a ADD CONSTRAINT cobter_area_construida_a_assentamento_precario_fk FOREIGN KEY (assentamento_precario) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.cobter_area_construida_a ALTER COLUMN assentamento_precario SET DEFAULT 9999# +ALTER TABLE edgv.cobter_area_construida_a ALTER COLUMN assentamento_precario SET DEFAULT 9999; CREATE TABLE edgv.cobter_massa_dagua_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -1438,31 +1438,31 @@ CREATE TABLE edgv.cobter_massa_dagua_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT cobter_massa_dagua_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX cobter_massa_dagua_a_geom ON edgv.cobter_massa_dagua_a USING gist (geom)# +); +CREATE INDEX cobter_massa_dagua_a_geom ON edgv.cobter_massa_dagua_a USING gist (geom); -ALTER TABLE edgv.cobter_massa_dagua_a OWNER TO postgres# +ALTER TABLE edgv.cobter_massa_dagua_a OWNER TO postgres; ALTER TABLE edgv.cobter_massa_dagua_a ADD CONSTRAINT cobter_massa_dagua_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_massa_dagua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.cobter_massa_dagua_a ADD CONSTRAINT cobter_massa_dagua_a_regime_fk FOREIGN KEY (regime) REFERENCES dominios.regime (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN regime SET DEFAULT 9999# +ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN regime SET DEFAULT 9999; ALTER TABLE edgv.cobter_massa_dagua_a ADD CONSTRAINT cobter_massa_dagua_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.cobter_massa_dagua_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.cobter_vegetacao_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -1471,17 +1471,17 @@ CREATE TABLE edgv.cobter_vegetacao_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT cobter_vegetacao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX cobter_vegetacao_a_geom ON edgv.cobter_vegetacao_a USING gist (geom)# +); +CREATE INDEX cobter_vegetacao_a_geom ON edgv.cobter_vegetacao_a USING gist (geom); -ALTER TABLE edgv.cobter_vegetacao_a OWNER TO postgres# +ALTER TABLE edgv.cobter_vegetacao_a OWNER TO postgres; ALTER TABLE edgv.cobter_vegetacao_a ADD CONSTRAINT cobter_vegetacao_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_veg (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.cobter_vegetacao_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.cobter_vegetacao_a ALTER COLUMN tipo SET DEFAULT 9999; CREATE TABLE edgv.constr_area_uso_especifico_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -1496,31 +1496,31 @@ CREATE TABLE edgv.constr_area_uso_especifico_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT constr_area_uso_especifico_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX constr_area_uso_especifico_a_geom ON edgv.constr_area_uso_especifico_a USING gist (geom)# +); +CREATE INDEX constr_area_uso_especifico_a_geom ON edgv.constr_area_uso_especifico_a USING gist (geom); -ALTER TABLE edgv.constr_area_uso_especifico_a OWNER TO postgres# +ALTER TABLE edgv.constr_area_uso_especifico_a OWNER TO postgres; ALTER TABLE edgv.constr_area_uso_especifico_a ADD CONSTRAINT constr_area_uso_especifico_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_area_uso_especifico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_area_uso_especifico_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.constr_area_uso_especifico_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.constr_area_uso_especifico_a ADD CONSTRAINT constr_area_uso_especifico_a_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_area_uso_especifico_a ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.constr_area_uso_especifico_a ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.constr_area_uso_especifico_a ADD CONSTRAINT constr_area_uso_especifico_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_area_uso_especifico_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.constr_area_uso_especifico_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.constr_deposito_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -1540,70 +1540,70 @@ CREATE TABLE edgv.constr_deposito_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT constr_deposito_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX constr_deposito_a_geom ON edgv.constr_deposito_a USING gist (geom)# +); +CREATE INDEX constr_deposito_a_geom ON edgv.constr_deposito_a USING gist (geom); -ALTER TABLE edgv.constr_deposito_a OWNER TO postgres# +ALTER TABLE edgv.constr_deposito_a OWNER TO postgres; ALTER TABLE edgv.constr_deposito_a ADD CONSTRAINT constr_deposito_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_deposito (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_a ADD CONSTRAINT constr_deposito_a_tipo_exposicao_fk FOREIGN KEY (tipo_exposicao) REFERENCES dominios.tipo_exposicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_a ALTER COLUMN tipo_exposicao SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN tipo_exposicao SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_a ADD CONSTRAINT constr_deposito_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_a ADD CONSTRAINT constr_deposito_a_material_construcao_fk FOREIGN KEY (material_construcao) REFERENCES dominios.material_construcao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.constr_deposito_a ADD CONSTRAINT constr_deposito_a_material_construcao_check - CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.constr_deposito_a ALTER COLUMN material_construcao SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN material_construcao SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_a ADD CONSTRAINT constr_deposito_a_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_a ALTER COLUMN finalidade SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN finalidade SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_a ADD CONSTRAINT constr_deposito_a_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_a ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_a ADD CONSTRAINT constr_deposito_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_a ADD CONSTRAINT constr_deposito_a_exibir_linha_rotulo_fk FOREIGN KEY (exibir_linha_rotulo) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_a ALTER COLUMN exibir_linha_rotulo SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_a ALTER COLUMN exibir_linha_rotulo SET DEFAULT 9999; CREATE TABLE edgv.constr_deposito_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -1624,70 +1624,70 @@ CREATE TABLE edgv.constr_deposito_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT constr_deposito_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX constr_deposito_p_geom ON edgv.constr_deposito_p USING gist (geom)# +); +CREATE INDEX constr_deposito_p_geom ON edgv.constr_deposito_p USING gist (geom); -ALTER TABLE edgv.constr_deposito_p OWNER TO postgres# +ALTER TABLE edgv.constr_deposito_p OWNER TO postgres; ALTER TABLE edgv.constr_deposito_p ADD CONSTRAINT constr_deposito_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_deposito (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_p ADD CONSTRAINT constr_deposito_p_tipo_exposicao_fk FOREIGN KEY (tipo_exposicao) REFERENCES dominios.tipo_exposicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_p ALTER COLUMN tipo_exposicao SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN tipo_exposicao SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_p ADD CONSTRAINT constr_deposito_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_p ADD CONSTRAINT constr_deposito_p_material_construcao_fk FOREIGN KEY (material_construcao) REFERENCES dominios.material_construcao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.constr_deposito_p ADD CONSTRAINT constr_deposito_p_material_construcao_check - CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.constr_deposito_p ALTER COLUMN material_construcao SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN material_construcao SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_p ADD CONSTRAINT constr_deposito_p_finalidade_fk FOREIGN KEY (finalidade) REFERENCES dominios.finalidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_p ALTER COLUMN finalidade SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN finalidade SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_p ADD CONSTRAINT constr_deposito_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_p ADD CONSTRAINT constr_deposito_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.constr_deposito_p ADD CONSTRAINT constr_deposito_p_exibir_linha_rotulo_fk FOREIGN KEY (exibir_linha_rotulo) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_deposito_p ALTER COLUMN exibir_linha_rotulo SET DEFAULT 9999# +ALTER TABLE edgv.constr_deposito_p ALTER COLUMN exibir_linha_rotulo SET DEFAULT 9999; CREATE TABLE edgv.constr_edificacao_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -1705,56 +1705,56 @@ CREATE TABLE edgv.constr_edificacao_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT constr_edificacao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX constr_edificacao_a_geom ON edgv.constr_edificacao_a USING gist (geom)# +); +CREATE INDEX constr_edificacao_a_geom ON edgv.constr_edificacao_a USING gist (geom); -ALTER TABLE edgv.constr_edificacao_a OWNER TO postgres# +ALTER TABLE edgv.constr_edificacao_a OWNER TO postgres; ALTER TABLE edgv.constr_edificacao_a ADD CONSTRAINT constr_edificacao_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_edificacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.constr_edificacao_a ADD CONSTRAINT constr_edificacao_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.constr_edificacao_a ADD CONSTRAINT constr_edificacao_a_material_construcao_fk FOREIGN KEY (material_construcao) REFERENCES dominios.material_construcao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.constr_edificacao_a ADD CONSTRAINT constr_edificacao_a_material_construcao_check - CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN material_construcao SET DEFAULT 9999# +ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN material_construcao SET DEFAULT 9999; ALTER TABLE edgv.constr_edificacao_a ADD CONSTRAINT constr_edificacao_a_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.constr_edificacao_a ADD CONSTRAINT constr_edificacao_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.constr_edificacao_a ADD CONSTRAINT constr_edificacao_a_exibir_linha_rotulo_fk FOREIGN KEY (exibir_linha_rotulo) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN exibir_linha_rotulo SET DEFAULT 9999# +ALTER TABLE edgv.constr_edificacao_a ALTER COLUMN exibir_linha_rotulo SET DEFAULT 9999; CREATE TABLE edgv.constr_edificacao_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -1774,63 +1774,63 @@ CREATE TABLE edgv.constr_edificacao_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT constr_edificacao_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX constr_edificacao_p_geom ON edgv.constr_edificacao_p USING gist (geom)# +); +CREATE INDEX constr_edificacao_p_geom ON edgv.constr_edificacao_p USING gist (geom); -ALTER TABLE edgv.constr_edificacao_p OWNER TO postgres# +ALTER TABLE edgv.constr_edificacao_p OWNER TO postgres; ALTER TABLE edgv.constr_edificacao_p ADD CONSTRAINT constr_edificacao_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_edificacao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.constr_edificacao_p ADD CONSTRAINT constr_edificacao_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.constr_edificacao_p ADD CONSTRAINT constr_edificacao_p_material_construcao_fk FOREIGN KEY (material_construcao) REFERENCES dominios.material_construcao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.constr_edificacao_p ADD CONSTRAINT constr_edificacao_p_material_construcao_check - CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN material_construcao SET DEFAULT 9999# +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN material_construcao SET DEFAULT 9999; ALTER TABLE edgv.constr_edificacao_p ADD CONSTRAINT constr_edificacao_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.constr_edificacao_p ADD CONSTRAINT constr_edificacao_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.constr_edificacao_p ADD CONSTRAINT constr_edificacao_p_exibir_linha_rotulo_fk FOREIGN KEY (exibir_linha_rotulo) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN exibir_linha_rotulo SET DEFAULT 9999# +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN exibir_linha_rotulo SET DEFAULT 9999; ALTER TABLE edgv.constr_edificacao_p ADD CONSTRAINT constr_edificacao_p_suprimir_bandeira_fk FOREIGN KEY (suprimir_bandeira) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN suprimir_bandeira SET DEFAULT 9999# +ALTER TABLE edgv.constr_edificacao_p ALTER COLUMN suprimir_bandeira SET DEFAULT 9999; CREATE TABLE edgv.constr_extracao_mineral_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -1848,52 +1848,52 @@ CREATE TABLE edgv.constr_extracao_mineral_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT constr_extracao_mineral_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX constr_extracao_mineral_a_geom ON edgv.constr_extracao_mineral_a USING gist (geom)# +); +CREATE INDEX constr_extracao_mineral_a_geom ON edgv.constr_extracao_mineral_a USING gist (geom); -ALTER TABLE edgv.constr_extracao_mineral_a OWNER TO postgres# +ALTER TABLE edgv.constr_extracao_mineral_a OWNER TO postgres; ALTER TABLE edgv.constr_extracao_mineral_a ADD CONSTRAINT constr_extracao_mineral_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_extracao_mineral (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.constr_extracao_mineral_a ADD CONSTRAINT constr_extracao_mineral_a_tipo_produto_fk FOREIGN KEY (tipo_produto) REFERENCES dominios.tipo_produto_residuo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN tipo_produto SET DEFAULT 9999# +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN tipo_produto SET DEFAULT 9999; ALTER TABLE edgv.constr_extracao_mineral_a ADD CONSTRAINT constr_extracao_mineral_a_forma_extracao_fk FOREIGN KEY (forma_extracao) REFERENCES dominios.forma_extracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN forma_extracao SET DEFAULT 9999# +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN forma_extracao SET DEFAULT 9999; ALTER TABLE edgv.constr_extracao_mineral_a ADD CONSTRAINT constr_extracao_mineral_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.constr_extracao_mineral_a ADD CONSTRAINT constr_extracao_mineral_a_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.constr_extracao_mineral_a ADD CONSTRAINT constr_extracao_mineral_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.constr_extracao_mineral_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.constr_extracao_mineral_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -1911,52 +1911,52 @@ CREATE TABLE edgv.constr_extracao_mineral_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT constr_extracao_mineral_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX constr_extracao_mineral_p_geom ON edgv.constr_extracao_mineral_p USING gist (geom)# +); +CREATE INDEX constr_extracao_mineral_p_geom ON edgv.constr_extracao_mineral_p USING gist (geom); -ALTER TABLE edgv.constr_extracao_mineral_p OWNER TO postgres# +ALTER TABLE edgv.constr_extracao_mineral_p OWNER TO postgres; ALTER TABLE edgv.constr_extracao_mineral_p ADD CONSTRAINT constr_extracao_mineral_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_extracao_mineral (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.constr_extracao_mineral_p ADD CONSTRAINT constr_extracao_mineral_p_tipo_produto_fk FOREIGN KEY (tipo_produto) REFERENCES dominios.tipo_produto_residuo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN tipo_produto SET DEFAULT 9999# +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN tipo_produto SET DEFAULT 9999; ALTER TABLE edgv.constr_extracao_mineral_p ADD CONSTRAINT constr_extracao_mineral_p_forma_extracao_fk FOREIGN KEY (forma_extracao) REFERENCES dominios.forma_extracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN forma_extracao SET DEFAULT 9999# +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN forma_extracao SET DEFAULT 9999; ALTER TABLE edgv.constr_extracao_mineral_p ADD CONSTRAINT constr_extracao_mineral_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.constr_extracao_mineral_p ADD CONSTRAINT constr_extracao_mineral_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.constr_extracao_mineral_p ADD CONSTRAINT constr_extracao_mineral_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.constr_extracao_mineral_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.constr_ocupacao_solo_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -1972,42 +1972,42 @@ CREATE TABLE edgv.constr_ocupacao_solo_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT constr_ocupacao_solo_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX constr_ocupacao_solo_a_geom ON edgv.constr_ocupacao_solo_a USING gist (geom)# +); +CREATE INDEX constr_ocupacao_solo_a_geom ON edgv.constr_ocupacao_solo_a USING gist (geom); -ALTER TABLE edgv.constr_ocupacao_solo_a OWNER TO postgres# +ALTER TABLE edgv.constr_ocupacao_solo_a OWNER TO postgres; ALTER TABLE edgv.constr_ocupacao_solo_a ADD CONSTRAINT constr_ocupacao_solo_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_ocupacao_solo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.constr_ocupacao_solo_a ADD CONSTRAINT constr_ocupacao_solo_a_tipo_check - CHECK (tipo = ANY(ARRAY[101 :: SMALLINT, 102 :: SMALLINT, 103 :: SMALLINT, 104 :: SMALLINT, 105 :: SMALLINT, 106 :: SMALLINT, 107 :: SMALLINT, 108 :: SMALLINT, 201 :: SMALLINT, 202 :: SMALLINT, 203 :: SMALLINT, 204 :: SMALLINT, 205 :: SMALLINT, 206 :: SMALLINT, 207 :: SMALLINT, 298 :: SMALLINT, 301 :: SMALLINT, 302 :: SMALLINT, 303 :: SMALLINT, 304 :: SMALLINT, 305 :: SMALLINT, 306 :: SMALLINT, 307 :: SMALLINT, 398 :: SMALLINT, 404 :: SMALLINT, 405 :: SMALLINT, 406 :: SMALLINT, 409 :: SMALLINT, 414 :: SMALLINT, 415 :: SMALLINT, 416 :: SMALLINT, 501 :: SMALLINT, 601 :: SMALLINT, 701 :: SMALLINT, 801 :: SMALLINT, 802 :: SMALLINT, 804 :: SMALLINT, 803 :: SMALLINT, 805 :: SMALLINT, 806 :: SMALLINT, 901 :: SMALLINT, 1001 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[101 :: SMALLINT, 102 :: SMALLINT, 103 :: SMALLINT, 104 :: SMALLINT, 105 :: SMALLINT, 106 :: SMALLINT, 107 :: SMALLINT, 108 :: SMALLINT, 201 :: SMALLINT, 202 :: SMALLINT, 203 :: SMALLINT, 204 :: SMALLINT, 205 :: SMALLINT, 206 :: SMALLINT, 207 :: SMALLINT, 298 :: SMALLINT, 301 :: SMALLINT, 302 :: SMALLINT, 303 :: SMALLINT, 304 :: SMALLINT, 305 :: SMALLINT, 306 :: SMALLINT, 307 :: SMALLINT, 398 :: SMALLINT, 404 :: SMALLINT, 405 :: SMALLINT, 406 :: SMALLINT, 409 :: SMALLINT, 414 :: SMALLINT, 415 :: SMALLINT, 416 :: SMALLINT, 501 :: SMALLINT, 601 :: SMALLINT, 701 :: SMALLINT, 801 :: SMALLINT, 802 :: SMALLINT, 804 :: SMALLINT, 803 :: SMALLINT, 805 :: SMALLINT, 806 :: SMALLINT, 901 :: SMALLINT, 1001 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.constr_ocupacao_solo_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.constr_ocupacao_solo_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.constr_ocupacao_solo_a ADD CONSTRAINT constr_ocupacao_solo_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_ocupacao_solo_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.constr_ocupacao_solo_a ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.constr_ocupacao_solo_a ADD CONSTRAINT constr_ocupacao_solo_a_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_ocupacao_solo_a ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.constr_ocupacao_solo_a ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.constr_ocupacao_solo_a ADD CONSTRAINT constr_ocupacao_solo_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_ocupacao_solo_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.constr_ocupacao_solo_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.constr_ocupacao_solo_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2023,42 +2023,42 @@ CREATE TABLE edgv.constr_ocupacao_solo_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT constr_ocupacao_solo_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX constr_ocupacao_solo_l_geom ON edgv.constr_ocupacao_solo_l USING gist (geom)# +); +CREATE INDEX constr_ocupacao_solo_l_geom ON edgv.constr_ocupacao_solo_l USING gist (geom); -ALTER TABLE edgv.constr_ocupacao_solo_l OWNER TO postgres# +ALTER TABLE edgv.constr_ocupacao_solo_l OWNER TO postgres; ALTER TABLE edgv.constr_ocupacao_solo_l ADD CONSTRAINT constr_ocupacao_solo_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_ocupacao_solo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.constr_ocupacao_solo_l ADD CONSTRAINT constr_ocupacao_solo_l_tipo_check - CHECK (tipo = ANY(ARRAY[301 :: SMALLINT, 302 :: SMALLINT, 303 :: SMALLINT, 304 :: SMALLINT, 305 :: SMALLINT, 306 :: SMALLINT, 307 :: SMALLINT, 398 :: SMALLINT, 1001 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[301 :: SMALLINT, 302 :: SMALLINT, 303 :: SMALLINT, 304 :: SMALLINT, 305 :: SMALLINT, 306 :: SMALLINT, 307 :: SMALLINT, 398 :: SMALLINT, 1001 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.constr_ocupacao_solo_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.constr_ocupacao_solo_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.constr_ocupacao_solo_l ADD CONSTRAINT constr_ocupacao_solo_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_ocupacao_solo_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.constr_ocupacao_solo_l ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.constr_ocupacao_solo_l ADD CONSTRAINT constr_ocupacao_solo_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_ocupacao_solo_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.constr_ocupacao_solo_l ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.constr_ocupacao_solo_l ADD CONSTRAINT constr_ocupacao_solo_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_ocupacao_solo_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.constr_ocupacao_solo_l ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.constr_ocupacao_solo_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2074,42 +2074,42 @@ CREATE TABLE edgv.constr_ocupacao_solo_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT constr_ocupacao_solo_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX constr_ocupacao_solo_p_geom ON edgv.constr_ocupacao_solo_p USING gist (geom)# +); +CREATE INDEX constr_ocupacao_solo_p_geom ON edgv.constr_ocupacao_solo_p USING gist (geom); -ALTER TABLE edgv.constr_ocupacao_solo_p OWNER TO postgres# +ALTER TABLE edgv.constr_ocupacao_solo_p OWNER TO postgres; ALTER TABLE edgv.constr_ocupacao_solo_p ADD CONSTRAINT constr_ocupacao_solo_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_ocupacao_solo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.constr_ocupacao_solo_p ADD CONSTRAINT constr_ocupacao_solo_p_tipo_check - CHECK (tipo = ANY(ARRAY[101 :: SMALLINT, 102 :: SMALLINT, 103 :: SMALLINT, 104 :: SMALLINT, 105 :: SMALLINT, 106 :: SMALLINT, 107 :: SMALLINT, 108 :: SMALLINT, 201 :: SMALLINT, 202 :: SMALLINT, 203 :: SMALLINT, 204 :: SMALLINT, 205 :: SMALLINT, 206 :: SMALLINT, 207 :: SMALLINT, 298 :: SMALLINT, 301 :: SMALLINT, 302 :: SMALLINT, 303 :: SMALLINT, 304 :: SMALLINT, 305 :: SMALLINT, 306 :: SMALLINT, 307 :: SMALLINT, 398 :: SMALLINT, 701 :: SMALLINT, 801 :: SMALLINT, 802 :: SMALLINT, 804 :: SMALLINT, 803 :: SMALLINT, 805 :: SMALLINT, 806 :: SMALLINT, 1101 :: SMALLINT, 1601 :: SMALLINT, 1602 :: SMALLINT, 1603 :: SMALLINT, 1604 :: SMALLINT, 1605 :: SMALLINT, 1606 :: SMALLINT, 1607 :: SMALLINT, 1608 :: SMALLINT, 1609 :: SMALLINT, 1610 :: SMALLINT, 1611 :: SMALLINT, 1612 :: SMALLINT, 1613 :: SMALLINT, 1614 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[101 :: SMALLINT, 102 :: SMALLINT, 103 :: SMALLINT, 104 :: SMALLINT, 105 :: SMALLINT, 106 :: SMALLINT, 107 :: SMALLINT, 108 :: SMALLINT, 201 :: SMALLINT, 202 :: SMALLINT, 203 :: SMALLINT, 204 :: SMALLINT, 205 :: SMALLINT, 206 :: SMALLINT, 207 :: SMALLINT, 298 :: SMALLINT, 301 :: SMALLINT, 302 :: SMALLINT, 303 :: SMALLINT, 304 :: SMALLINT, 305 :: SMALLINT, 306 :: SMALLINT, 307 :: SMALLINT, 398 :: SMALLINT, 701 :: SMALLINT, 801 :: SMALLINT, 802 :: SMALLINT, 804 :: SMALLINT, 803 :: SMALLINT, 805 :: SMALLINT, 806 :: SMALLINT, 1101 :: SMALLINT, 1601 :: SMALLINT, 1602 :: SMALLINT, 1603 :: SMALLINT, 1604 :: SMALLINT, 1605 :: SMALLINT, 1606 :: SMALLINT, 1607 :: SMALLINT, 1608 :: SMALLINT, 1609 :: SMALLINT, 1610 :: SMALLINT, 1611 :: SMALLINT, 1612 :: SMALLINT, 1613 :: SMALLINT, 1614 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.constr_ocupacao_solo_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.constr_ocupacao_solo_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.constr_ocupacao_solo_p ADD CONSTRAINT constr_ocupacao_solo_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_ocupacao_solo_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.constr_ocupacao_solo_p ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.constr_ocupacao_solo_p ADD CONSTRAINT constr_ocupacao_solo_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_ocupacao_solo_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.constr_ocupacao_solo_p ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.constr_ocupacao_solo_p ADD CONSTRAINT constr_ocupacao_solo_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.constr_ocupacao_solo_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.constr_ocupacao_solo_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.elemnat_curva_nivel_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2123,38 +2123,38 @@ CREATE TABLE edgv.elemnat_curva_nivel_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT elemnat_curva_nivel_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_curva_nivel_l_geom ON edgv.elemnat_curva_nivel_l USING gist (geom)# +); +CREATE INDEX elemnat_curva_nivel_l_geom ON edgv.elemnat_curva_nivel_l USING gist (geom); -ALTER TABLE edgv.elemnat_curva_nivel_l OWNER TO postgres# +ALTER TABLE edgv.elemnat_curva_nivel_l OWNER TO postgres; ALTER TABLE edgv.elemnat_curva_nivel_l ADD CONSTRAINT elemnat_curva_nivel_l_indice_fk FOREIGN KEY (indice) REFERENCES dominios.indice (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN indice SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN indice SET DEFAULT 9999; ALTER TABLE edgv.elemnat_curva_nivel_l ADD CONSTRAINT elemnat_curva_nivel_l_depressao_fk FOREIGN KEY (depressao) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN depressao SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN depressao SET DEFAULT 9999; ALTER TABLE edgv.elemnat_curva_nivel_l ADD CONSTRAINT elemnat_curva_nivel_l_dentro_de_massa_dagua_fk FOREIGN KEY (dentro_de_massa_dagua) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN dentro_de_massa_dagua SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN dentro_de_massa_dagua SET DEFAULT 9999; ALTER TABLE edgv.elemnat_curva_nivel_l ADD CONSTRAINT elemnat_curva_nivel_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_curva_nivel_l ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.elemnat_elemento_fisiografico_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2169,35 +2169,35 @@ CREATE TABLE edgv.elemnat_elemento_fisiografico_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT elemnat_elemento_fisiografico_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_elemento_fisiografico_a_geom ON edgv.elemnat_elemento_fisiografico_a USING gist (geom)# +); +CREATE INDEX elemnat_elemento_fisiografico_a_geom ON edgv.elemnat_elemento_fisiografico_a USING gist (geom); -ALTER TABLE edgv.elemnat_elemento_fisiografico_a OWNER TO postgres# +ALTER TABLE edgv.elemnat_elemento_fisiografico_a OWNER TO postgres; ALTER TABLE edgv.elemnat_elemento_fisiografico_a ADD CONSTRAINT elemnat_elemento_fisiografico_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_fisiografico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.elemnat_elemento_fisiografico_a ADD CONSTRAINT elemnat_elemento_fisiografico_a_tipo_check - CHECK (tipo = ANY(ARRAY[15 :: SMALLINT, 16 :: SMALLINT, 21 :: SMALLINT, 22 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[15 :: SMALLINT, 16 :: SMALLINT, 21 :: SMALLINT, 22 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.elemnat_elemento_fisiografico_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_fisiografico_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.elemnat_elemento_fisiografico_a ADD CONSTRAINT elemnat_elemento_fisiografico_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_elemento_fisiografico_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_fisiografico_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.elemnat_elemento_fisiografico_a ADD CONSTRAINT elemnat_elemento_fisiografico_a_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_elemento_fisiografico_a ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_fisiografico_a ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.elemnat_elemento_fisiografico_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2212,35 +2212,35 @@ CREATE TABLE edgv.elemnat_elemento_fisiografico_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT elemnat_elemento_fisiografico_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_elemento_fisiografico_l_geom ON edgv.elemnat_elemento_fisiografico_l USING gist (geom)# +); +CREATE INDEX elemnat_elemento_fisiografico_l_geom ON edgv.elemnat_elemento_fisiografico_l USING gist (geom); -ALTER TABLE edgv.elemnat_elemento_fisiografico_l OWNER TO postgres# +ALTER TABLE edgv.elemnat_elemento_fisiografico_l OWNER TO postgres; ALTER TABLE edgv.elemnat_elemento_fisiografico_l ADD CONSTRAINT elemnat_elemento_fisiografico_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_fisiografico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.elemnat_elemento_fisiografico_l ADD CONSTRAINT elemnat_elemento_fisiografico_l_tipo_check - CHECK (tipo = ANY(ARRAY[8 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[8 :: SMALLINT, 13 :: SMALLINT, 14 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.elemnat_elemento_fisiografico_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_fisiografico_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.elemnat_elemento_fisiografico_l ADD CONSTRAINT elemnat_elemento_fisiografico_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_elemento_fisiografico_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_fisiografico_l ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.elemnat_elemento_fisiografico_l ADD CONSTRAINT elemnat_elemento_fisiografico_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_elemento_fisiografico_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_fisiografico_l ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.elemnat_elemento_fisiografico_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2256,35 +2256,35 @@ CREATE TABLE edgv.elemnat_elemento_fisiografico_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT elemnat_elemento_fisiografico_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_elemento_fisiografico_p_geom ON edgv.elemnat_elemento_fisiografico_p USING gist (geom)# +); +CREATE INDEX elemnat_elemento_fisiografico_p_geom ON edgv.elemnat_elemento_fisiografico_p USING gist (geom); -ALTER TABLE edgv.elemnat_elemento_fisiografico_p OWNER TO postgres# +ALTER TABLE edgv.elemnat_elemento_fisiografico_p OWNER TO postgres; ALTER TABLE edgv.elemnat_elemento_fisiografico_p ADD CONSTRAINT elemnat_elemento_fisiografico_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_fisiografico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.elemnat_elemento_fisiografico_p ADD CONSTRAINT elemnat_elemento_fisiografico_p_tipo_check - CHECK (tipo = ANY(ARRAY[19 :: SMALLINT, 20 :: SMALLINT, 21 :: SMALLINT, 22 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[19 :: SMALLINT, 20 :: SMALLINT, 21 :: SMALLINT, 22 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.elemnat_elemento_fisiografico_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_fisiografico_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.elemnat_elemento_fisiografico_p ADD CONSTRAINT elemnat_elemento_fisiografico_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_elemento_fisiografico_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_fisiografico_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.elemnat_elemento_fisiografico_p ADD CONSTRAINT elemnat_elemento_fisiografico_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_elemento_fisiografico_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_fisiografico_p ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.elemnat_elemento_hidrografico_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2299,35 +2299,35 @@ CREATE TABLE edgv.elemnat_elemento_hidrografico_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT elemnat_elemento_hidrografico_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_elemento_hidrografico_a_geom ON edgv.elemnat_elemento_hidrografico_a USING gist (geom)# +); +CREATE INDEX elemnat_elemento_hidrografico_a_geom ON edgv.elemnat_elemento_hidrografico_a USING gist (geom); -ALTER TABLE edgv.elemnat_elemento_hidrografico_a OWNER TO postgres# +ALTER TABLE edgv.elemnat_elemento_hidrografico_a OWNER TO postgres; ALTER TABLE edgv.elemnat_elemento_hidrografico_a ADD CONSTRAINT elemnat_elemento_hidrografico_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_hidrografico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.elemnat_elemento_hidrografico_a ADD CONSTRAINT elemnat_elemento_hidrografico_a_tipo_check - CHECK (tipo = ANY(ARRAY[6 :: SMALLINT, 8 :: SMALLINT, 12 :: SMALLINT, 14 :: SMALLINT, 15 :: SMALLINT, 16 :: SMALLINT, 17 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[6 :: SMALLINT, 8 :: SMALLINT, 12 :: SMALLINT, 14 :: SMALLINT, 15 :: SMALLINT, 16 :: SMALLINT, 17 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.elemnat_elemento_hidrografico_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_hidrografico_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.elemnat_elemento_hidrografico_a ADD CONSTRAINT elemnat_elemento_hidrografico_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_elemento_hidrografico_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_hidrografico_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.elemnat_elemento_hidrografico_a ADD CONSTRAINT elemnat_elemento_hidrografico_a_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_elemento_hidrografico_a ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_hidrografico_a ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.elemnat_elemento_hidrografico_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2342,35 +2342,35 @@ CREATE TABLE edgv.elemnat_elemento_hidrografico_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT elemnat_elemento_hidrografico_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_elemento_hidrografico_l_geom ON edgv.elemnat_elemento_hidrografico_l USING gist (geom)# +); +CREATE INDEX elemnat_elemento_hidrografico_l_geom ON edgv.elemnat_elemento_hidrografico_l USING gist (geom); -ALTER TABLE edgv.elemnat_elemento_hidrografico_l OWNER TO postgres# +ALTER TABLE edgv.elemnat_elemento_hidrografico_l OWNER TO postgres; ALTER TABLE edgv.elemnat_elemento_hidrografico_l ADD CONSTRAINT elemnat_elemento_hidrografico_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_hidrografico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.elemnat_elemento_hidrografico_l ADD CONSTRAINT elemnat_elemento_hidrografico_l_tipo_check - CHECK (tipo = ANY(ARRAY[6 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[6 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.elemnat_elemento_hidrografico_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_hidrografico_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.elemnat_elemento_hidrografico_l ADD CONSTRAINT elemnat_elemento_hidrografico_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_elemento_hidrografico_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_hidrografico_l ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.elemnat_elemento_hidrografico_l ADD CONSTRAINT elemnat_elemento_hidrografico_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_elemento_hidrografico_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_hidrografico_l ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.elemnat_elemento_hidrografico_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2386,35 +2386,35 @@ CREATE TABLE edgv.elemnat_elemento_hidrografico_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT elemnat_elemento_hidrografico_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_elemento_hidrografico_p_geom ON edgv.elemnat_elemento_hidrografico_p USING gist (geom)# +); +CREATE INDEX elemnat_elemento_hidrografico_p_geom ON edgv.elemnat_elemento_hidrografico_p USING gist (geom); -ALTER TABLE edgv.elemnat_elemento_hidrografico_p OWNER TO postgres# +ALTER TABLE edgv.elemnat_elemento_hidrografico_p OWNER TO postgres; ALTER TABLE edgv.elemnat_elemento_hidrografico_p ADD CONSTRAINT elemnat_elemento_hidrografico_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_hidrografico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.elemnat_elemento_hidrografico_p ADD CONSTRAINT elemnat_elemento_hidrografico_p_tipo_check - CHECK (tipo = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 6 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 6 :: SMALLINT, 8 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.elemnat_elemento_hidrografico_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_hidrografico_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.elemnat_elemento_hidrografico_p ADD CONSTRAINT elemnat_elemento_hidrografico_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_elemento_hidrografico_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_hidrografico_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.elemnat_elemento_hidrografico_p ADD CONSTRAINT elemnat_elemento_hidrografico_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_elemento_hidrografico_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_elemento_hidrografico_p ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.elemnat_ilha_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2430,31 +2430,31 @@ CREATE TABLE edgv.elemnat_ilha_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT elemnat_ilha_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_ilha_p_geom ON edgv.elemnat_ilha_p USING gist (geom)# +); +CREATE INDEX elemnat_ilha_p_geom ON edgv.elemnat_ilha_p USING gist (geom); -ALTER TABLE edgv.elemnat_ilha_p OWNER TO postgres# +ALTER TABLE edgv.elemnat_ilha_p OWNER TO postgres; ALTER TABLE edgv.elemnat_ilha_p ADD CONSTRAINT elemnat_ilha_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_ilha (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_ilha_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_ilha_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.elemnat_ilha_p ADD CONSTRAINT elemnat_ilha_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_ilha_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_ilha_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.elemnat_ilha_p ADD CONSTRAINT elemnat_ilha_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_ilha_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_ilha_p ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.elemnat_ilha_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2470,31 +2470,31 @@ CREATE TABLE edgv.elemnat_ilha_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT elemnat_ilha_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_ilha_a_geom ON edgv.elemnat_ilha_a USING gist (geom)# +); +CREATE INDEX elemnat_ilha_a_geom ON edgv.elemnat_ilha_a USING gist (geom); -ALTER TABLE edgv.elemnat_ilha_a OWNER TO postgres# +ALTER TABLE edgv.elemnat_ilha_a OWNER TO postgres; ALTER TABLE edgv.elemnat_ilha_a ADD CONSTRAINT elemnat_ilha_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_ilha (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_ilha_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_ilha_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.elemnat_ilha_a ADD CONSTRAINT elemnat_ilha_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_ilha_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_ilha_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.elemnat_ilha_a ADD CONSTRAINT elemnat_ilha_a_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_ilha_a ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_ilha_a ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.elemnat_ponto_cotado_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2511,52 +2511,52 @@ CREATE TABLE edgv.elemnat_ponto_cotado_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT elemnat_ponto_cotado_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_ponto_cotado_p_geom ON edgv.elemnat_ponto_cotado_p USING gist (geom)# +); +CREATE INDEX elemnat_ponto_cotado_p_geom ON edgv.elemnat_ponto_cotado_p USING gist (geom); -ALTER TABLE edgv.elemnat_ponto_cotado_p OWNER TO postgres# +ALTER TABLE edgv.elemnat_ponto_cotado_p OWNER TO postgres; ALTER TABLE edgv.elemnat_ponto_cotado_p ADD CONSTRAINT elemnat_ponto_cotado_p_cota_comprovada_fk FOREIGN KEY (cota_comprovada) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN cota_comprovada SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN cota_comprovada SET DEFAULT 9999; ALTER TABLE edgv.elemnat_ponto_cotado_p ADD CONSTRAINT elemnat_ponto_cotado_p_cota_mais_alta_fk FOREIGN KEY (cota_mais_alta) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN cota_mais_alta SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN cota_mais_alta SET DEFAULT 9999; ALTER TABLE edgv.elemnat_ponto_cotado_p ADD CONSTRAINT elemnat_ponto_cotado_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.elemnat_ponto_cotado_p ADD CONSTRAINT elemnat_ponto_cotado_p_ancora_horizontal_fk FOREIGN KEY (ancora_horizontal) REFERENCES dominios.ancora_horizontal (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN ancora_horizontal SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN ancora_horizontal SET DEFAULT 9999; ALTER TABLE edgv.elemnat_ponto_cotado_p ADD CONSTRAINT elemnat_ponto_cotado_p_ancora_vertical_fk FOREIGN KEY (ancora_vertical) REFERENCES dominios.ancora_vertical (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN ancora_vertical SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN ancora_vertical SET DEFAULT 9999; ALTER TABLE edgv.elemnat_ponto_cotado_p ADD CONSTRAINT elemnat_ponto_cotado_p_suprimir_simbologia_fk FOREIGN KEY (suprimir_simbologia) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN suprimir_simbologia SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_ponto_cotado_p ALTER COLUMN suprimir_simbologia SET DEFAULT 9999; CREATE TABLE edgv.elemnat_terreno_sujeito_inundacao_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2564,10 +2564,10 @@ CREATE TABLE edgv.elemnat_terreno_sujeito_inundacao_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT elemnat_terreno_sujeito_inundacao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_terreno_sujeito_inundacao_a_geom ON edgv.elemnat_terreno_sujeito_inundacao_a USING gist (geom)# +); +CREATE INDEX elemnat_terreno_sujeito_inundacao_a_geom ON edgv.elemnat_terreno_sujeito_inundacao_a USING gist (geom); -ALTER TABLE edgv.elemnat_terreno_sujeito_inundacao_a OWNER TO postgres# +ALTER TABLE edgv.elemnat_terreno_sujeito_inundacao_a OWNER TO postgres; CREATE TABLE edgv.elemnat_toponimo_fisiografico_natural_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2583,28 +2583,28 @@ CREATE TABLE edgv.elemnat_toponimo_fisiografico_natural_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT elemnat_toponimo_fisiografico_natural_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_toponimo_fisiografico_natural_p_geom ON edgv.elemnat_toponimo_fisiografico_natural_p USING gist (geom)# +); +CREATE INDEX elemnat_toponimo_fisiografico_natural_p_geom ON edgv.elemnat_toponimo_fisiografico_natural_p USING gist (geom); -ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p OWNER TO postgres# +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p OWNER TO postgres; ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_toponimo_fisiografico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_p_tipo_check - CHECK (tipo = ANY(ARRAY[2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 17 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 6 :: SMALLINT, 7 :: SMALLINT, 9 :: SMALLINT, 10 :: SMALLINT, 11 :: SMALLINT, 12 :: SMALLINT, 17 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.elemnat_toponimo_fisiografico_natural_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2619,21 +2619,21 @@ CREATE TABLE edgv.elemnat_toponimo_fisiografico_natural_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT elemnat_toponimo_fisiografico_natural_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_toponimo_fisiografico_natural_l_geom ON edgv.elemnat_toponimo_fisiografico_natural_l USING gist (geom)# +); +CREATE INDEX elemnat_toponimo_fisiografico_natural_l_geom ON edgv.elemnat_toponimo_fisiografico_natural_l USING gist (geom); -ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l OWNER TO postgres# +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l OWNER TO postgres; ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_toponimo_fisiografico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l ADD CONSTRAINT elemnat_toponimo_fisiografico_natural_l_tipo_check - CHECK (tipo = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 12 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 12 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_toponimo_fisiografico_natural_l ALTER COLUMN tipo SET DEFAULT 9999; CREATE TABLE edgv.elemnat_trecho_drenagem_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2650,52 +2650,52 @@ CREATE TABLE edgv.elemnat_trecho_drenagem_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT elemnat_trecho_drenagem_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_trecho_drenagem_l_geom ON edgv.elemnat_trecho_drenagem_l USING gist (geom)# +); +CREATE INDEX elemnat_trecho_drenagem_l_geom ON edgv.elemnat_trecho_drenagem_l USING gist (geom); -ALTER TABLE edgv.elemnat_trecho_drenagem_l OWNER TO postgres# +ALTER TABLE edgv.elemnat_trecho_drenagem_l OWNER TO postgres; ALTER TABLE edgv.elemnat_trecho_drenagem_l ADD CONSTRAINT elemnat_trecho_drenagem_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_trecho_drenagem (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.elemnat_trecho_drenagem_l ADD CONSTRAINT elemnat_trecho_drenagem_l_situacao_em_poligono_fk FOREIGN KEY (situacao_em_poligono) REFERENCES dominios.situacao_em_poligono (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN situacao_em_poligono SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN situacao_em_poligono SET DEFAULT 9999; ALTER TABLE edgv.elemnat_trecho_drenagem_l ADD CONSTRAINT elemnat_trecho_drenagem_l_regime_fk FOREIGN KEY (regime) REFERENCES dominios.regime (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN regime SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN regime SET DEFAULT 9999; ALTER TABLE edgv.elemnat_trecho_drenagem_l ADD CONSTRAINT elemnat_trecho_drenagem_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.elemnat_trecho_drenagem_l ADD CONSTRAINT elemnat_trecho_drenagem_l_posicao_rotulo_fk FOREIGN KEY (posicao_rotulo) REFERENCES dominios.posicao_rotulo (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN posicao_rotulo SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN posicao_rotulo SET DEFAULT 9999; ALTER TABLE edgv.elemnat_trecho_drenagem_l ADD CONSTRAINT elemnat_trecho_drenagem_l_direcao_fixada_fk FOREIGN KEY (direcao_fixada) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN direcao_fixada SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_trecho_drenagem_l ALTER COLUMN direcao_fixada SET DEFAULT 9999; CREATE TABLE edgv.elemnat_sumidouro_vertedouro_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2706,24 +2706,24 @@ CREATE TABLE edgv.elemnat_sumidouro_vertedouro_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT elemnat_sumidouro_vertedouro_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX elemnat_sumidouro_vertedouro_p_geom ON edgv.elemnat_sumidouro_vertedouro_p USING gist (geom)# +); +CREATE INDEX elemnat_sumidouro_vertedouro_p_geom ON edgv.elemnat_sumidouro_vertedouro_p USING gist (geom); -ALTER TABLE edgv.elemnat_sumidouro_vertedouro_p OWNER TO postgres# +ALTER TABLE edgv.elemnat_sumidouro_vertedouro_p OWNER TO postgres; ALTER TABLE edgv.elemnat_sumidouro_vertedouro_p ADD CONSTRAINT elemnat_sumidouro_vertedouro_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_sumidouro_vertedouro (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_sumidouro_vertedouro_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_sumidouro_vertedouro_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.elemnat_sumidouro_vertedouro_p ADD CONSTRAINT elemnat_sumidouro_vertedouro_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.elemnat_sumidouro_vertedouro_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.elemnat_sumidouro_vertedouro_p ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.infra_alteracao_fisiografica_antropica_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2737,38 +2737,38 @@ CREATE TABLE edgv.infra_alteracao_fisiografica_antropica_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT infra_alteracao_fisiografica_antropica_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_alteracao_fisiografica_antropica_l_geom ON edgv.infra_alteracao_fisiografica_antropica_l USING gist (geom)# +); +CREATE INDEX infra_alteracao_fisiografica_antropica_l_geom ON edgv.infra_alteracao_fisiografica_antropica_l USING gist (geom); -ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l OWNER TO postgres# +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l OWNER TO postgres; ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ADD CONSTRAINT infra_alteracao_fisiografica_antropica_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_alteracao_fisiografica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ADD CONSTRAINT infra_alteracao_fisiografica_antropica_l_sobreposto_transportes_fk FOREIGN KEY (sobreposto_transportes) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ALTER COLUMN sobreposto_transportes SET DEFAULT 9999# +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ALTER COLUMN sobreposto_transportes SET DEFAULT 9999; ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ADD CONSTRAINT infra_alteracao_fisiografica_antropica_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ADD CONSTRAINT infra_alteracao_fisiografica_antropica_l_exibir_lado_simbologia_fk FOREIGN KEY (exibir_lado_simbologia) REFERENCES dominios.exibir_lado_simbologia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ALTER COLUMN exibir_lado_simbologia SET DEFAULT 9999# +ALTER TABLE edgv.infra_alteracao_fisiografica_antropica_l ALTER COLUMN exibir_lado_simbologia SET DEFAULT 9999; CREATE TABLE edgv.infra_barragem_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2785,42 +2785,42 @@ CREATE TABLE edgv.infra_barragem_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT infra_barragem_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_barragem_l_geom ON edgv.infra_barragem_l USING gist (geom)# +); +CREATE INDEX infra_barragem_l_geom ON edgv.infra_barragem_l USING gist (geom); -ALTER TABLE edgv.infra_barragem_l OWNER TO postgres# +ALTER TABLE edgv.infra_barragem_l OWNER TO postgres; ALTER TABLE edgv.infra_barragem_l ADD CONSTRAINT infra_barragem_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_barragem (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_barragem_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_barragem_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_barragem_l ADD CONSTRAINT infra_barragem_l_material_construcao_fk FOREIGN KEY (material_construcao) REFERENCES dominios.material_construcao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_barragem_l ADD CONSTRAINT infra_barragem_l_material_construcao_check - CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_barragem_l ALTER COLUMN material_construcao SET DEFAULT 9999# +ALTER TABLE edgv.infra_barragem_l ALTER COLUMN material_construcao SET DEFAULT 9999; ALTER TABLE edgv.infra_barragem_l ADD CONSTRAINT infra_barragem_l_sobreposto_transportes_fk FOREIGN KEY (sobreposto_transportes) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_barragem_l ALTER COLUMN sobreposto_transportes SET DEFAULT 9999# +ALTER TABLE edgv.infra_barragem_l ALTER COLUMN sobreposto_transportes SET DEFAULT 9999; ALTER TABLE edgv.infra_barragem_l ADD CONSTRAINT infra_barragem_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_barragem_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_barragem_l ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.infra_barragem_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2836,42 +2836,42 @@ CREATE TABLE edgv.infra_barragem_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT infra_barragem_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_barragem_a_geom ON edgv.infra_barragem_a USING gist (geom)# +); +CREATE INDEX infra_barragem_a_geom ON edgv.infra_barragem_a USING gist (geom); -ALTER TABLE edgv.infra_barragem_a OWNER TO postgres# +ALTER TABLE edgv.infra_barragem_a OWNER TO postgres; ALTER TABLE edgv.infra_barragem_a ADD CONSTRAINT infra_barragem_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_barragem (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_barragem_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_barragem_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_barragem_a ADD CONSTRAINT infra_barragem_a_material_construcao_fk FOREIGN KEY (material_construcao) REFERENCES dominios.material_construcao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_barragem_a ADD CONSTRAINT infra_barragem_a_material_construcao_check - CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 23 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_barragem_a ALTER COLUMN material_construcao SET DEFAULT 9999# +ALTER TABLE edgv.infra_barragem_a ALTER COLUMN material_construcao SET DEFAULT 9999; ALTER TABLE edgv.infra_barragem_a ADD CONSTRAINT infra_barragem_a_sobreposto_transportes_fk FOREIGN KEY (sobreposto_transportes) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_barragem_a ALTER COLUMN sobreposto_transportes SET DEFAULT 9999# +ALTER TABLE edgv.infra_barragem_a ALTER COLUMN sobreposto_transportes SET DEFAULT 9999; ALTER TABLE edgv.infra_barragem_a ADD CONSTRAINT infra_barragem_a_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_barragem_a ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_barragem_a ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.infra_elemento_energia_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2888,42 +2888,42 @@ CREATE TABLE edgv.infra_elemento_energia_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT infra_elemento_energia_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_elemento_energia_p_geom ON edgv.infra_elemento_energia_p USING gist (geom)# +); +CREATE INDEX infra_elemento_energia_p_geom ON edgv.infra_elemento_energia_p USING gist (geom); -ALTER TABLE edgv.infra_elemento_energia_p OWNER TO postgres# +ALTER TABLE edgv.infra_elemento_energia_p OWNER TO postgres; ALTER TABLE edgv.infra_elemento_energia_p ADD CONSTRAINT infra_elemento_energia_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_energia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_elemento_energia_p ADD CONSTRAINT infra_elemento_energia_p_tipo_check - CHECK (tipo = ANY(ARRAY[1401 :: SMALLINT, 1701 :: SMALLINT, 405 :: SMALLINT, 406 :: SMALLINT, 407 :: SMALLINT, 408 :: SMALLINT, 409 :: SMALLINT, 498 :: SMALLINT, 1801 :: SMALLINT, 1802 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[1401 :: SMALLINT, 1701 :: SMALLINT, 405 :: SMALLINT, 406 :: SMALLINT, 407 :: SMALLINT, 408 :: SMALLINT, 409 :: SMALLINT, 498 :: SMALLINT, 1801 :: SMALLINT, 1802 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_energia_p ADD CONSTRAINT infra_elemento_energia_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_energia_p ADD CONSTRAINT infra_elemento_energia_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_energia_p ADD CONSTRAINT infra_elemento_energia_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_energia_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.infra_elemento_energia_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2936,35 +2936,35 @@ CREATE TABLE edgv.infra_elemento_energia_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT infra_elemento_energia_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_elemento_energia_l_geom ON edgv.infra_elemento_energia_l USING gist (geom)# +); +CREATE INDEX infra_elemento_energia_l_geom ON edgv.infra_elemento_energia_l USING gist (geom); -ALTER TABLE edgv.infra_elemento_energia_l OWNER TO postgres# +ALTER TABLE edgv.infra_elemento_energia_l OWNER TO postgres; ALTER TABLE edgv.infra_elemento_energia_l ADD CONSTRAINT infra_elemento_energia_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_energia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_elemento_energia_l ADD CONSTRAINT infra_elemento_energia_l_tipo_check - CHECK (tipo = ANY(ARRAY[302 :: SMALLINT, 303 :: SMALLINT, 405 :: SMALLINT, 406 :: SMALLINT, 407 :: SMALLINT, 408 :: SMALLINT, 409 :: SMALLINT, 498 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[302 :: SMALLINT, 303 :: SMALLINT, 405 :: SMALLINT, 406 :: SMALLINT, 407 :: SMALLINT, 408 :: SMALLINT, 409 :: SMALLINT, 498 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_elemento_energia_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_energia_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_energia_l ADD CONSTRAINT infra_elemento_energia_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_energia_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_energia_l ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_energia_l ADD CONSTRAINT infra_elemento_energia_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_energia_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_energia_l ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.infra_elemento_energia_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -2980,42 +2980,42 @@ CREATE TABLE edgv.infra_elemento_energia_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT infra_elemento_energia_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_elemento_energia_a_geom ON edgv.infra_elemento_energia_a USING gist (geom)# +); +CREATE INDEX infra_elemento_energia_a_geom ON edgv.infra_elemento_energia_a USING gist (geom); -ALTER TABLE edgv.infra_elemento_energia_a OWNER TO postgres# +ALTER TABLE edgv.infra_elemento_energia_a OWNER TO postgres; ALTER TABLE edgv.infra_elemento_energia_a ADD CONSTRAINT infra_elemento_energia_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_energia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_elemento_energia_a ADD CONSTRAINT infra_elemento_energia_a_tipo_check - CHECK (tipo = ANY(ARRAY[405 :: SMALLINT, 406 :: SMALLINT, 407 :: SMALLINT, 408 :: SMALLINT, 409 :: SMALLINT, 498 :: SMALLINT, 1801 :: SMALLINT, 1802 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[405 :: SMALLINT, 406 :: SMALLINT, 407 :: SMALLINT, 408 :: SMALLINT, 409 :: SMALLINT, 498 :: SMALLINT, 1801 :: SMALLINT, 1802 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_energia_a ADD CONSTRAINT infra_elemento_energia_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_energia_a ADD CONSTRAINT infra_elemento_energia_a_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_energia_a ADD CONSTRAINT infra_elemento_energia_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_energia_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.infra_elemento_infraestrutura_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3031,42 +3031,42 @@ CREATE TABLE edgv.infra_elemento_infraestrutura_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT infra_elemento_infraestrutura_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_elemento_infraestrutura_a_geom ON edgv.infra_elemento_infraestrutura_a USING gist (geom)# +); +CREATE INDEX infra_elemento_infraestrutura_a_geom ON edgv.infra_elemento_infraestrutura_a USING gist (geom); -ALTER TABLE edgv.infra_elemento_infraestrutura_a OWNER TO postgres# +ALTER TABLE edgv.infra_elemento_infraestrutura_a OWNER TO postgres; ALTER TABLE edgv.infra_elemento_infraestrutura_a ADD CONSTRAINT infra_elemento_infraestrutura_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_infraestrutura (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_elemento_infraestrutura_a ADD CONSTRAINT infra_elemento_infraestrutura_a_tipo_check - CHECK (tipo = ANY(ARRAY[701 :: SMALLINT, 801 :: SMALLINT, 1001 :: SMALLINT, 1400 :: SMALLINT, 1401 :: SMALLINT, 1402 :: SMALLINT, 1495 :: SMALLINT, 1801 :: SMALLINT, 1938 :: SMALLINT, 1939 :: SMALLINT, 1940 :: SMALLINT, 1941 :: SMALLINT, 1942 :: SMALLINT, 1943 :: SMALLINT, 1944 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[701 :: SMALLINT, 801 :: SMALLINT, 1001 :: SMALLINT, 1400 :: SMALLINT, 1401 :: SMALLINT, 1402 :: SMALLINT, 1495 :: SMALLINT, 1801 :: SMALLINT, 1938 :: SMALLINT, 1939 :: SMALLINT, 1940 :: SMALLINT, 1941 :: SMALLINT, 1942 :: SMALLINT, 1943 :: SMALLINT, 1944 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_infraestrutura_a ADD CONSTRAINT infra_elemento_infraestrutura_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_infraestrutura_a ADD CONSTRAINT infra_elemento_infraestrutura_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_infraestrutura_a ADD CONSTRAINT infra_elemento_infraestrutura_a_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_infraestrutura_a ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.infra_elemento_infraestrutura_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3082,42 +3082,42 @@ CREATE TABLE edgv.infra_elemento_infraestrutura_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT infra_elemento_infraestrutura_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_elemento_infraestrutura_l_geom ON edgv.infra_elemento_infraestrutura_l USING gist (geom)# +); +CREATE INDEX infra_elemento_infraestrutura_l_geom ON edgv.infra_elemento_infraestrutura_l USING gist (geom); -ALTER TABLE edgv.infra_elemento_infraestrutura_l OWNER TO postgres# +ALTER TABLE edgv.infra_elemento_infraestrutura_l OWNER TO postgres; ALTER TABLE edgv.infra_elemento_infraestrutura_l ADD CONSTRAINT infra_elemento_infraestrutura_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_infraestrutura (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_elemento_infraestrutura_l ADD CONSTRAINT infra_elemento_infraestrutura_l_tipo_check - CHECK (tipo = ANY(ARRAY[701 :: SMALLINT, 801 :: SMALLINT, 901 :: SMALLINT, 1001 :: SMALLINT, 1501 :: SMALLINT, 1601 :: SMALLINT, 1938 :: SMALLINT, 1939 :: SMALLINT, 1940 :: SMALLINT, 1941 :: SMALLINT, 1942 :: SMALLINT, 1943 :: SMALLINT, 1944 :: SMALLINT, 2001 :: SMALLINT, 2098 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[701 :: SMALLINT, 801 :: SMALLINT, 901 :: SMALLINT, 1001 :: SMALLINT, 1501 :: SMALLINT, 1601 :: SMALLINT, 1938 :: SMALLINT, 1939 :: SMALLINT, 1940 :: SMALLINT, 1941 :: SMALLINT, 1942 :: SMALLINT, 1943 :: SMALLINT, 1944 :: SMALLINT, 2001 :: SMALLINT, 2098 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_infraestrutura_l ADD CONSTRAINT infra_elemento_infraestrutura_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_infraestrutura_l ADD CONSTRAINT infra_elemento_infraestrutura_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_infraestrutura_l ADD CONSTRAINT infra_elemento_infraestrutura_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_infraestrutura_l ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.infra_elemento_infraestrutura_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3133,42 +3133,42 @@ CREATE TABLE edgv.infra_elemento_infraestrutura_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT infra_elemento_infraestrutura_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_elemento_infraestrutura_p_geom ON edgv.infra_elemento_infraestrutura_p USING gist (geom)# +); +CREATE INDEX infra_elemento_infraestrutura_p_geom ON edgv.infra_elemento_infraestrutura_p USING gist (geom); -ALTER TABLE edgv.infra_elemento_infraestrutura_p OWNER TO postgres# +ALTER TABLE edgv.infra_elemento_infraestrutura_p OWNER TO postgres; ALTER TABLE edgv.infra_elemento_infraestrutura_p ADD CONSTRAINT infra_elemento_infraestrutura_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_infraestrutura (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_elemento_infraestrutura_p ADD CONSTRAINT infra_elemento_infraestrutura_p_tipo_check - CHECK (tipo = ANY(ARRAY[901 :: SMALLINT, 1001 :: SMALLINT, 1201 :: SMALLINT, 1301 :: SMALLINT, 1400 :: SMALLINT, 1401 :: SMALLINT, 1402 :: SMALLINT, 1495 :: SMALLINT, 1601 :: SMALLINT, 1701 :: SMALLINT, 1801 :: SMALLINT, 1938 :: SMALLINT, 1939 :: SMALLINT, 1940 :: SMALLINT, 1941 :: SMALLINT, 1942 :: SMALLINT, 1943 :: SMALLINT, 1944 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[901 :: SMALLINT, 1001 :: SMALLINT, 1201 :: SMALLINT, 1301 :: SMALLINT, 1400 :: SMALLINT, 1401 :: SMALLINT, 1402 :: SMALLINT, 1495 :: SMALLINT, 1601 :: SMALLINT, 1701 :: SMALLINT, 1801 :: SMALLINT, 1938 :: SMALLINT, 1939 :: SMALLINT, 1940 :: SMALLINT, 1941 :: SMALLINT, 1942 :: SMALLINT, 1943 :: SMALLINT, 1944 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_infraestrutura_p ADD CONSTRAINT infra_elemento_infraestrutura_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_infraestrutura_p ADD CONSTRAINT infra_elemento_infraestrutura_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_infraestrutura_p ADD CONSTRAINT infra_elemento_infraestrutura_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_infraestrutura_p ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.infra_elemento_viario_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3192,77 +3192,77 @@ CREATE TABLE edgv.infra_elemento_viario_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT infra_elemento_viario_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_elemento_viario_l_geom ON edgv.infra_elemento_viario_l USING gist (geom)# +); +CREATE INDEX infra_elemento_viario_l_geom ON edgv.infra_elemento_viario_l USING gist (geom); -ALTER TABLE edgv.infra_elemento_viario_l OWNER TO postgres# +ALTER TABLE edgv.infra_elemento_viario_l OWNER TO postgres; ALTER TABLE edgv.infra_elemento_viario_l ADD CONSTRAINT infra_elemento_viario_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_viario (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_l ADD CONSTRAINT infra_elemento_viario_l_material_construcao_fk FOREIGN KEY (material_construcao) REFERENCES dominios.material_construcao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_elemento_viario_l ADD CONSTRAINT infra_elemento_viario_l_material_construcao_check - CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN material_construcao SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN material_construcao SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_l ADD CONSTRAINT infra_elemento_viario_l_modal_uso_fk FOREIGN KEY (modal_uso) REFERENCES dominios.modal_uso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN modal_uso SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN modal_uso SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_l ADD CONSTRAINT infra_elemento_viario_l_posicao_pista_fk FOREIGN KEY (posicao_pista) REFERENCES dominios.posicao_pista (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN posicao_pista SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN posicao_pista SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_l ADD CONSTRAINT infra_elemento_viario_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_l ADD CONSTRAINT infra_elemento_viario_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_l ADD CONSTRAINT infra_elemento_viario_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_l ADD CONSTRAINT infra_elemento_viario_l_exibir_lado_simbologia_fk FOREIGN KEY (exibir_lado_simbologia) REFERENCES dominios.exibir_lado_simbologia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN exibir_lado_simbologia SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN exibir_lado_simbologia SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_l ADD CONSTRAINT infra_elemento_viario_l_exibir_ponta_simbologia_fk FOREIGN KEY (exibir_ponta_simbologia) REFERENCES dominios.exibir_ponta_simbologia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN exibir_ponta_simbologia SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_l ALTER COLUMN exibir_ponta_simbologia SET DEFAULT 9999; CREATE TABLE edgv.infra_elemento_viario_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3287,77 +3287,77 @@ CREATE TABLE edgv.infra_elemento_viario_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT infra_elemento_viario_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_elemento_viario_p_geom ON edgv.infra_elemento_viario_p USING gist (geom)# +); +CREATE INDEX infra_elemento_viario_p_geom ON edgv.infra_elemento_viario_p USING gist (geom); -ALTER TABLE edgv.infra_elemento_viario_p OWNER TO postgres# +ALTER TABLE edgv.infra_elemento_viario_p OWNER TO postgres; ALTER TABLE edgv.infra_elemento_viario_p ADD CONSTRAINT infra_elemento_viario_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_viario (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_p ADD CONSTRAINT infra_elemento_viario_p_material_construcao_fk FOREIGN KEY (material_construcao) REFERENCES dominios.material_construcao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_elemento_viario_p ADD CONSTRAINT infra_elemento_viario_p_material_construcao_check - CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 97 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN material_construcao SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN material_construcao SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_p ADD CONSTRAINT infra_elemento_viario_p_modal_uso_fk FOREIGN KEY (modal_uso) REFERENCES dominios.modal_uso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN modal_uso SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN modal_uso SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_p ADD CONSTRAINT infra_elemento_viario_p_posicao_pista_fk FOREIGN KEY (posicao_pista) REFERENCES dominios.posicao_pista (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN posicao_pista SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN posicao_pista SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_p ADD CONSTRAINT infra_elemento_viario_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_p ADD CONSTRAINT infra_elemento_viario_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_p ADD CONSTRAINT infra_elemento_viario_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_p ADD CONSTRAINT infra_elemento_viario_p_exibir_lado_simbologia_fk FOREIGN KEY (exibir_lado_simbologia) REFERENCES dominios.exibir_lado_simbologia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN exibir_lado_simbologia SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN exibir_lado_simbologia SET DEFAULT 9999; ALTER TABLE edgv.infra_elemento_viario_p ADD CONSTRAINT infra_elemento_viario_p_exibir_ponta_simbologia_fk FOREIGN KEY (exibir_ponta_simbologia) REFERENCES dominios.exibir_ponta_simbologia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN exibir_ponta_simbologia SET DEFAULT 9999# +ALTER TABLE edgv.infra_elemento_viario_p ALTER COLUMN exibir_ponta_simbologia SET DEFAULT 9999; CREATE TABLE edgv.infra_ferrovia_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3378,84 +3378,84 @@ CREATE TABLE edgv.infra_ferrovia_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT infra_ferrovia_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_ferrovia_l_geom ON edgv.infra_ferrovia_l USING gist (geom)# +); +CREATE INDEX infra_ferrovia_l_geom ON edgv.infra_ferrovia_l USING gist (geom); -ALTER TABLE edgv.infra_ferrovia_l OWNER TO postgres# +ALTER TABLE edgv.infra_ferrovia_l OWNER TO postgres; ALTER TABLE edgv.infra_ferrovia_l ADD CONSTRAINT infra_ferrovia_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_ferrovia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_ferrovia_l ADD CONSTRAINT infra_ferrovia_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_ferrovia_l ADD CONSTRAINT infra_ferrovia_l_posicao_relativa_fk FOREIGN KEY (posicao_relativa) REFERENCES dominios.posicao_relativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_ferrovia_l ADD CONSTRAINT infra_ferrovia_l_posicao_relativa_check - CHECK (posicao_relativa = ANY(ARRAY[2 :: SMALLINT, 3 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (posicao_relativa = ANY(ARRAY[2 :: SMALLINT, 3 :: SMALLINT, 6 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN posicao_relativa SET DEFAULT 9999# +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN posicao_relativa SET DEFAULT 9999; ALTER TABLE edgv.infra_ferrovia_l ADD CONSTRAINT infra_ferrovia_l_nr_linhas_fk FOREIGN KEY (nr_linhas) REFERENCES dominios.nr_linhas (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN nr_linhas SET DEFAULT 9999# +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN nr_linhas SET DEFAULT 9999; ALTER TABLE edgv.infra_ferrovia_l ADD CONSTRAINT infra_ferrovia_l_eletrificada_fk FOREIGN KEY (eletrificada) REFERENCES dominios.auxiliar (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN eletrificada SET DEFAULT 9999# +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN eletrificada SET DEFAULT 9999; ALTER TABLE edgv.infra_ferrovia_l ADD CONSTRAINT infra_ferrovia_l_bitola_fk FOREIGN KEY (bitola) REFERENCES dominios.bitola (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN bitola SET DEFAULT 9999# +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN bitola SET DEFAULT 9999; ALTER TABLE edgv.infra_ferrovia_l ADD CONSTRAINT infra_ferrovia_l_em_arruamento_fk FOREIGN KEY (em_arruamento) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN em_arruamento SET DEFAULT 9999# +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN em_arruamento SET DEFAULT 9999; ALTER TABLE edgv.infra_ferrovia_l ADD CONSTRAINT infra_ferrovia_l_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN jurisdicao SET DEFAULT 9999# +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN jurisdicao SET DEFAULT 9999; ALTER TABLE edgv.infra_ferrovia_l ADD CONSTRAINT infra_ferrovia_l_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN administracao SET DEFAULT 9999# +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN administracao SET DEFAULT 9999; ALTER TABLE edgv.infra_ferrovia_l ADD CONSTRAINT infra_ferrovia_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_ferrovia_l ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.infra_mobilidade_urbana_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3467,31 +3467,31 @@ CREATE TABLE edgv.infra_mobilidade_urbana_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT infra_mobilidade_urbana_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_mobilidade_urbana_l_geom ON edgv.infra_mobilidade_urbana_l USING gist (geom)# +); +CREATE INDEX infra_mobilidade_urbana_l_geom ON edgv.infra_mobilidade_urbana_l USING gist (geom); -ALTER TABLE edgv.infra_mobilidade_urbana_l OWNER TO postgres# +ALTER TABLE edgv.infra_mobilidade_urbana_l OWNER TO postgres; ALTER TABLE edgv.infra_mobilidade_urbana_l ADD CONSTRAINT infra_mobilidade_urbana_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_mobilidade_urbana (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_mobilidade_urbana_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_mobilidade_urbana_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_mobilidade_urbana_l ADD CONSTRAINT infra_mobilidade_urbana_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_mobilidade_urbana_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_mobilidade_urbana_l ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_mobilidade_urbana_l ADD CONSTRAINT infra_mobilidade_urbana_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_mobilidade_urbana_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_mobilidade_urbana_l ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.infra_pista_pouso_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3510,60 +3510,60 @@ CREATE TABLE edgv.infra_pista_pouso_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT infra_pista_pouso_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_pista_pouso_a_geom ON edgv.infra_pista_pouso_a USING gist (geom)# +); +CREATE INDEX infra_pista_pouso_a_geom ON edgv.infra_pista_pouso_a USING gist (geom); -ALTER TABLE edgv.infra_pista_pouso_a OWNER TO postgres# +ALTER TABLE edgv.infra_pista_pouso_a OWNER TO postgres; ALTER TABLE edgv.infra_pista_pouso_a ADD CONSTRAINT infra_pista_pouso_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_pista_pouso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_pista_pouso_a ADD CONSTRAINT infra_pista_pouso_a_tipo_check - CHECK (tipo = ANY(ARRAY[9 :: SMALLINT, 10 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[9 :: SMALLINT, 10 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_a ADD CONSTRAINT infra_pista_pouso_a_revestimento_fk FOREIGN KEY (revestimento) REFERENCES dominios.revestimento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_pista_pouso_a ADD CONSTRAINT infra_pista_pouso_a_revestimento_check - CHECK (revestimento = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (revestimento = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN revestimento SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN revestimento SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_a ADD CONSTRAINT infra_pista_pouso_a_uso_pista_fk FOREIGN KEY (uso_pista) REFERENCES dominios.uso_pista (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN uso_pista SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN uso_pista SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_a ADD CONSTRAINT infra_pista_pouso_a_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_a ADD CONSTRAINT infra_pista_pouso_a_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_a ADD CONSTRAINT infra_pista_pouso_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.infra_pista_pouso_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3582,60 +3582,60 @@ CREATE TABLE edgv.infra_pista_pouso_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT infra_pista_pouso_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_pista_pouso_l_geom ON edgv.infra_pista_pouso_l USING gist (geom)# +); +CREATE INDEX infra_pista_pouso_l_geom ON edgv.infra_pista_pouso_l USING gist (geom); -ALTER TABLE edgv.infra_pista_pouso_l OWNER TO postgres# +ALTER TABLE edgv.infra_pista_pouso_l OWNER TO postgres; ALTER TABLE edgv.infra_pista_pouso_l ADD CONSTRAINT infra_pista_pouso_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_pista_pouso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_pista_pouso_l ADD CONSTRAINT infra_pista_pouso_l_tipo_check - CHECK (tipo = ANY(ARRAY[9 :: SMALLINT, 10 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[9 :: SMALLINT, 10 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_l ADD CONSTRAINT infra_pista_pouso_l_revestimento_fk FOREIGN KEY (revestimento) REFERENCES dominios.revestimento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_pista_pouso_l ADD CONSTRAINT infra_pista_pouso_l_revestimento_check - CHECK (revestimento = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (revestimento = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN revestimento SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN revestimento SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_l ADD CONSTRAINT infra_pista_pouso_l_uso_pista_fk FOREIGN KEY (uso_pista) REFERENCES dominios.uso_pista (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN uso_pista SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN uso_pista SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_l ADD CONSTRAINT infra_pista_pouso_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_l ADD CONSTRAINT infra_pista_pouso_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_l ADD CONSTRAINT infra_pista_pouso_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_l ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.infra_pista_pouso_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3655,60 +3655,60 @@ CREATE TABLE edgv.infra_pista_pouso_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT infra_pista_pouso_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_pista_pouso_p_geom ON edgv.infra_pista_pouso_p USING gist (geom)# +); +CREATE INDEX infra_pista_pouso_p_geom ON edgv.infra_pista_pouso_p USING gist (geom); -ALTER TABLE edgv.infra_pista_pouso_p OWNER TO postgres# +ALTER TABLE edgv.infra_pista_pouso_p OWNER TO postgres; ALTER TABLE edgv.infra_pista_pouso_p ADD CONSTRAINT infra_pista_pouso_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_pista_pouso (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_pista_pouso_p ADD CONSTRAINT infra_pista_pouso_p_tipo_check - CHECK (tipo = ANY(ARRAY[9 :: SMALLINT, 11 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[9 :: SMALLINT, 11 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_p ADD CONSTRAINT infra_pista_pouso_p_revestimento_fk FOREIGN KEY (revestimento) REFERENCES dominios.revestimento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_pista_pouso_p ADD CONSTRAINT infra_pista_pouso_p_revestimento_check - CHECK (revestimento = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (revestimento = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN revestimento SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN revestimento SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_p ADD CONSTRAINT infra_pista_pouso_p_uso_pista_fk FOREIGN KEY (uso_pista) REFERENCES dominios.uso_pista (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN uso_pista SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN uso_pista SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_p ADD CONSTRAINT infra_pista_pouso_p_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_p ADD CONSTRAINT infra_pista_pouso_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN visivel SET DEFAULT 9999; ALTER TABLE edgv.infra_pista_pouso_p ADD CONSTRAINT infra_pista_pouso_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.infra_pista_pouso_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.infra_travessia_hidroviaria_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3723,31 +3723,31 @@ CREATE TABLE edgv.infra_travessia_hidroviaria_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT infra_travessia_hidroviaria_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_travessia_hidroviaria_l_geom ON edgv.infra_travessia_hidroviaria_l USING gist (geom)# +); +CREATE INDEX infra_travessia_hidroviaria_l_geom ON edgv.infra_travessia_hidroviaria_l USING gist (geom); -ALTER TABLE edgv.infra_travessia_hidroviaria_l OWNER TO postgres# +ALTER TABLE edgv.infra_travessia_hidroviaria_l OWNER TO postgres; ALTER TABLE edgv.infra_travessia_hidroviaria_l ADD CONSTRAINT infra_travessia_hidroviaria_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_travessia (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_travessia_hidroviaria_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_travessia_hidroviaria_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_travessia_hidroviaria_l ADD CONSTRAINT infra_travessia_hidroviaria_l_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_travessia_hidroviaria_l ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.infra_travessia_hidroviaria_l ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.infra_travessia_hidroviaria_l ADD CONSTRAINT infra_travessia_hidroviaria_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_travessia_hidroviaria_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_travessia_hidroviaria_l ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.infra_trecho_duto_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3761,38 +3761,38 @@ CREATE TABLE edgv.infra_trecho_duto_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT infra_trecho_duto_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_trecho_duto_l_geom ON edgv.infra_trecho_duto_l USING gist (geom)# +); +CREATE INDEX infra_trecho_duto_l_geom ON edgv.infra_trecho_duto_l USING gist (geom); -ALTER TABLE edgv.infra_trecho_duto_l OWNER TO postgres# +ALTER TABLE edgv.infra_trecho_duto_l OWNER TO postgres; ALTER TABLE edgv.infra_trecho_duto_l ADD CONSTRAINT infra_trecho_duto_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_trecho_duto (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_trecho_duto_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_trecho_duto_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_trecho_duto_l ADD CONSTRAINT infra_trecho_duto_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_trecho_duto_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_trecho_duto_l ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_trecho_duto_l ADD CONSTRAINT infra_trecho_duto_l_posicao_relativa_fk FOREIGN KEY (posicao_relativa) REFERENCES dominios.posicao_relativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_trecho_duto_l ALTER COLUMN posicao_relativa SET DEFAULT 9999# +ALTER TABLE edgv.infra_trecho_duto_l ALTER COLUMN posicao_relativa SET DEFAULT 9999; ALTER TABLE edgv.infra_trecho_duto_l ADD CONSTRAINT infra_trecho_duto_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_trecho_duto_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_trecho_duto_l ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.infra_vala_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3802,17 +3802,17 @@ CREATE TABLE edgv.infra_vala_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT infra_vala_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_vala_l_geom ON edgv.infra_vala_l USING gist (geom)# +); +CREATE INDEX infra_vala_l_geom ON edgv.infra_vala_l USING gist (geom); -ALTER TABLE edgv.infra_vala_l OWNER TO postgres# +ALTER TABLE edgv.infra_vala_l OWNER TO postgres; ALTER TABLE edgv.infra_vala_l ADD CONSTRAINT infra_vala_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_vala_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_vala_l ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.infra_via_deslocamento_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3835,78 +3835,78 @@ CREATE TABLE edgv.infra_via_deslocamento_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT infra_via_deslocamento_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX infra_via_deslocamento_l_geom ON edgv.infra_via_deslocamento_l USING gist (geom)# +); +CREATE INDEX infra_via_deslocamento_l_geom ON edgv.infra_via_deslocamento_l USING gist (geom); -ALTER TABLE edgv.infra_via_deslocamento_l OWNER TO postgres# +ALTER TABLE edgv.infra_via_deslocamento_l OWNER TO postgres; ALTER TABLE edgv.infra_via_deslocamento_l ADD CONSTRAINT infra_via_deslocamento_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_via_deslocamento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.infra_via_deslocamento_l ADD CONSTRAINT infra_via_deslocamento_l_revestimento_fk FOREIGN KEY (revestimento) REFERENCES dominios.revestimento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_via_deslocamento_l ADD CONSTRAINT infra_via_deslocamento_l_revestimento_check - CHECK (revestimento = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (revestimento = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 3 :: SMALLINT, 4 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN revestimento SET DEFAULT 9999# +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN revestimento SET DEFAULT 9999; ALTER TABLE edgv.infra_via_deslocamento_l ADD CONSTRAINT infra_via_deslocamento_l_trafego_fk FOREIGN KEY (trafego) REFERENCES dominios.trafego (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN trafego SET DEFAULT 9999# +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN trafego SET DEFAULT 9999; ALTER TABLE edgv.infra_via_deslocamento_l ADD CONSTRAINT infra_via_deslocamento_l_canteiro_divisorio_fk FOREIGN KEY (canteiro_divisorio) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN canteiro_divisorio SET DEFAULT 9999# +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN canteiro_divisorio SET DEFAULT 9999; ALTER TABLE edgv.infra_via_deslocamento_l ADD CONSTRAINT infra_via_deslocamento_l_situacao_fisica_fk FOREIGN KEY (situacao_fisica) REFERENCES dominios.situacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN situacao_fisica SET DEFAULT 9999# +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN situacao_fisica SET DEFAULT 9999; ALTER TABLE edgv.infra_via_deslocamento_l ADD CONSTRAINT infra_via_deslocamento_l_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_via_deslocamento_l ADD CONSTRAINT infra_via_deslocamento_l_jurisdicao_check - CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (jurisdicao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN jurisdicao SET DEFAULT 9999# +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN jurisdicao SET DEFAULT 9999; ALTER TABLE edgv.infra_via_deslocamento_l ADD CONSTRAINT infra_via_deslocamento_l_administracao_fk FOREIGN KEY (administracao) REFERENCES dominios.administracao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.infra_via_deslocamento_l ADD CONSTRAINT infra_via_deslocamento_l_administracao_check - CHECK (administracao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 7 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (administracao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 2 :: SMALLINT, 7 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN administracao SET DEFAULT 9999# +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN administracao SET DEFAULT 9999; ALTER TABLE edgv.infra_via_deslocamento_l ADD CONSTRAINT infra_via_deslocamento_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.infra_via_deslocamento_l ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.llp_delimitacao_fisica_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3917,35 +3917,35 @@ CREATE TABLE edgv.llp_delimitacao_fisica_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT llp_delimitacao_fisica_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX llp_delimitacao_fisica_l_geom ON edgv.llp_delimitacao_fisica_l USING gist (geom)# +); +CREATE INDEX llp_delimitacao_fisica_l_geom ON edgv.llp_delimitacao_fisica_l USING gist (geom); -ALTER TABLE edgv.llp_delimitacao_fisica_l OWNER TO postgres# +ALTER TABLE edgv.llp_delimitacao_fisica_l OWNER TO postgres; ALTER TABLE edgv.llp_delimitacao_fisica_l ADD CONSTRAINT llp_delimitacao_fisica_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_delimitacao_fisica (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_delimitacao_fisica_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.llp_delimitacao_fisica_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.llp_delimitacao_fisica_l ADD CONSTRAINT llp_delimitacao_fisica_l_material_construcao_fk FOREIGN KEY (material_construcao) REFERENCES dominios.material_construcao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.llp_delimitacao_fisica_l ADD CONSTRAINT llp_delimitacao_fisica_l_material_construcao_check - CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 9 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (material_construcao = ANY(ARRAY[0 :: SMALLINT, 1 :: SMALLINT, 4 :: SMALLINT, 5 :: SMALLINT, 9 :: SMALLINT, 98 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.llp_delimitacao_fisica_l ALTER COLUMN material_construcao SET DEFAULT 9999# +ALTER TABLE edgv.llp_delimitacao_fisica_l ALTER COLUMN material_construcao SET DEFAULT 9999; ALTER TABLE edgv.llp_delimitacao_fisica_l ADD CONSTRAINT llp_delimitacao_fisica_l_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_delimitacao_fisica_l ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.llp_delimitacao_fisica_l ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.llp_limite_especial_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3961,31 +3961,31 @@ CREATE TABLE edgv.llp_limite_especial_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT llp_limite_especial_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX llp_limite_especial_a_geom ON edgv.llp_limite_especial_a USING gist (geom)# +); +CREATE INDEX llp_limite_especial_a_geom ON edgv.llp_limite_especial_a USING gist (geom); -ALTER TABLE edgv.llp_limite_especial_a OWNER TO postgres# +ALTER TABLE edgv.llp_limite_especial_a OWNER TO postgres; ALTER TABLE edgv.llp_limite_especial_a ADD CONSTRAINT llp_limite_especial_a_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_limite_especial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_limite_especial_a ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.llp_limite_especial_a ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.llp_limite_especial_a ADD CONSTRAINT llp_limite_especial_a_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_limite_especial_a ALTER COLUMN geometria_aproximada SET DEFAULT 9999# +ALTER TABLE edgv.llp_limite_especial_a ALTER COLUMN geometria_aproximada SET DEFAULT 9999; ALTER TABLE edgv.llp_limite_especial_a ADD CONSTRAINT llp_limite_especial_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_limite_especial_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.llp_limite_especial_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.llp_unidade_federacao_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -3996,17 +3996,17 @@ CREATE TABLE edgv.llp_unidade_federacao_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT llp_unidade_federacao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX llp_unidade_federacao_a_geom ON edgv.llp_unidade_federacao_a USING gist (geom)# +); +CREATE INDEX llp_unidade_federacao_a_geom ON edgv.llp_unidade_federacao_a USING gist (geom); -ALTER TABLE edgv.llp_unidade_federacao_a OWNER TO postgres# +ALTER TABLE edgv.llp_unidade_federacao_a OWNER TO postgres; ALTER TABLE edgv.llp_unidade_federacao_a ADD CONSTRAINT llp_unidade_federacao_a_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_unidade_federacao_a ALTER COLUMN geometria_aproximada SET DEFAULT 9999# +ALTER TABLE edgv.llp_unidade_federacao_a ALTER COLUMN geometria_aproximada SET DEFAULT 9999; CREATE TABLE edgv.llp_localidade_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4022,31 +4022,31 @@ CREATE TABLE edgv.llp_localidade_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT llp_localidade_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX llp_localidade_p_geom ON edgv.llp_localidade_p USING gist (geom)# +); +CREATE INDEX llp_localidade_p_geom ON edgv.llp_localidade_p USING gist (geom); -ALTER TABLE edgv.llp_localidade_p OWNER TO postgres# +ALTER TABLE edgv.llp_localidade_p OWNER TO postgres; ALTER TABLE edgv.llp_localidade_p ADD CONSTRAINT llp_localidade_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_localidade (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_localidade_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.llp_localidade_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.llp_localidade_p ADD CONSTRAINT llp_localidade_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_localidade_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.llp_localidade_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; ALTER TABLE edgv.llp_localidade_p ADD CONSTRAINT llp_localidade_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_localidade_p ALTER COLUMN visivel SET DEFAULT 9999# +ALTER TABLE edgv.llp_localidade_p ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.llp_ponto_controle_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4070,59 +4070,59 @@ CREATE TABLE edgv.llp_ponto_controle_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT llp_ponto_controle_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX llp_ponto_controle_p_geom ON edgv.llp_ponto_controle_p USING gist (geom)# +); +CREATE INDEX llp_ponto_controle_p_geom ON edgv.llp_ponto_controle_p USING gist (geom); -ALTER TABLE edgv.llp_ponto_controle_p OWNER TO postgres# +ALTER TABLE edgv.llp_ponto_controle_p OWNER TO postgres; ALTER TABLE edgv.llp_ponto_controle_p ADD CONSTRAINT llp_ponto_controle_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_pto (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.llp_ponto_controle_p ADD CONSTRAINT llp_ponto_controle_p_tipo_ref_fk FOREIGN KEY (tipo_ref) REFERENCES dominios.tipo_ref (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN tipo_ref SET DEFAULT 9999# +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN tipo_ref SET DEFAULT 9999; ALTER TABLE edgv.llp_ponto_controle_p ADD CONSTRAINT llp_ponto_controle_p_sistema_geodesico_fk FOREIGN KEY (sistema_geodesico) REFERENCES dominios.sistema_geodesico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN sistema_geodesico SET DEFAULT 9999# +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN sistema_geodesico SET DEFAULT 9999; ALTER TABLE edgv.llp_ponto_controle_p ADD CONSTRAINT llp_ponto_controle_p_referencial_altim_fk FOREIGN KEY (referencial_altim) REFERENCES dominios.referencial_altim (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN referencial_altim SET DEFAULT 9999# +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN referencial_altim SET DEFAULT 9999; ALTER TABLE edgv.llp_ponto_controle_p ADD CONSTRAINT llp_ponto_controle_p_referencial_grav_fk FOREIGN KEY (referencial_grav) REFERENCES dominios.referencial_grav (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN referencial_grav SET DEFAULT 9999# +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN referencial_grav SET DEFAULT 9999; ALTER TABLE edgv.llp_ponto_controle_p ADD CONSTRAINT llp_ponto_controle_p_situacao_marco_fk FOREIGN KEY (situacao_marco) REFERENCES dominios.situacao_marco (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN situacao_marco SET DEFAULT 9999# +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN situacao_marco SET DEFAULT 9999; ALTER TABLE edgv.llp_ponto_controle_p ADD CONSTRAINT llp_ponto_controle_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.llp_ponto_controle_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.llp_pais_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4133,17 +4133,17 @@ CREATE TABLE edgv.llp_pais_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT llp_pais_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX llp_pais_a_geom ON edgv.llp_pais_a USING gist (geom)# +); +CREATE INDEX llp_pais_a_geom ON edgv.llp_pais_a USING gist (geom); -ALTER TABLE edgv.llp_pais_a OWNER TO postgres# +ALTER TABLE edgv.llp_pais_a OWNER TO postgres; ALTER TABLE edgv.llp_pais_a ADD CONSTRAINT llp_pais_a_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.llp_pais_a ALTER COLUMN geometria_aproximada SET DEFAULT 9999# +ALTER TABLE edgv.llp_pais_a ALTER COLUMN geometria_aproximada SET DEFAULT 9999; CREATE TABLE edgv.edicao_limite_especial_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4156,38 +4156,38 @@ CREATE TABLE edgv.edicao_limite_especial_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT edicao_limite_especial_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_limite_especial_l_geom ON edgv.edicao_limite_especial_l USING gist (geom)# +); +CREATE INDEX edicao_limite_especial_l_geom ON edgv.edicao_limite_especial_l USING gist (geom); -ALTER TABLE edgv.edicao_limite_especial_l OWNER TO postgres# +ALTER TABLE edgv.edicao_limite_especial_l OWNER TO postgres; ALTER TABLE edgv.edicao_limite_especial_l ADD CONSTRAINT edicao_limite_especial_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_limite_especial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_limite_especial_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.edicao_limite_especial_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.edicao_limite_especial_l ADD CONSTRAINT edicao_limite_especial_l_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_limite_especial_l ALTER COLUMN geometria_aproximada SET DEFAULT 9999# +ALTER TABLE edgv.edicao_limite_especial_l ALTER COLUMN geometria_aproximada SET DEFAULT 9999; ALTER TABLE edgv.edicao_limite_especial_l ADD CONSTRAINT edicao_limite_especial_l_sobreposto_fk FOREIGN KEY (sobreposto) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_limite_especial_l ALTER COLUMN sobreposto SET DEFAULT 9999# +ALTER TABLE edgv.edicao_limite_especial_l ALTER COLUMN sobreposto SET DEFAULT 9999; ALTER TABLE edgv.edicao_limite_especial_l ADD CONSTRAINT edicao_limite_especial_l_exibir_rotulo_aproximado_fk FOREIGN KEY (exibir_rotulo_aproximado) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_limite_especial_l ALTER COLUMN exibir_rotulo_aproximado SET DEFAULT 9999# +ALTER TABLE edgv.edicao_limite_especial_l ALTER COLUMN exibir_rotulo_aproximado SET DEFAULT 9999; CREATE TABLE edgv.edicao_limite_legal_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4201,38 +4201,38 @@ CREATE TABLE edgv.edicao_limite_legal_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT edicao_limite_legal_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_limite_legal_l_geom ON edgv.edicao_limite_legal_l USING gist (geom)# +); +CREATE INDEX edicao_limite_legal_l_geom ON edgv.edicao_limite_legal_l USING gist (geom); -ALTER TABLE edgv.edicao_limite_legal_l OWNER TO postgres# +ALTER TABLE edgv.edicao_limite_legal_l OWNER TO postgres; ALTER TABLE edgv.edicao_limite_legal_l ADD CONSTRAINT edicao_limite_legal_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_limite_legal (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.edicao_limite_legal_l ADD CONSTRAINT edicao_limite_legal_l_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN geometria_aproximada SET DEFAULT 9999# +ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN geometria_aproximada SET DEFAULT 9999; ALTER TABLE edgv.edicao_limite_legal_l ADD CONSTRAINT edicao_limite_legal_l_sobreposto_fk FOREIGN KEY (sobreposto) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN sobreposto SET DEFAULT 9999# +ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN sobreposto SET DEFAULT 9999; ALTER TABLE edgv.edicao_limite_legal_l ADD CONSTRAINT edicao_limite_legal_l_exibir_rotulo_aproximado_fk FOREIGN KEY (exibir_rotulo_aproximado) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN exibir_rotulo_aproximado SET DEFAULT 9999# +ALTER TABLE edgv.edicao_limite_legal_l ALTER COLUMN exibir_rotulo_aproximado SET DEFAULT 9999; CREATE TABLE edgv.edicao_area_sem_dados_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4245,17 +4245,17 @@ CREATE TABLE edgv.edicao_area_sem_dados_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT edicao_area_sem_dados_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_area_sem_dados_a_geom ON edgv.edicao_area_sem_dados_a USING gist (geom)# +); +CREATE INDEX edicao_area_sem_dados_a_geom ON edgv.edicao_area_sem_dados_a USING gist (geom); -ALTER TABLE edgv.edicao_area_sem_dados_a OWNER TO postgres# +ALTER TABLE edgv.edicao_area_sem_dados_a OWNER TO postgres; ALTER TABLE edgv.edicao_area_sem_dados_a ADD CONSTRAINT edicao_area_sem_dados_a_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_area_sem_dados_a ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.edicao_area_sem_dados_a ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.centroide_area_sem_dados_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4263,10 +4263,10 @@ CREATE TABLE edgv.centroide_area_sem_dados_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT centroide_area_sem_dados_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX centroide_area_sem_dados_p_geom ON edgv.centroide_area_sem_dados_p USING gist (geom)# +); +CREATE INDEX centroide_area_sem_dados_p_geom ON edgv.centroide_area_sem_dados_p USING gist (geom); -ALTER TABLE edgv.centroide_area_sem_dados_p OWNER TO postgres# +ALTER TABLE edgv.centroide_area_sem_dados_p OWNER TO postgres; CREATE TABLE edgv.delimitador_area_sem_dados_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4274,10 +4274,10 @@ CREATE TABLE edgv.delimitador_area_sem_dados_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT delimitador_area_sem_dados_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX delimitador_area_sem_dados_l_geom ON edgv.delimitador_area_sem_dados_l USING gist (geom)# +); +CREATE INDEX delimitador_area_sem_dados_l_geom ON edgv.delimitador_area_sem_dados_l USING gist (geom); -ALTER TABLE edgv.delimitador_area_sem_dados_l OWNER TO postgres# +ALTER TABLE edgv.delimitador_area_sem_dados_l OWNER TO postgres; CREATE TABLE edgv.aux_validacao_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4287,10 +4287,10 @@ CREATE TABLE edgv.aux_validacao_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT aux_validacao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_validacao_a_geom ON edgv.aux_validacao_a USING gist (geom)# +); +CREATE INDEX aux_validacao_a_geom ON edgv.aux_validacao_a USING gist (geom); -ALTER TABLE edgv.aux_validacao_a OWNER TO postgres# +ALTER TABLE edgv.aux_validacao_a OWNER TO postgres; CREATE TABLE edgv.aux_validacao_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4300,10 +4300,10 @@ CREATE TABLE edgv.aux_validacao_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT aux_validacao_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_validacao_l_geom ON edgv.aux_validacao_l USING gist (geom)# +); +CREATE INDEX aux_validacao_l_geom ON edgv.aux_validacao_l USING gist (geom); -ALTER TABLE edgv.aux_validacao_l OWNER TO postgres# +ALTER TABLE edgv.aux_validacao_l OWNER TO postgres; CREATE TABLE edgv.aux_validacao_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4313,10 +4313,10 @@ CREATE TABLE edgv.aux_validacao_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT aux_validacao_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_validacao_p_geom ON edgv.aux_validacao_p USING gist (geom)# +); +CREATE INDEX aux_validacao_p_geom ON edgv.aux_validacao_p USING gist (geom); -ALTER TABLE edgv.aux_validacao_p OWNER TO postgres# +ALTER TABLE edgv.aux_validacao_p OWNER TO postgres; CREATE TABLE edgv.aux_revisao_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4328,17 +4328,17 @@ CREATE TABLE edgv.aux_revisao_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT aux_revisao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_revisao_a_geom ON edgv.aux_revisao_a USING gist (geom)# +); +CREATE INDEX aux_revisao_a_geom ON edgv.aux_revisao_a USING gist (geom); -ALTER TABLE edgv.aux_revisao_a OWNER TO postgres# +ALTER TABLE edgv.aux_revisao_a OWNER TO postgres; ALTER TABLE edgv.aux_revisao_a ADD CONSTRAINT aux_revisao_a_corrigido_fk FOREIGN KEY (corrigido) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.aux_revisao_a ALTER COLUMN corrigido SET DEFAULT 9999# +ALTER TABLE edgv.aux_revisao_a ALTER COLUMN corrigido SET DEFAULT 9999; CREATE TABLE edgv.aux_revisao_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4350,17 +4350,17 @@ CREATE TABLE edgv.aux_revisao_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT aux_revisao_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_revisao_l_geom ON edgv.aux_revisao_l USING gist (geom)# +); +CREATE INDEX aux_revisao_l_geom ON edgv.aux_revisao_l USING gist (geom); -ALTER TABLE edgv.aux_revisao_l OWNER TO postgres# +ALTER TABLE edgv.aux_revisao_l OWNER TO postgres; ALTER TABLE edgv.aux_revisao_l ADD CONSTRAINT aux_revisao_l_corrigido_fk FOREIGN KEY (corrigido) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.aux_revisao_l ALTER COLUMN corrigido SET DEFAULT 9999# +ALTER TABLE edgv.aux_revisao_l ALTER COLUMN corrigido SET DEFAULT 9999; CREATE TABLE edgv.aux_revisao_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4372,17 +4372,17 @@ CREATE TABLE edgv.aux_revisao_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT aux_revisao_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_revisao_p_geom ON edgv.aux_revisao_p USING gist (geom)# +); +CREATE INDEX aux_revisao_p_geom ON edgv.aux_revisao_p USING gist (geom); -ALTER TABLE edgv.aux_revisao_p OWNER TO postgres# +ALTER TABLE edgv.aux_revisao_p OWNER TO postgres; ALTER TABLE edgv.aux_revisao_p ADD CONSTRAINT aux_revisao_p_corrigido_fk FOREIGN KEY (corrigido) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.aux_revisao_p ALTER COLUMN corrigido SET DEFAULT 9999# +ALTER TABLE edgv.aux_revisao_p ALTER COLUMN corrigido SET DEFAULT 9999; CREATE TABLE edgv.aux_reambulacao_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4391,10 +4391,10 @@ CREATE TABLE edgv.aux_reambulacao_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT aux_reambulacao_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_reambulacao_a_geom ON edgv.aux_reambulacao_a USING gist (geom)# +); +CREATE INDEX aux_reambulacao_a_geom ON edgv.aux_reambulacao_a USING gist (geom); -ALTER TABLE edgv.aux_reambulacao_a OWNER TO postgres# +ALTER TABLE edgv.aux_reambulacao_a OWNER TO postgres; CREATE TABLE edgv.aux_reambulacao_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4403,10 +4403,10 @@ CREATE TABLE edgv.aux_reambulacao_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT aux_reambulacao_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_reambulacao_l_geom ON edgv.aux_reambulacao_l USING gist (geom)# +); +CREATE INDEX aux_reambulacao_l_geom ON edgv.aux_reambulacao_l USING gist (geom); -ALTER TABLE edgv.aux_reambulacao_l OWNER TO postgres# +ALTER TABLE edgv.aux_reambulacao_l OWNER TO postgres; CREATE TABLE edgv.aux_reambulacao_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4415,10 +4415,10 @@ CREATE TABLE edgv.aux_reambulacao_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT aux_reambulacao_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_reambulacao_p_geom ON edgv.aux_reambulacao_p USING gist (geom)# +); +CREATE INDEX aux_reambulacao_p_geom ON edgv.aux_reambulacao_p USING gist (geom); -ALTER TABLE edgv.aux_reambulacao_p OWNER TO postgres# +ALTER TABLE edgv.aux_reambulacao_p OWNER TO postgres; CREATE TABLE edgv.aux_insumo_externo_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4428,10 +4428,10 @@ CREATE TABLE edgv.aux_insumo_externo_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT aux_insumo_externo_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_insumo_externo_a_geom ON edgv.aux_insumo_externo_a USING gist (geom)# +); +CREATE INDEX aux_insumo_externo_a_geom ON edgv.aux_insumo_externo_a USING gist (geom); -ALTER TABLE edgv.aux_insumo_externo_a OWNER TO postgres# +ALTER TABLE edgv.aux_insumo_externo_a OWNER TO postgres; CREATE TABLE edgv.aux_insumo_externo_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4441,10 +4441,10 @@ CREATE TABLE edgv.aux_insumo_externo_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT aux_insumo_externo_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_insumo_externo_l_geom ON edgv.aux_insumo_externo_l USING gist (geom)# +); +CREATE INDEX aux_insumo_externo_l_geom ON edgv.aux_insumo_externo_l USING gist (geom); -ALTER TABLE edgv.aux_insumo_externo_l OWNER TO postgres# +ALTER TABLE edgv.aux_insumo_externo_l OWNER TO postgres; CREATE TABLE edgv.aux_insumo_externo_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4454,10 +4454,10 @@ CREATE TABLE edgv.aux_insumo_externo_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT aux_insumo_externo_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_insumo_externo_p_geom ON edgv.aux_insumo_externo_p USING gist (geom)# +); +CREATE INDEX aux_insumo_externo_p_geom ON edgv.aux_insumo_externo_p USING gist (geom); -ALTER TABLE edgv.aux_insumo_externo_p OWNER TO postgres# +ALTER TABLE edgv.aux_insumo_externo_p OWNER TO postgres; CREATE TABLE edgv.aux_moldura_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4468,10 +4468,10 @@ CREATE TABLE edgv.aux_moldura_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT aux_moldura_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_moldura_a_geom ON edgv.aux_moldura_a USING gist (geom)# +); +CREATE INDEX aux_moldura_a_geom ON edgv.aux_moldura_a USING gist (geom); -ALTER TABLE edgv.aux_moldura_a OWNER TO postgres# +ALTER TABLE edgv.aux_moldura_a OWNER TO postgres; CREATE TABLE edgv.aux_moldura_area_continua_a( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4480,10 +4480,10 @@ CREATE TABLE edgv.aux_moldura_area_continua_a( geom geometry(MultiPolygon, [epsg]), CONSTRAINT aux_moldura_area_continua_a_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX aux_moldura_area_continua_a_geom ON edgv.aux_moldura_area_continua_a USING gist (geom)# +); +CREATE INDEX aux_moldura_area_continua_a_geom ON edgv.aux_moldura_area_continua_a USING gist (geom); -ALTER TABLE edgv.aux_moldura_area_continua_a OWNER TO postgres# +ALTER TABLE edgv.aux_moldura_area_continua_a OWNER TO postgres; CREATE TABLE edgv.edicao_grid_edicao_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4491,10 +4491,10 @@ CREATE TABLE edgv.edicao_grid_edicao_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT edicao_grid_edicao_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_grid_edicao_l_geom ON edgv.edicao_grid_edicao_l USING gist (geom)# +); +CREATE INDEX edicao_grid_edicao_l_geom ON edgv.edicao_grid_edicao_l USING gist (geom); -ALTER TABLE edgv.edicao_grid_edicao_l OWNER TO postgres# +ALTER TABLE edgv.edicao_grid_edicao_l OWNER TO postgres; CREATE TABLE edgv.delimitador_vegetacao_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4502,10 +4502,10 @@ CREATE TABLE edgv.delimitador_vegetacao_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT delimitador_vegetacao_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX delimitador_vegetacao_l_geom ON edgv.delimitador_vegetacao_l USING gist (geom)# +); +CREATE INDEX delimitador_vegetacao_l_geom ON edgv.delimitador_vegetacao_l USING gist (geom); -ALTER TABLE edgv.delimitador_vegetacao_l OWNER TO postgres# +ALTER TABLE edgv.delimitador_vegetacao_l OWNER TO postgres; CREATE TABLE edgv.delimitador_massa_dagua_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4513,10 +4513,10 @@ CREATE TABLE edgv.delimitador_massa_dagua_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT delimitador_massa_dagua_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX delimitador_massa_dagua_l_geom ON edgv.delimitador_massa_dagua_l USING gist (geom)# +); +CREATE INDEX delimitador_massa_dagua_l_geom ON edgv.delimitador_massa_dagua_l USING gist (geom); -ALTER TABLE edgv.delimitador_massa_dagua_l OWNER TO postgres# +ALTER TABLE edgv.delimitador_massa_dagua_l OWNER TO postgres; CREATE TABLE edgv.delimitador_area_construida_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4524,10 +4524,10 @@ CREATE TABLE edgv.delimitador_area_construida_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT delimitador_area_construida_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX delimitador_area_construida_l_geom ON edgv.delimitador_area_construida_l USING gist (geom)# +); +CREATE INDEX delimitador_area_construida_l_geom ON edgv.delimitador_area_construida_l USING gist (geom); -ALTER TABLE edgv.delimitador_area_construida_l OWNER TO postgres# +ALTER TABLE edgv.delimitador_area_construida_l OWNER TO postgres; CREATE TABLE edgv.delimitador_elemento_hidrografico_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4535,10 +4535,10 @@ CREATE TABLE edgv.delimitador_elemento_hidrografico_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT delimitador_elemento_hidrografico_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX delimitador_elemento_hidrografico_l_geom ON edgv.delimitador_elemento_hidrografico_l USING gist (geom)# +); +CREATE INDEX delimitador_elemento_hidrografico_l_geom ON edgv.delimitador_elemento_hidrografico_l USING gist (geom); -ALTER TABLE edgv.delimitador_elemento_hidrografico_l OWNER TO postgres# +ALTER TABLE edgv.delimitador_elemento_hidrografico_l OWNER TO postgres; CREATE TABLE edgv.delimitador_limite_especial_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4546,10 +4546,10 @@ CREATE TABLE edgv.delimitador_limite_especial_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT delimitador_limite_especial_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX delimitador_limite_especial_l_geom ON edgv.delimitador_limite_especial_l USING gist (geom)# +); +CREATE INDEX delimitador_limite_especial_l_geom ON edgv.delimitador_limite_especial_l USING gist (geom); -ALTER TABLE edgv.delimitador_limite_especial_l OWNER TO postgres# +ALTER TABLE edgv.delimitador_limite_especial_l OWNER TO postgres; CREATE TABLE edgv.centroide_vegetacao_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4559,24 +4559,24 @@ CREATE TABLE edgv.centroide_vegetacao_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT centroide_vegetacao_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX centroide_vegetacao_p_geom ON edgv.centroide_vegetacao_p USING gist (geom)# +); +CREATE INDEX centroide_vegetacao_p_geom ON edgv.centroide_vegetacao_p USING gist (geom); -ALTER TABLE edgv.centroide_vegetacao_p OWNER TO postgres# +ALTER TABLE edgv.centroide_vegetacao_p OWNER TO postgres; ALTER TABLE edgv.centroide_vegetacao_p ADD CONSTRAINT centroide_vegetacao_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_veg (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.centroide_vegetacao_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.centroide_vegetacao_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.centroide_vegetacao_p ADD CONSTRAINT centroide_vegetacao_p_sujeito_inundacao_fk FOREIGN KEY (sujeito_inundacao) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.centroide_vegetacao_p ALTER COLUMN sujeito_inundacao SET DEFAULT 9999# +ALTER TABLE edgv.centroide_vegetacao_p ALTER COLUMN sujeito_inundacao SET DEFAULT 9999; CREATE TABLE edgv.centroide_massa_dagua_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4587,24 +4587,24 @@ CREATE TABLE edgv.centroide_massa_dagua_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT centroide_massa_dagua_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX centroide_massa_dagua_p_geom ON edgv.centroide_massa_dagua_p USING gist (geom)# +); +CREATE INDEX centroide_massa_dagua_p_geom ON edgv.centroide_massa_dagua_p USING gist (geom); -ALTER TABLE edgv.centroide_massa_dagua_p OWNER TO postgres# +ALTER TABLE edgv.centroide_massa_dagua_p OWNER TO postgres; ALTER TABLE edgv.centroide_massa_dagua_p ADD CONSTRAINT centroide_massa_dagua_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_massa_dagua (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.centroide_massa_dagua_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.centroide_massa_dagua_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.centroide_massa_dagua_p ADD CONSTRAINT centroide_massa_dagua_p_regime_fk FOREIGN KEY (regime) REFERENCES dominios.regime (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.centroide_massa_dagua_p ALTER COLUMN regime SET DEFAULT 9999# +ALTER TABLE edgv.centroide_massa_dagua_p ALTER COLUMN regime SET DEFAULT 9999; CREATE TABLE edgv.centroide_area_construida_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4615,24 +4615,24 @@ CREATE TABLE edgv.centroide_area_construida_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT centroide_area_construida_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX centroide_area_construida_p_geom ON edgv.centroide_area_construida_p USING gist (geom)# +); +CREATE INDEX centroide_area_construida_p_geom ON edgv.centroide_area_construida_p USING gist (geom); -ALTER TABLE edgv.centroide_area_construida_p OWNER TO postgres# +ALTER TABLE edgv.centroide_area_construida_p OWNER TO postgres; ALTER TABLE edgv.centroide_area_construida_p ADD CONSTRAINT centroide_area_construida_p_densamente_edificada_fk FOREIGN KEY (densamente_edificada) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.centroide_area_construida_p ALTER COLUMN densamente_edificada SET DEFAULT 9999# +ALTER TABLE edgv.centroide_area_construida_p ALTER COLUMN densamente_edificada SET DEFAULT 9999; ALTER TABLE edgv.centroide_area_construida_p ADD CONSTRAINT centroide_area_construida_p_assentamento_precario_fk FOREIGN KEY (assentamento_precario) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.centroide_area_construida_p ALTER COLUMN assentamento_precario SET DEFAULT 9999# +ALTER TABLE edgv.centroide_area_construida_p ALTER COLUMN assentamento_precario SET DEFAULT 9999; CREATE TABLE edgv.centroide_ilha_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4642,17 +4642,17 @@ CREATE TABLE edgv.centroide_ilha_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT centroide_ilha_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX centroide_ilha_p_geom ON edgv.centroide_ilha_p USING gist (geom)# +); +CREATE INDEX centroide_ilha_p_geom ON edgv.centroide_ilha_p USING gist (geom); -ALTER TABLE edgv.centroide_ilha_p OWNER TO postgres# +ALTER TABLE edgv.centroide_ilha_p OWNER TO postgres; ALTER TABLE edgv.centroide_ilha_p ADD CONSTRAINT centroide_ilha_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_ilha (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.centroide_ilha_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.centroide_ilha_p ALTER COLUMN tipo SET DEFAULT 9999; CREATE TABLE edgv.centroide_elemento_hidrografico_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4662,21 +4662,21 @@ CREATE TABLE edgv.centroide_elemento_hidrografico_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT centroide_elemento_hidrografico_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX centroide_elemento_hidrografico_p_geom ON edgv.centroide_elemento_hidrografico_p USING gist (geom)# +); +CREATE INDEX centroide_elemento_hidrografico_p_geom ON edgv.centroide_elemento_hidrografico_p USING gist (geom); -ALTER TABLE edgv.centroide_elemento_hidrografico_p OWNER TO postgres# +ALTER TABLE edgv.centroide_elemento_hidrografico_p OWNER TO postgres; ALTER TABLE edgv.centroide_elemento_hidrografico_p ADD CONSTRAINT centroide_elemento_hidrografico_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_elemento_hidrografico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.centroide_elemento_hidrografico_p ADD CONSTRAINT centroide_elemento_hidrografico_p_tipo_check - CHECK (tipo = ANY(ARRAY[6 :: SMALLINT, 8 :: SMALLINT, 12 :: SMALLINT, 14 :: SMALLINT, 15 :: SMALLINT, 16 :: SMALLINT, 17 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (tipo = ANY(ARRAY[6 :: SMALLINT, 8 :: SMALLINT, 12 :: SMALLINT, 14 :: SMALLINT, 15 :: SMALLINT, 16 :: SMALLINT, 17 :: SMALLINT, 18 :: SMALLINT, 19 :: SMALLINT, 9999 :: SMALLINT])); -ALTER TABLE edgv.centroide_elemento_hidrografico_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.centroide_elemento_hidrografico_p ALTER COLUMN tipo SET DEFAULT 9999; CREATE TABLE edgv.centroide_limite_especial_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4687,24 +4687,24 @@ CREATE TABLE edgv.centroide_limite_especial_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT centroide_limite_especial_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX centroide_limite_especial_p_geom ON edgv.centroide_limite_especial_p USING gist (geom)# +); +CREATE INDEX centroide_limite_especial_p_geom ON edgv.centroide_limite_especial_p USING gist (geom); -ALTER TABLE edgv.centroide_limite_especial_p OWNER TO postgres# +ALTER TABLE edgv.centroide_limite_especial_p OWNER TO postgres; ALTER TABLE edgv.centroide_limite_especial_p ADD CONSTRAINT centroide_limite_especial_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_limite_especial (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.centroide_limite_especial_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.centroide_limite_especial_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.centroide_limite_especial_p ADD CONSTRAINT centroide_limite_especial_p_geometria_aproximada_fk FOREIGN KEY (geometria_aproximada) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.centroide_limite_especial_p ALTER COLUMN geometria_aproximada SET DEFAULT 9999# +ALTER TABLE edgv.centroide_limite_especial_p ALTER COLUMN geometria_aproximada SET DEFAULT 9999; CREATE TABLE edgv.edicao_texto_generico_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4720,17 +4720,17 @@ CREATE TABLE edgv.edicao_texto_generico_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT edicao_texto_generico_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_texto_generico_p_geom ON edgv.edicao_texto_generico_p USING gist (geom)# +); +CREATE INDEX edicao_texto_generico_p_geom ON edgv.edicao_texto_generico_p USING gist (geom); -ALTER TABLE edgv.edicao_texto_generico_p OWNER TO postgres# +ALTER TABLE edgv.edicao_texto_generico_p OWNER TO postgres; ALTER TABLE edgv.edicao_texto_generico_p ADD CONSTRAINT edicao_texto_generico_p_justificativa_txt_fk FOREIGN KEY (justificativa_txt) REFERENCES dominios.justificativa (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_texto_generico_p ALTER COLUMN justificativa_txt SET DEFAULT 9999# +ALTER TABLE edgv.edicao_texto_generico_p ALTER COLUMN justificativa_txt SET DEFAULT 9999; CREATE TABLE edgv.edicao_texto_generico_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4743,10 +4743,10 @@ CREATE TABLE edgv.edicao_texto_generico_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT edicao_texto_generico_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_texto_generico_l_geom ON edgv.edicao_texto_generico_l USING gist (geom)# +); +CREATE INDEX edicao_texto_generico_l_geom ON edgv.edicao_texto_generico_l USING gist (geom); -ALTER TABLE edgv.edicao_texto_generico_l OWNER TO postgres# +ALTER TABLE edgv.edicao_texto_generico_l OWNER TO postgres; CREATE TABLE edgv.edicao_simb_cota_mestra_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4755,54 +4755,70 @@ CREATE TABLE edgv.edicao_simb_cota_mestra_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT edicao_simb_cota_mestra_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_simb_cota_mestra_l_geom ON edgv.edicao_simb_cota_mestra_l USING gist (geom)# +); +CREATE INDEX edicao_simb_cota_mestra_l_geom ON edgv.edicao_simb_cota_mestra_l USING gist (geom); -ALTER TABLE edgv.edicao_simb_cota_mestra_l OWNER TO postgres# +ALTER TABLE edgv.edicao_simb_cota_mestra_l OWNER TO postgres; CREATE TABLE edgv.edicao_simb_torre_energia_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), simb_rot real, + visivel smallint NOT NULL, observacao varchar(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edicao_simb_torre_energia_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_simb_torre_energia_p_geom ON edgv.edicao_simb_torre_energia_p USING gist (geom)# +); +CREATE INDEX edicao_simb_torre_energia_p_geom ON edgv.edicao_simb_torre_energia_p USING gist (geom); + +ALTER TABLE edgv.edicao_simb_torre_energia_p OWNER TO postgres; -ALTER TABLE edgv.edicao_simb_torre_energia_p OWNER TO postgres# +ALTER TABLE edgv.edicao_simb_torre_energia_p + ADD CONSTRAINT edicao_simb_torre_energia_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION; + +ALTER TABLE edgv.edicao_simb_torre_energia_p ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.edicao_identificador_trecho_rod_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), sigla varchar(255), tipo smallint NOT NULL, jurisdicao smallint NOT NULL, + visivel smallint NOT NULL, observacao varchar(255), geom geometry(MultiPoint, [epsg]), CONSTRAINT edicao_identificador_trecho_rod_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_identificador_trecho_rod_p_geom ON edgv.edicao_identificador_trecho_rod_p USING gist (geom)# +); +CREATE INDEX edicao_identificador_trecho_rod_p_geom ON edgv.edicao_identificador_trecho_rod_p USING gist (geom); -ALTER TABLE edgv.edicao_identificador_trecho_rod_p OWNER TO postgres# +ALTER TABLE edgv.edicao_identificador_trecho_rod_p OWNER TO postgres; ALTER TABLE edgv.edicao_identificador_trecho_rod_p ADD CONSTRAINT edicao_identificador_trecho_rod_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_via_deslocamento (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_identificador_trecho_rod_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.edicao_identificador_trecho_rod_p ALTER COLUMN tipo SET DEFAULT 9999; ALTER TABLE edgv.edicao_identificador_trecho_rod_p ADD CONSTRAINT edicao_identificador_trecho_rod_p_jurisdicao_fk FOREIGN KEY (jurisdicao) REFERENCES dominios.jurisdicao (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; ALTER TABLE edgv.edicao_identificador_trecho_rod_p ADD CONSTRAINT edicao_identificador_trecho_rod_p_jurisdicao_check - CHECK (jurisdicao = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT]))# + CHECK (jurisdicao = ANY(ARRAY[1 :: SMALLINT, 2 :: SMALLINT, 9999 :: SMALLINT])); + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p ALTER COLUMN jurisdicao SET DEFAULT 9999; + +ALTER TABLE edgv.edicao_identificador_trecho_rod_p + ADD CONSTRAINT edicao_identificador_trecho_rod_p_visivel_fk FOREIGN KEY (visivel) + REFERENCES dominios.booleano (code) MATCH FULL + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_identificador_trecho_rod_p ALTER COLUMN jurisdicao SET DEFAULT 9999# +ALTER TABLE edgv.edicao_identificador_trecho_rod_p ALTER COLUMN visivel SET DEFAULT 9999; CREATE TABLE edgv.edicao_simb_vegetacao_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4811,10 +4827,10 @@ CREATE TABLE edgv.edicao_simb_vegetacao_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT edicao_simb_vegetacao_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_simb_vegetacao_p_geom ON edgv.edicao_simb_vegetacao_p USING gist (geom)# +); +CREATE INDEX edicao_simb_vegetacao_p_geom ON edgv.edicao_simb_vegetacao_p USING gist (geom); -ALTER TABLE edgv.edicao_simb_vegetacao_p OWNER TO postgres# +ALTER TABLE edgv.edicao_simb_vegetacao_p OWNER TO postgres; CREATE TABLE edgv.edicao_simb_direcao_corrente_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4823,10 +4839,10 @@ CREATE TABLE edgv.edicao_simb_direcao_corrente_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT edicao_simb_direcao_corrente_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_simb_direcao_corrente_p_geom ON edgv.edicao_simb_direcao_corrente_p USING gist (geom)# +); +CREATE INDEX edicao_simb_direcao_corrente_p_geom ON edgv.edicao_simb_direcao_corrente_p USING gist (geom); -ALTER TABLE edgv.edicao_simb_direcao_corrente_p OWNER TO postgres# +ALTER TABLE edgv.edicao_simb_direcao_corrente_p OWNER TO postgres; CREATE TABLE edgv.edicao_simb_area_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4836,17 +4852,17 @@ CREATE TABLE edgv.edicao_simb_area_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT edicao_simb_area_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_simb_area_p_geom ON edgv.edicao_simb_area_p USING gist (geom)# +); +CREATE INDEX edicao_simb_area_p_geom ON edgv.edicao_simb_area_p USING gist (geom); -ALTER TABLE edgv.edicao_simb_area_p OWNER TO postgres# +ALTER TABLE edgv.edicao_simb_area_p OWNER TO postgres; ALTER TABLE edgv.edicao_simb_area_p ADD CONSTRAINT edicao_simb_area_p_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_simbolo_area (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_simb_area_p ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.edicao_simb_area_p ALTER COLUMN tipo SET DEFAULT 9999; CREATE TABLE edgv.edicao_borda_elemento_hidrografico_l( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4855,17 +4871,17 @@ CREATE TABLE edgv.edicao_borda_elemento_hidrografico_l( geom geometry(MultiLinestring, [epsg]), CONSTRAINT edicao_borda_elemento_hidrografico_l_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_borda_elemento_hidrografico_l_geom ON edgv.edicao_borda_elemento_hidrografico_l USING gist (geom)# +); +CREATE INDEX edicao_borda_elemento_hidrografico_l_geom ON edgv.edicao_borda_elemento_hidrografico_l USING gist (geom); -ALTER TABLE edgv.edicao_borda_elemento_hidrografico_l OWNER TO postgres# +ALTER TABLE edgv.edicao_borda_elemento_hidrografico_l OWNER TO postgres; ALTER TABLE edgv.edicao_borda_elemento_hidrografico_l ADD CONSTRAINT edicao_borda_elemento_hidrografico_l_tipo_fk FOREIGN KEY (tipo) REFERENCES dominios.tipo_borda_elemento_hidrografico (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_borda_elemento_hidrografico_l ALTER COLUMN tipo SET DEFAULT 9999# +ALTER TABLE edgv.edicao_borda_elemento_hidrografico_l ALTER COLUMN tipo SET DEFAULT 9999; CREATE TABLE edgv.edicao_ponto_mudanca_p( id uuid NOT NULL DEFAULT uuid_generate_v4(), @@ -4876,14 +4892,14 @@ CREATE TABLE edgv.edicao_ponto_mudanca_p( geom geometry(MultiPoint, [epsg]), CONSTRAINT edicao_ponto_mudanca_p_pk PRIMARY KEY (id) WITH (FILLFACTOR = 80) -)# -CREATE INDEX edicao_ponto_mudanca_p_geom ON edgv.edicao_ponto_mudanca_p USING gist (geom)# +); +CREATE INDEX edicao_ponto_mudanca_p_geom ON edgv.edicao_ponto_mudanca_p USING gist (geom); -ALTER TABLE edgv.edicao_ponto_mudanca_p OWNER TO postgres# +ALTER TABLE edgv.edicao_ponto_mudanca_p OWNER TO postgres; ALTER TABLE edgv.edicao_ponto_mudanca_p ADD CONSTRAINT edicao_ponto_mudanca_p_visivel_fk FOREIGN KEY (visivel) REFERENCES dominios.booleano (code) MATCH FULL - ON UPDATE NO ACTION ON DELETE NO ACTION# + ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE edgv.edicao_ponto_mudanca_p ALTER COLUMN visivel SET DEFAULT 9999# \ No newline at end of file +ALTER TABLE edgv.edicao_ponto_mudanca_p ALTER COLUMN visivel SET DEFAULT 9999; \ No newline at end of file diff --git a/DsgTools/core/Factories/DbFactory/abstractDb.py b/DsgTools/core/Factories/DbFactory/abstractDb.py index a84ed83a0..254e9eef7 100644 --- a/DsgTools/core/Factories/DbFactory/abstractDb.py +++ b/DsgTools/core/Factories/DbFactory/abstractDb.py @@ -894,6 +894,8 @@ def getStyleDirectory(self, dbVersion): styleDir = os.path.join(styleDir, "edgv_3") elif dbVersion == "3.0 Pro": styleDir = os.path.join(styleDir, "edgv_3_pro") + elif dbVersion == "3.0 Orto": + styleDir = os.path.join(styleDir, "edgv_300_orto") elif dbVersion == "FTer_2a_Ed": styleDir = os.path.join(styleDir, "edgv_FTer_2a_Ed") else: diff --git a/DsgTools/core/Factories/DbFactory/postgisDb.py b/DsgTools/core/Factories/DbFactory/postgisDb.py index 56508a481..47a531296 100644 --- a/DsgTools/core/Factories/DbFactory/postgisDb.py +++ b/DsgTools/core/Factories/DbFactory/postgisDb.py @@ -1112,10 +1112,7 @@ def checkTemplateImplementationVersion(self, edgvVersion=None): templateName = self.getTemplateName(edgvVersion) fileImplementationVersion = self.getImplementationVersionFromFile(edgvVersion) templateImplementationVersion = self.getImplementationVersion() - if templateImplementationVersion < fileImplementationVersion: - return True - else: - return False + return templateImplementationVersion < fileImplementationVersion def dropDatabase(self, candidateName, dropTemplate=False): """ @@ -3507,6 +3504,8 @@ def getTemplateName(self, version): return "template_edgv_3" elif version in ("EDGV 3.0 Pro", "3.0 Pro"): return "template_edgv_3_pro" + elif version in ("EDGV 3.0 Orto", "3.0 Orto"): + return "template_edgv_3_orto" def setDbAsTemplate( self, version=None, dbName=None, setTemplate=True, useTransaction=True @@ -3602,6 +3601,18 @@ def getCreationSqlPath(self, version): "3_Pro", "edgv3_pro.sql", ) + elif version in ("3.0 Orto", "EDGV 3.0 Orto"): + edgvPath = os.path.join( + currentPath, + "..", + "..", + "..", + "core", + "DbModels", + "PostGIS", + "3_Orto", + "edgv3_orto.sql", + ) elif version == "admin": edgvPath = os.path.join( currentPath, @@ -3638,7 +3649,7 @@ def getImplementationVersionFromFile(self, edgvVersion): if searchString in command: return ( command.split(searchString)[-1] - .split(",")[-1] + .split(",")[1] .replace(")", "") .replace("'", "") ) diff --git a/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py b/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py index 75d01ae4d..2e52cfb33 100644 --- a/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py +++ b/DsgTools/core/Factories/SqlFactory/postgisSqlGenerator.py @@ -1546,7 +1546,7 @@ def alterSearchPath(self, dbName, version): sql = "ALTER DATABASE \"{0}\" SET search_path = \"$user\", public, topology,'edgv','dominios';".format( dbName ) - elif version in ("3.0", "3.0 Pro"): + elif version in ("3.0", "3.0 Pro", "3.0 Orto"): sql = "ALTER DATABASE \"{0}\" SET search_path = \"$user\", public, topology, pg_catalog, 'edgv' ,'dominios';".format( dbName ) diff --git a/DsgTools/core/Factories/ThreadFactory/postgisDbThread.py b/DsgTools/core/Factories/ThreadFactory/postgisDbThread.py index 44bab6c93..27bff6e0b 100644 --- a/DsgTools/core/Factories/ThreadFactory/postgisDbThread.py +++ b/DsgTools/core/Factories/ThreadFactory/postgisDbThread.py @@ -145,6 +145,10 @@ def createDatabaseStructure(self): edgvPath = os.path.join(currentPath, "sqls", "213_Pro", "edgv213_pro.sql") elif self.version == "3.0": edgvPath = os.path.join(currentPath, "sqls", "3", "edgv3.sql") + elif self.version == "3.0 Pro": + edgvPath = os.path.join(currentPath, "sqls", "3_Pro", "edgv3_pro.sql") + elif self.version == "3.0 Orto": + edgvPath = os.path.join(currentPath, "sqls", "3_Orto", "edgv300_orto.sql") else: edgvPath = "" return self.loadDatabaseStructure(edgvPath) diff --git a/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/connectionComboBox.py b/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/connectionComboBox.py index 133e7b6d8..b0a32dae5 100644 --- a/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/connectionComboBox.py +++ b/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/connectionComboBox.py @@ -68,6 +68,7 @@ def __init__(self, parent=None, isStatic=False): "Non_EDGV": self.tr("Other database model"), "3.0": "EDGV 3.0", "3.0 Pro": "EDGV 3.0 Pro", + "3.0 Orto": "EDGV 3.0 Orto", } self.instantiateAbstractDb = False self.isStatic = isStatic diff --git a/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/databaseFileLineEdit.py b/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/databaseFileLineEdit.py index 89f00ccb7..65d8ca5b6 100644 --- a/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/databaseFileLineEdit.py +++ b/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/databaseFileLineEdit.py @@ -64,6 +64,7 @@ def __init__(self, parent=None): "Non_EDGV": self.tr("Other database model"), "3.0": "EDGV 3.0", "3.0 Pro": "EDGV 3.0 Pro", + "3.0 Orto": "EDGV 3.0 Orto", } self.instantiateAbstractDb = False self.connectionSelectorLineEdit.lineEdit.setText(self.tr("Select datasource")) diff --git a/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/newConnectionLineEdit.py b/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/newConnectionLineEdit.py index 82d2a1403..8a512f209 100644 --- a/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/newConnectionLineEdit.py +++ b/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/newConnectionLineEdit.py @@ -90,6 +90,7 @@ def fillEdgvVersions(self): "EDGV 2.1.3 Pro", "EDGV 3.0", "EDGV 3.0 Pro", + "EDGV 3.0 Orto", ] self.edgvComboBox.addItems(versions) diff --git a/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/newDatabaseLineEdit.py b/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/newDatabaseLineEdit.py index 428cb4974..fe33607ca 100644 --- a/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/newDatabaseLineEdit.py +++ b/DsgTools/gui/CustomWidgets/ConnectionWidgets/AdvancedConnectionWidgets/newDatabaseLineEdit.py @@ -78,6 +78,7 @@ def fillEdgvVersions(self): "EDGV 2.1.3 Pro", "EDGV 3.0", "EDGV 3.0 Pro", + "EDGV 3.0 Orto", ] self.edgvComboBox.addItems(versions) diff --git a/DsgTools/gui/CustomWidgets/DatabasePropertiesWidgets/BasicPropertyWidgets/databaseParameterWidget.ui b/DsgTools/gui/CustomWidgets/DatabasePropertiesWidgets/BasicPropertyWidgets/databaseParameterWidget.ui index 66fc4f77c..6571c0289 100644 --- a/DsgTools/gui/CustomWidgets/DatabasePropertiesWidgets/BasicPropertyWidgets/databaseParameterWidget.ui +++ b/DsgTools/gui/CustomWidgets/DatabasePropertiesWidgets/BasicPropertyWidgets/databaseParameterWidget.ui @@ -75,6 +75,11 @@ 3.0 Pro + + + 3.0 Orto + + diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 0a44f7098..7f833af87 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.38 +version=4.11.39 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= From 1b6be08d7b07d3be6642949b253c19b569526b7f Mon Sep 17 00:00:00 2001 From: phborba Date: Wed, 13 Dec 2023 17:09:48 -0300 Subject: [PATCH 53/53] =?UTF-8?q?altera=20vers=C3=A3o=20para=20lan=C3=A7ar?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 2 +- DsgTools/metadata.txt | 53 ++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 53 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7af38da95..2b2ad04be 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # CHANGELOG -## 4.11.39 - dev +## 4.12.0 - 2023-12-13 Novas Funcionalidades: diff --git a/DsgTools/metadata.txt b/DsgTools/metadata.txt index 7f833af87..920f8f178 100644 --- a/DsgTools/metadata.txt +++ b/DsgTools/metadata.txt @@ -10,7 +10,7 @@ name=DSG Tools qgisMinimumVersion=3.22 description=Brazilian Army Cartographic Production Tools -version=4.11.39 +version=4.12.0 author=Brazilian Army Geographic Service email=dsgtools@dsg.eb.mil.br about= @@ -44,6 +44,57 @@ about= # Uncomment the following line and add your changelog: changelog= + 4.12.0: + Novas Funcionalidades: + - Novo processo de corrigir erros de segmentação em linhas (barragem versus rodovias); + - Novo processo para validar a estrutura do banco de dados em relação ao masterfile; + - Novo processo de detectar as mudanças entre dois banco de dados, realizados em dias distintos; + - Novo processo de identificar erros de intersecção entre curvas de nível e massas d'água; + - Novo processo de criar grid por meio de informar as coordenadas dos extremos; + - Adicionado atalho para ativar/desativar modo reclassificação; + - Novo processo de criar pacote de shapefile (utilizado normalmente para preparar a carga no BDGEx); + - Novo processo de generalizar trechos de drenagem de acordo com o comprimento; + - Adicionado o modelo EDGV 3.0 Orto; + Melhorias: + - O estado do Menu de classificação agora é salvo no projeto; + - Adiciona parâmetros opcionais na rotina de extração de pontos cotados; + - Melhoria de desempenho na extração de pontos cotados; + - O seletor genérico agora ignora camadas somente leitura; + - Melhoria de desempenho no processo Unir Linhas com Mesmo Conjunto de Atributos (Merge Lines With Same Attribute Set): Código refatorado para usar busca utilizando grafo. Além disso, o processo pega casos que não eram unidos anteriormente (linhas com mesmo conjunto de atributos e encadeadas); + - Melhoria de desempenho no processo Identify Unmerged Lines With Same Attribute Set: Código refatorado para usar busca utilizando grafo; + - O detecta nula agora indica quais camadas tem que ser verificadas; + - Algoritmos da caixa de ferramentas reorganizados por temática para facilitar o uso; + - A interface de carregamento agora filtra também na coluna de categoria da camada; + - O menu de aquisição agora mantém a camada ativa quando reclassifica uma feição no modo de reclassificação; + - Adicionado botão de selecionar a camada ativa na barra de ferramentas de revisão; + - Adicionada a opção de uso da tag "NULL" no atributo do botão do menu para preencher o campo com o valor nulo na atributação e reclassificação do menu de aquisição; + - O processo de carregar shapefiles agora agrupa por pasta, caso seja dado como entrada uma pasta que possui pastas com shapefiles; + - Melhoria de desempenho no processo de generalizar trechos de drenagem; + Correção de bug: + - Corrige bug de quando o usuário tenta reclassificar primitivas não compatíveis utilizando o menu de classificação; + - Corrige bug na rotina de extração de pontos cotados; + - Corrige bug de flags incorretas na rotina de identificar erros de segmentação em linhas (Identify Segment Errors Between Lines); + - Corrige bug de número de conexões ativas na ferramenta de setar estilo do banco (os métodos nativos do QGIS abrem conexão e não fecham, dessa forma derrubando todo mundo da produção por exceder o número máximo de conexões defindo no postgres.conf); + - Corrige bug no processo de verificar atributo unicode; + - Corrige bug no processo de identificar pontas soltas (retira distância mínima na busca, agora pega erro até no "mundo quântico"); + - Corrige bug na ferramenta de inverter o sentido de linhas (flip lines) quando é uma camada não salva do banco de dados; + - Corrige bug na geração de moldura relativo a camada (Generate Systematic Grid Related to Layer) quando se usa memory layer (o memory layer não atualiza seu extent automaticamente, logo foi necessário colocar um layer.updateExtents() no código antes de calcular o extent); + - Corrige bug no processo de calcular azimute (estava sendo calculado com +90 graus); + - Corrige bug no ClipAndCopyFeaturesBetweenDatabasesAlgorithm; + - Corrige bug no VerifyAdjacentGeographicBoundaryDataAlgorithm (verifica interseção na moldura, não apenas no boundingbox); + - Corrige bug na rotina de extrair automaticamente pontos cotados (Extract Spot Elevation); + - Corrige bug da interface de carregamento não listar camadas do tipo GEOMETRY (genéricas normalmente criadas pelo FME). A camada que tiver esse tipo vai ser carregada em um nó chamado Geometry; + - Corrige bug dos parâmetros do clean não permitirem casas decimais o suficiente; + - Corrige bug de crash no qgis no algoritmo AddUnsharedVertexOnIntersectionsAlgorithm; + - Corrige bug de quando o usuário tenta reclassificar primitivas não compatíveis utilizando o menu de classificação; + - Corrige bug de quando o usuário tenta classificar com o formulário suprimido; + - Corrige bug de quando o usuário tenta classificar e o camada do botão não estava mudando; + - Corrige bug na interface do carregamento de feições, em bancos não EDGV; + - Corrige bug no processo de geometria inválida quando há geometria nula ou vazia; + - Corrige bug no processo de verificar atributo unicode (não estava gerando flag por erro de definição de geometria da camada); + - Corrige bug em parâmetro do algoritmo de verificação de regras de construção do terreno; + - Correção de bug no modelo EDGV 3.0 Pro; + - Correção de bug no modelo EDGV 3.0; 4.10.1: Melhoria: - Adicionado o modelo EDGV 3.0 Pro;