Projeto

Geral

Perfil

Levantamentos #428 » AnaliseExploratoriaPopulacao.sql

 
select sg_uf, co_municipio_ibge, co_uf_ibge, no_municipio
from dbgeral.tb_municipio
where st_registro_ativo='S';

select co_municipio_ibge, qt_populacao, qt_popfaixaetaria_60oumais
from dbgeral.tb_populacao
where nu_ano_referencia=2021
order by nu_ano_referencia;

select * from dbgeral.tb_populacao_residente;

select nu_ano from dbgeral.tb_populacao_residente group by nu_ano order by nu_ano;

select * from dbgeral.tb_municipio;

select co_municipio_ibge, nu_ano, sg_uf, tp_sexo, tp_domicilio, ds_faixa_etaria, qt_populacao, co_sexo
from dbgeral.tb_populacao_residente
where nu_ano=2021;

/*N?o d? pra usar dbgeral.tb_populacao_residente*/

select nu_ano from dbgeral.vw_populacaoresidente_reduzida group by nu_ano order by nu_ano; --1980 / 2012
(5-5/9)