CNEFE: mudanças entre as edições

De Documentação
Linha 5: Linha 5:


== Faces de Quadra ==
== Faces de Quadra ==
Pegar em 4314902_faces_de_logradouros_2021.prj


<pre>
mkdir /tmp/POA_FACES/


cd /tmp/POA_FACES
wget https://dl.digital-guard.org/5d5daa06e048ad8c83c909babee040e26fd8a54a29ed4cef2d2d220a3bd17b84.zip
zip -T 5d5daa06e048ad8c83c909babee040e26fd8a54a29ed4cef2d2d220a3bd17b84.zip
cd '/tmp/5d5daa06e048ad8c83c909babee040e26fd8a54a29ed4cef2d2d220a3bd17b84/rs_faces_de_logradouros_2021/'
cp 4314902* /tmp/POA_FACES
</pre>
Supor arquivos logradouro em log:
<pre>
create database poa;
\c poa
create extension postgis;
-----
shp2pgsql  log | psql -q postgres://postgres@localhost/poa
</pre>


== Pontos ==
== Pontos ==

Edição das 21h58min de 30 de maio de 2024

CNEFE - Cadastro Nacional de Endereços para Fins Estatísticos

Ver https://www.ibge.gov.br/estatisticas/sociais/populacao/38734-cadastro-nacional-de-enderecos-para-fins-estatisticos.html?edicao=40122&t=resultados

Faces de Quadra

Pegar em 4314902_faces_de_logradouros_2021.prj

mkdir /tmp/POA_FACES/

cd /tmp/POA_FACES

wget https://dl.digital-guard.org/5d5daa06e048ad8c83c909babee040e26fd8a54a29ed4cef2d2d220a3bd17b84.zip

zip -T 5d5daa06e048ad8c83c909babee040e26fd8a54a29ed4cef2d2d220a3bd17b84.zip

cd '/tmp/5d5daa06e048ad8c83c909babee040e26fd8a54a29ed4cef2d2d220a3bd17b84/rs_faces_de_logradouros_2021/'
cp 4314902* /tmp/POA_FACES

Supor arquivos logradouro em log:

create database poa;
\c poa
create extension postgis;
-----
shp2pgsql  log | psql -q postgres://postgres@localhost/poa

Pontos

Por cidade temos Censo_Demografico_2022/Arquivos_CNEFE/Municipio, direto latLong em srid=4326.

Pelo cabeçalho podemos copiar para uma tabela texto,

CREATE TABLE ibge_cnefe2022 (
COD_UNICO_ENDERECO text,
COD_UF text,
COD_MUNICIPIO text,
COD_DISTRITO text,
COD_SUBDISTRITO text,
COD_SETOR text,
NUM_QUADRA text,
NUM_FACE text,
CEP text,
DSC_LOCALIDADE text,
NOM_TIPO_SEGLOGR text,
NOM_TITULO_SEGLOGR text,
NOM_SEGLOGR text,
NUM_ENDERECO text,
DSC_MODIFICADOR text,
NOM_COMP_ELEM1 text,
VAL_COMP_ELEM1 text,
NOM_COMP_ELEM2 text,
VAL_COMP_ELEM2 text,
NOM_COMP_ELEM3 text,
VAL_COMP_ELEM3 text,
NOM_COMP_ELEM4 text,
VAL_COMP_ELEM4 text,
NOM_COMP_ELEM5 text,
VAL_COMP_ELEM5 text,
LATITUDE real,
LONGITUDE real,
NV_GEO_COORD text,
COD_ESPECIE text,
DSC_ESTABELECIMENTO text,
COD_INDICADOR_ESTAB_ENDERECO text,
COD_INDICADOR_CONST_ENDERECO text,
COD_INDICADOR_FINALIDADE_CONST text,
COD_TIPO_ESPECI text
);
copy ibge_cnefe2022 from '/tmp/POA_FACES/4314902_PORTO_ALEGRE.csv' with  (format CSV, delimiter ';', header);