Update 004 ACTUALIZAR ESTADOS CONVENIOS.sql
This commit is contained in:
parent
a0afde6baf
commit
dbc43ed9f0
@ -2,13 +2,21 @@ use telus;
|
|||||||
|
|
||||||
/*verificar convenios antes del 2024*/
|
/*verificar convenios antes del 2024*/
|
||||||
|
|
||||||
--exec agcm_telus_avaluo_emision_consulta 49132, '2024-02-19'
|
--exec agcm_telus_avaluo_emision_consulta 27437, '2024-02-08'
|
||||||
|
|
||||||
|
--select * from agcm_2022_tram_liquidaciones_convenio where lote_id IN (80487, 27969)
|
||||||
|
--update agcm_2022_tram_liquidaciones_convenio set estado = 'ACTIVO' where lote_id IN (27969)
|
||||||
|
--select * from avaluo_emision_anual_cabecera where lote_id IN (27969);
|
||||||
|
--update avaluo_emision_anual_cabecera set esta_convenio = 1 whedre emision_id = 2085664
|
||||||
|
--select * from rentas_estado WHERE registro_lote_id IN (80487, 27969);
|
||||||
|
--select * from rentas_estado WHERE registro_lote_id = 80487;
|
||||||
|
|
||||||
if OBJECT_ID('tempdb.dbo.#convenios_revisar') is not null
|
if OBJECT_ID('tempdb.dbo.#convenios_revisar') is not null
|
||||||
drop table #convenios_revisar
|
drop table #convenios_revisar
|
||||||
|
|
||||||
select id
|
select id
|
||||||
into #convenios_revisar
|
into #convenios_revisar
|
||||||
from db_olympo_web.dbo.convenios_cabecera where code in('002538');
|
from db_olympo_web.dbo.convenios_cabecera where code in('002333');
|
||||||
|
|
||||||
select b.ClaveCatastral, a.* from agcm_2022_tram_liquidaciones_convenio a
|
select b.ClaveCatastral, a.* from agcm_2022_tram_liquidaciones_convenio a
|
||||||
inner join telus_procesos.dbo.agcm_datos_claves_avaluos b on a.lote_id = b.lote_id
|
inner join telus_procesos.dbo.agcm_datos_claves_avaluos b on a.lote_id = b.lote_id
|
||||||
@ -28,7 +36,7 @@ select b.* from avaluo_emision_anual_cabecera b
|
|||||||
order by b.lote_id
|
order by b.lote_id
|
||||||
|
|
||||||
|
|
||||||
--update avaluo_emision_anual_cabecera set esta_convenio = 0 where emision_id in(1947170,1947170)and esta_convenio = 1
|
--update avaluo_emision_anual_cabecera set esta_convenio = 0 where emision_id in(1740009)and esta_convenio = 1
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user