<?xml version="1.0" encoding="UTF-8"?>
<jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="informe_general_compromisos" language="groovy" pageWidth="1944" pageHeight="612" orientation="Landscape" columnWidth="1904" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20">
	<property name="ireport.zoom" value="1.4641000000000013"/>
	<property name="ireport.x" value="0"/>
	<property name="ireport.y" value="0"/>
	<property name="ireport.jasperserver.reportUnit" value="/reports/presupuesto/informe_general_compromisos"/>
	<property name="ireport.jasperserver.url" value="http://soporte14.sofhouse.net:8090/jasperserver/services/repository"/>
	<parameter name="whereObj" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<parameter name="fechai" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="fechaf" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="vigencia" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="id_vigencia" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="whereOpciones" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<parameter name="whereUltimo" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<parameter name="mescorte" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="fechainicial" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="fechafinal" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<queryString>
		<![CDATA[select * from (

		select p.codigo as codigo, prc.id_rp as ID_RP,
		obg.abreviatura as OBJ,
		prp.fecha_proceso as fecha,ter.num_doc AS DOCUMENTO,
		 case when ter.razon_soc IS NOT NULL then ter.razon_soc else (ter.pnombre|| ' ' ||ter.snombre|| ' ' || ter.papellido || ' ' || ter.sapellido) end as tercero,
		nvl(valfin.valor,0) as valor,
		nvl((obligaciones.suma),0) as valOb,
		nvl(reintegro.valor,0) as valrein,
		nvl((pagos.suma),0) as pagos, ( nvl(valfin.valor,0) - ( (nvl(pagos.suma,0)) - (nvl(anulacion.anul,0)) - (nvl(reintegro.valor,0)) ) ) as Saldo,
		ppg.descripcion as tipoDoc, to_char(ppg.no_acto_admin) as nro, nvl(anulacion.anul,0) as anul,
		prp.id_cdp,ppg.fecha_inicio AS FECHA_INICIO,ppg.fecha_fin AS FECHA_TERMINACION,cdp.fecha AS FECHA_CDP,ppg.supervisor
		from PROYECTOS p
		left join PR_RP_COMPROMISO prc ON p.id=prc.id_cpo $P!{whereObj}
		join OBJETOS_GASTO obg ON prc.id_obj_gasto = obg.id
		join PR_RP prp ON prc.id_rp = prp.id
		and prp.fecha_proceso >= to_date($P{fechai},'DD-MM-YYYY')
		and prp.fecha_proceso <= to_date($P{fechaf},'DD-MM-YYYY')
		and prp.vigencia = prc.vigencia
		and prp.id_vigencia = prc.id_vigencia
		join PR_ASIG_PRESUP pap ON prc.id_asign = pap.id
		left join (
		SELECT case when ter.razon_soc IS NOT NULL then ter.razon_soc else (ter.pnombre|| ' ' ||ter.snombre|| ' ' || ter.papellido || ' ' || ter.sapellido) end as supervisor,
		pg.no_acto_admin,clase.descripcion,pg.fecha_inicio,pg.fecha_fin,pg.vigencia,pg.id_vigencia,pg.id_rp
		FROM PR_PG pg
		JOIN INTERCEROS ter ON pg.id_tercero = ter.id_mae_ter
		join PR_CLASE_ACT_ADMIN clase ON pg.id_clase_admin = clase.id


		) ppg ON prc.id_rp = ppg.id_rp
		and prc.vigencia = ppg.vigencia
		and prc.id_vigencia = ppg.id_vigencia

		JOIN PR_CDP cdp ON cdp.id=prp.id_cdp and cdp.id_vigencia=prp.id_vigencia and cdp.ano_fiscal=prp.vigencia
		join INTERCEROS ter ON prp.id_tercero = ter.id_mae_ter
		join PR_APROPIACION pa ON pap.id_apropiacion = pa.id
		join PR_CODIF_PRESUP cod ON pa.id_rubro = cod.id_rubro
		join PR_PROG_GEN pgen ON cod.cod_rub1 = pgen.id
		join PR_TIPO_REC re ON pa.id_tipo_rec = re.id

		left join (
		select prp.id, p.id as id_cpo, prc.id_asign,prc.id_obj_gasto,
		case when sum(hist.valor) is null then sum(prc.valor) else ( nvl(hist.valor,0)+nvl(sum(nval.debito),0)-nvl(sum(nval.credito),0) ) end
		as VALOR, prp.id_vigencia, prp.vigencia, prp.id_tercero
		from PROYECTOS p
		left join PR_RP_COMPROMISO prc ON prc.id_cpo = p.id
		and prc.vigencia=$P{vigencia}
		and prc.id_vigencia=$P{id_vigencia}
		join PR_RP prp ON prc.id_rp = prp.id
		and prc.id_vigencia = prp.id_vigencia
		and prc.vigencia = prp.vigencia
		and prp.fecha_proceso <= to_date($P{fechaf},'DD-MM-YYYY')
		left join PR_HISTORIAL_RP hist ON prp.id = hist.id_rp
		and hist.id_vigencia = prp.id_vigencia
		and hist.vigencia = prp.vigencia
		and hist.id_asign = prc.id_asign
		and hist.id_obj_gasto = prc.id_obj_gasto
		and hist.id_cpo = prc.id_cpo
		left join
		(
		select novi.fecha, novi.id_rp, novi.id_vigencia, novi.vigencia, novi.id_novedad_rp
		from PR_NOVEDAD_RP novi
		where novi.fecha <= to_date($P{fechaf},'DD-MM-YYYY')
		)nov ON prp.id = nov.id_rp
		and nov.id_vigencia = prp.id_vigencia
		and nov.vigencia = prp.vigencia
		left join PR_NOVEDAD_RP_VAL nval ON nov.id_novedad_rp = nval.id_novedad_rp
		and nval.id_asign = prc.id_asign
		and nval.id_obj_gasto = prc.id_obj_gasto
		group by prp.id, p.id, prc.id_asign, prc.id_obj_gasto, hist.valor,prp.id_vigencia, prp.vigencia, prp.id_tercero
		)valfin ON prc.id_rp = valfin.id
		and obg.id = valfin.id_obj_gasto
		and p.id = valfin.id_cpo
		and prp.id_vigencia = valfin.id_vigencia
		and prp.vigencia = valfin.vigencia
		and prc.id_asign = valfin.id_asign
		and prp.id_tercero = valfin.id_tercero


		left join
		(
		select id_rp, sum(suma) as suma, id_obg, id_cpo, id_asign, vig, idvig
		from(
		select obl.id_rp as ID_RP, sum (tov.valor_obligacion) as suma,
		tov.id_obj_gasto as ID_OBG, tov.id_cpo as ID_CPO,
		tov.id_asign as ID_ASIGN, obl.ano_fiscal as vig,
		obl.id_vigencia as idvig, 'act' as des
		from TS_OBLIGACION obl
		join TS_OBLIGACION_VAL tov ON obl.id_obligacion = tov.id_obligacion
		and obl.secuencia = tov.secuencia
		and obl.ano_fiscal = tov.ano_fiscal
		and obl.id_vigencia = tov.id_vigencia
		where obl.fecha_proceso >= to_date($P{fechai},'DD-MM-YYYY')
		and obl.fecha_proceso <= to_date($P{fechaf},'DD-MM-YYYY') and obl.estado=1
		group by obl.id_rp, tov.id_obj_gasto, tov.id_cpo, tov.id_asign, obl.ano_fiscal, obl.id_vigencia, 'act'

		) group by id_rp, id_obg, id_cpo, id_asign, vig, idvig
		)obligaciones ON prc.id_rp = obligaciones.id_rp
		and pap.id = obligaciones.id_asign
		and prc.id_obj_gasto = obligaciones.id_obg
		and prc.vigencia = obligaciones.vig
		and prc.id_vigencia = obligaciones.idvig

		left join
		(
		select sum(oval.valor_obligacion) suma,
		oval.id_obj_gasto as id_obg, oval.id_cpo as id_cpo,
		oval.id_asign as id_asign, obl.id_rp as id_rp,
		obl.id_vigencia as idvig, obl.ano_fiscal as vig
		from TS_OBLIGACION obl
		join TS_PAGO_OBL pag ON pag.id_obligacion = obl.id_obligacion
		and pag.id_clase_pago is null
		and pag.secuencia = obl.secuencia
		and pag.vigencia = obl.ano_fiscal
		join TS_OBLIGACION_VAL oval ON obl.id_obligacion = oval.id_obligacion
		and oval.secuencia = obl.secuencia
		and oval.ano_fiscal =obl.ano_fiscal
		and oval.id_vigencia =obl.id_vigencia
		join TS_EMISION_PAGO emi ON pag.id_emision_pago = emi.id_emision_pago
		and emi.fecha_proc >=to_date($P{fechai},'DD-MM-YYYY')
		and emi.fecha_proc <=to_date($P{fechaf},'DD-MM-YYYY')
		where obl.ano_fiscal = $P{vigencia}and obl.id_vigencia =$P{id_vigencia}
		group by oval.id_obj_gasto, oval.id_cpo, oval.id_asign, obl.id_rp,obl.id_vigencia, obl.ano_fiscal

		)pagos ON prc.id_rp = pagos.id_rp
		and pap.id = pagos.id_asign
		and prc.id_obj_gasto = pagos.id_obg
		and prc.vigencia = pagos.vig
		and prc.id_vigencia = pagos.idvig
		left join(
		select id_rp, id_asig,id_obj_gasto, id_vigencia, vigencia, sum(reint) as valor
		from(
		select ob.id_obligacion as id_obliga, re.valor as reint, ob.id_asign as id_asig, ob.id_obj_gasto, ob.secuencia, p.id_pago_obl as id_reintegro, p.id_rp, ob.ano_fiscal as vigencia , ob.id_vigencia
		from TS_OBLIGACION_VAL ob
		join TS_PAGO_OBL p ON ob.id_obligacion = p.id_obligacion
		and ob.secuencia = p.secuencia
		and ob.id_vigencia = p.id_vigencia
		and ob.ano_fiscal = p.vigencia
		and p.id_clase_pago is null
		join (
		select r.id_pago_obl, d.id_cpo, d.id_asig, d.id_obj_gasto, sum(d.valor) as valor
		from PR_REINTEGRO r
		join PR_DETA_REIN d ON r.id_reintegro = d.id_reintegro
		where r.fecha_proceso >= to_date($P{fechai},'DD-MM-YYYY')
		and r.fecha_proceso <= to_date($P{fechaf},'DD-MM-YYYY')
		group by r.id_pago_obl, d.id_cpo, d.id_asig, d.id_obj_gasto
		)re ON p.id_pago_obl = re.id_pago_obl
		and ob.id_cpo = re.id_cpo
		and ob.id_asign =re.id_asig
		and ob.id_obj_gasto = re.id_obj_gasto

		union

		select obl.id_obligacion as id_obliga, pdr.valor*(-1) as reint, pdr.id_asig, pdr.id_obj_gasto, obl.secuencia,pr.id_reintegro, obl.id_rp, obl.ano_fiscal as vigencia,obl.id_vigencia
		from TS_OBLIGACION obl
		join TS_PAGO_OBL pag ON obl.id_obligacion = pag.id_obligacion
		and obl.ano_fiscal = pag.vigencia
		and obl.id_vigencia = pag.id_vigencia
		and obl.secuencia = pag.secuencia
		and pag.id_clase_pago IS NULL
		join PR_REINTEGRO pr ON pag.id_pago_obl = pr.id_pago_obl
		join PR_DETA_REIN pdr ON pr.id_reintegro = pdr.id_reintegro
		join TS_ANU_MOV_BANC anul ON anul.id_mov_banc = pr.id_mov_ban
		and anul.fecha_anul >= to_date($P{fechai},'DD-MM-YYYY')
		and anul.fecha_anul <= to_date($P{fechaf},'DD-MM-YYYY')
		where obl.ano_fiscal = $P{vigencia}

		union

		select obl.id_obligacion as id_obliga, sum(pdr.valor)*(-1) as reint, pdr.id_asig, pdr.id_obj_gasto, obl.secuencia, pr.id_reintegro, obl.id_rp, obl.ano_fiscal as vigencia, obl.id_vigencia
		from TS_OBLIGACION obl
		join TS_PAGO_OBL pag ON obl.id_obligacion = pag.id_obligacion
		and obl.ano_fiscal = pag.vigencia
		and obl.id_vigencia = pag.id_vigencia
		and obl.secuencia = pag.secuencia
		and pag.id_clase_pago IS NULL
		join PR_REINTEGRO pr ON pag.id_pago_obl = pr.id_pago_obl
		join PR_DETA_REIN pdr ON pr.id_reintegro = pdr.id_reintegro
		join TS_ANUL_RC anul ON anul.id_rc = pr.id_rc
		and anul.fecha_anul >= to_date($P{fechai},'DD-MM-YYYY')
		and anul.fecha_anul <= to_date($P{fechaf},'DD-MM-YYYY')
		where obl.ano_fiscal = '".$vigencia."'
		group by obl.id_obligacion, pdr.id_asig, pdr.id_obj_gasto, obl.secuencia,pr.id_reintegro, obl.id_rp, obl.ano_fiscal, obl.id_vigencia
		) group by id_rp, id_asig, id_obj_gasto, id_vigencia, vigencia
		)reintegro ON prc.id_rp = reintegro.id_rp
		and pap.id = reintegro.id_asig
		and prc.id_obj_gasto = reintegro.id_obj_gasto
		and prc.vigencia = reintegro.vigencia
		and prc.id_vigencia = reintegro.id_vigencia
		left join(
		select sum(tov.valor_obligacion) anul, tov.id_asign as id_asign, tov.ano_fiscal as vig, tov.id_vigencia as idvig, obl.id_rp as id_rp, tov.id_obj_gasto as id_obg
		from TS_OBLIGACION obl
		join TS_PAGO_OBL pag ON obl.id_obligacion = pag.id_obligacion
		and obl.ano_fiscal = pag.vigencia
		and obl.id_vigencia = pag.id_vigencia
		and obl.secuencia = pag.secuencia
		and pag.id_clase_pago IS NULL
		join TS_OBLIGACION_VAL tov ON obl.id_obligacion = tov.id_obligacion
		and obl.ano_fiscal = tov.ano_fiscal
		and obl.id_vigencia = tov.id_vigencia
		and obl.secuencia = tov.secuencia
		join TS_ANUL_PAGOS anul ON pag.id_pago_obl = anul.id_pago_obl
		and anul.fecha_anul >= to_date($P{fechai},'DD-MM-YYYY')
		and anul.fecha_anul <= to_date($P{fechaf},'DD-MM-YYYY')
		where obl.ano_fiscal = $P{vigencia} and obl.id_vigencia=$P{id_vigencia}
		group by tov.id_asign, tov.ano_fiscal, tov.id_vigencia, obl.id_rp, tov.id_obj_gasto
		)anulacion ON prc.id_rp = anulacion.id_rp
		and pap.id = anulacion.id_asign
		and prc.id_obj_gasto = anulacion.id_obg
		and prc.vigencia = anulacion.vig
		and prc.id_vigencia = anulacion.idvig

		where prc.vigencia=$P{vigencia}and prc.id_vigencia=$P{id_vigencia} and prc.valor IS NOT NULL $P!{whereOpciones}


		UNION

		select p.codigo as codigo, prc.id_rp as ID_RP,
		obg.abreviatura as OBJ,
		prp.fecha_proceso as fecha,ter.num_doc AS DOCUMENTO,
		case when ter.razon_soc IS NOT NULL then ter.razon_soc else (ter.pnombre|| ' ' ||ter.snombre|| ' ' || ter.papellido || ' ' || ter.sapellido) end as tercero,
		nvl(valfin.valor,0) as valor,
		nvl((obligaciones.suma),0) as valOb,
		nvl(reintegro.valor,0) as valrein,
		nvl((pagos.suma),0) as pagos, ( nvl(valfin.valor,0) - ( (nvl(pagos.suma,0)) - (nvl(anulacion.anul,0)) - (nvl(reintegro.valor,0)) ) ) as Saldo,
		acto.descripcion as tipoDoc, resol.resolucion as nro, nvl(anulacion.anul,0) as anul,
		prp.id_cdp,NULL AS FECHA_INICIO,NULL AS FECHA_TERMINACION,cdp.fecha AS FECHA_CDP,NULL AS SUPERVISOR
		from PROYECTOS p
		left join PR_RP_COMPROMISO prc ON p.id=prc.id_cpo $P!{whereObj}
		join OBJETOS_GASTO obg ON prc.id_obj_gasto = obg.id
		join PR_RP_COMIS prp ON prc.id_rp = prp.id
		and prp.fecha_proceso >= to_date($P{fechai},'DD-MM-YYYY')
		and prp.fecha_proceso <= to_date($P{fechaf},'DD-MM-YYYY')
		and prp.vigencia = prc.vigencia
		and prp.id_vigencia = prc.id_vigencia
		join PR_ASIG_PRESUP pap ON prc.id_asign = pap.id

		JOIN PR_RESOL_COMIS resol ON resol.id=prp.no_acto_admin and resol.id_vigencia=prp.id_vigencia and resol.vigencia=prp.vigencia
		JOIN PR_CLASE_ACT_ADMIN acto ON acto.id=prp.id_clase_admin

		JOIN PR_CDP_COMIS cdp ON cdp.id=prp.id_cdp and cdp.id_vigencia=prp.id_vigencia and cdp.ano_fiscal=prp.vigencia
		join INTERCEROS ter ON prp.id_mae_ter = ter.id_mae_ter
		join PR_APROPIACION pa ON pap.id_apropiacion = pa.id
		join PR_CODIF_PRESUP cod ON pa.id_rubro = cod.id_rubro
		join PR_PROG_GEN pgen ON cod.cod_rub1 = pgen.id
		join PR_TIPO_REC re ON pa.id_tipo_rec = re.id

		left join (
		select prp.id, p.id as id_cpo, prc.id_asign,prc.id_obj_gasto,
		case when sum(hist.valor) is null then sum(prc.valor) else ( nvl(hist.valor,0)+nvl(sum(nval.debito),0)-nvl(sum(nval.credito),0) ) end
		as VALOR, prp.id_vigencia, prp.vigencia, prp.id_tercero
		from PROYECTOS p
		left join PR_RP_COMPROMISO prc ON prc.id_cpo = p.id
		and prc.vigencia=$P{vigencia}
		and prc.id_vigencia=$P{id_vigencia}
		join PR_RP_COMIS prp ON prc.id_rp = prp.id
		and prc.id_vigencia = prp.id_vigencia
		and prc.vigencia = prp.vigencia
		and prp.fecha_proceso <= to_date($P{fechaf},'DD-MM-YYYY')
		left join PR_HISTORIAL_RP hist ON prp.id = hist.id_rp
		and hist.id_vigencia = prp.id_vigencia
		and hist.vigencia = prp.vigencia
		and hist.id_asign = prc.id_asign
		and hist.id_obj_gasto = prc.id_obj_gasto
		and hist.id_cpo = prc.id_cpo
		left join
		(
		select novi.fecha, novi.id_rp, novi.id_vigencia, novi.vigencia, novi.id_novedad_rp
		from PR_NOVEDAD_RP novi
		where novi.fecha <= to_date($P{fechaf},'DD-MM-YYYY')
		)nov ON prp.id = nov.id_rp
		and nov.id_vigencia = prp.id_vigencia
		and nov.vigencia = prp.vigencia
		left join PR_NOVEDAD_RP_VAL nval ON nov.id_novedad_rp = nval.id_novedad_rp
		and nval.id_asign = prc.id_asign
		and nval.id_obj_gasto = prc.id_obj_gasto
		group by prp.id, p.id, prc.id_asign, prc.id_obj_gasto, hist.valor,prp.id_vigencia, prp.vigencia, prp.id_tercero
		)valfin ON prc.id_rp = valfin.id
		and obg.id = valfin.id_obj_gasto
		and p.id = valfin.id_cpo
		and prp.id_vigencia = valfin.id_vigencia
		and prp.vigencia = valfin.vigencia
		and prc.id_asign = valfin.id_asign
		and prp.id_tercero = valfin.id_tercero


		left join
		(
		select id_rp, sum(suma) as suma, id_obg, id_cpo, id_asign, vig, idvig
		from(
		select obl.id_rp as ID_RP, sum (tov.valor_obligacion) as suma,
		tov.id_obj_gasto as ID_OBG, tov.id_cpo as ID_CPO,
		tov.id_asign as ID_ASIGN, obl.ano_fiscal as vig,
		obl.id_vigencia as idvig, 'act' as des
		from TS_OBLIGACION obl
		join TS_OBLIGACION_VAL tov ON obl.id_obligacion = tov.id_obligacion
		and obl.secuencia = tov.secuencia
		and obl.ano_fiscal = tov.ano_fiscal
		and obl.id_vigencia = tov.id_vigencia
		where obl.fecha_proceso >= to_date($P{fechai},'DD-MM-YYYY')
		and obl.fecha_proceso <= to_date($P{fechaf},'DD-MM-YYYY') and obl.estado=1
		group by obl.id_rp, tov.id_obj_gasto, tov.id_cpo, tov.id_asign, obl.ano_fiscal, obl.id_vigencia, 'act'

		) group by id_rp, id_obg, id_cpo, id_asign, vig, idvig
		)obligaciones ON prc.id_rp = obligaciones.id_rp
		and pap.id = obligaciones.id_asign
		and prc.id_obj_gasto = obligaciones.id_obg
		and prc.vigencia = obligaciones.vig
		and prc.id_vigencia = obligaciones.idvig

		left join
		(
		select sum(oval.valor_obligacion) suma,
		oval.id_obj_gasto as id_obg, oval.id_cpo as id_cpo,
		oval.id_asign as id_asign, obl.id_rp as id_rp,
		obl.id_vigencia as idvig, obl.ano_fiscal as vig
		from TS_OBLIGACION obl
		join TS_PAGO_OBL pag ON pag.id_obligacion = obl.id_obligacion
		and pag.id_clase_pago is null
		and pag.secuencia = obl.secuencia
		and pag.vigencia = obl.ano_fiscal
		join TS_OBLIGACION_VAL oval ON obl.id_obligacion = oval.id_obligacion
		and oval.secuencia = obl.secuencia
		and oval.ano_fiscal =obl.ano_fiscal
		and oval.id_vigencia =obl.id_vigencia
		join TS_EMISION_PAGO emi ON pag.id_emision_pago = emi.id_emision_pago
		and emi.fecha_proc >=to_date($P{fechai},'DD-MM-YYYY')
		and emi.fecha_proc <=to_date($P{fechaf},'DD-MM-YYYY')
		where obl.ano_fiscal = $P{vigencia}and obl.id_vigencia =$P{id_vigencia}
		group by oval.id_obj_gasto, oval.id_cpo, oval.id_asign, obl.id_rp,obl.id_vigencia, obl.ano_fiscal

		)pagos ON prc.id_rp = pagos.id_rp
		and pap.id = pagos.id_asign
		and prc.id_obj_gasto = pagos.id_obg
		and prc.vigencia = pagos.vig
		and prc.id_vigencia = pagos.idvig
		left join(
		select id_rp, id_asig,id_obj_gasto, id_vigencia, vigencia, sum(reint) as valor
		from(
		select ob.id_obligacion as id_obliga, re.valor as reint, ob.id_asign as id_asig, ob.id_obj_gasto, ob.secuencia, p.id_pago_obl as id_reintegro, p.id_rp, ob.ano_fiscal as vigencia , ob.id_vigencia
		from TS_OBLIGACION_VAL ob
		join TS_PAGO_OBL p ON ob.id_obligacion = p.id_obligacion
		and ob.secuencia = p.secuencia
		and ob.id_vigencia = p.id_vigencia
		and ob.ano_fiscal = p.vigencia
		and p.id_clase_pago is null
		join (
		select r.id_pago_obl, d.id_cpo, d.id_asig, d.id_obj_gasto, sum(d.valor) as valor
		from PR_REINTEGRO r
		join PR_DETA_REIN d ON r.id_reintegro = d.id_reintegro
		where r.fecha_proceso >= to_date($P{fechai},'DD-MM-YYYY')
		and r.fecha_proceso <= to_date($P{fechaf},'DD-MM-YYYY')
		group by r.id_pago_obl, d.id_cpo, d.id_asig, d.id_obj_gasto
		)re ON p.id_pago_obl = re.id_pago_obl
		and ob.id_cpo = re.id_cpo
		and ob.id_asign =re.id_asig
		and ob.id_obj_gasto = re.id_obj_gasto

		union

		select obl.id_obligacion as id_obliga, pdr.valor*(-1) as reint, pdr.id_asig, pdr.id_obj_gasto, obl.secuencia,pr.id_reintegro, obl.id_rp, obl.ano_fiscal as vigencia,obl.id_vigencia
		from TS_OBLIGACION obl
		join TS_PAGO_OBL pag ON obl.id_obligacion = pag.id_obligacion
		and obl.ano_fiscal = pag.vigencia
		and obl.id_vigencia = pag.id_vigencia
		and obl.secuencia = pag.secuencia
		and pag.id_clase_pago IS NULL
		join PR_REINTEGRO pr ON pag.id_pago_obl = pr.id_pago_obl
		join PR_DETA_REIN pdr ON pr.id_reintegro = pdr.id_reintegro
		join TS_ANU_MOV_BANC anul ON anul.id_mov_banc = pr.id_mov_ban
		and anul.fecha_anul >= to_date($P{fechai},'DD-MM-YYYY')
		and anul.fecha_anul <= to_date($P{fechaf},'DD-MM-YYYY')
		where obl.ano_fiscal = $P{vigencia}

		union

		select obl.id_obligacion as id_obliga, sum(pdr.valor)*(-1) as reint, pdr.id_asig, pdr.id_obj_gasto, obl.secuencia, pr.id_reintegro, obl.id_rp, obl.ano_fiscal as vigencia, obl.id_vigencia
		from TS_OBLIGACION obl
		join TS_PAGO_OBL pag ON obl.id_obligacion = pag.id_obligacion
		and obl.ano_fiscal = pag.vigencia
		and obl.id_vigencia = pag.id_vigencia
		and obl.secuencia = pag.secuencia
		and pag.id_clase_pago IS NULL
		join PR_REINTEGRO pr ON pag.id_pago_obl = pr.id_pago_obl
		join PR_DETA_REIN pdr ON pr.id_reintegro = pdr.id_reintegro
		join TS_ANUL_RC anul ON anul.id_rc = pr.id_rc
		and anul.fecha_anul >= to_date($P{fechai},'DD-MM-YYYY')
		and anul.fecha_anul <= to_date($P{fechaf},'DD-MM-YYYY')
		where obl.ano_fiscal = $P{vigencia}
		group by obl.id_obligacion, pdr.id_asig, pdr.id_obj_gasto, obl.secuencia,pr.id_reintegro, obl.id_rp, obl.ano_fiscal, obl.id_vigencia
		) group by id_rp, id_asig, id_obj_gasto, id_vigencia, vigencia
		)reintegro ON prc.id_rp = reintegro.id_rp
		and pap.id = reintegro.id_asig
		and prc.id_obj_gasto = reintegro.id_obj_gasto
		and prc.vigencia = reintegro.vigencia
		and prc.id_vigencia = reintegro.id_vigencia
		left join(
		select sum(tov.valor_obligacion) anul, tov.id_asign as id_asign, tov.ano_fiscal as vig, tov.id_vigencia as idvig, obl.id_rp as id_rp, tov.id_obj_gasto as id_obg
		from TS_OBLIGACION obl
		join TS_PAGO_OBL pag ON obl.id_obligacion = pag.id_obligacion
		and obl.ano_fiscal = pag.vigencia
		and obl.id_vigencia = pag.id_vigencia
		and obl.secuencia = pag.secuencia
		and pag.id_clase_pago IS NULL
		join TS_OBLIGACION_VAL tov ON obl.id_obligacion = tov.id_obligacion
		and obl.ano_fiscal = tov.ano_fiscal
		and obl.id_vigencia = tov.id_vigencia
		and obl.secuencia = tov.secuencia
		join TS_ANUL_PAGOS anul ON pag.id_pago_obl = anul.id_pago_obl
		and anul.fecha_anul >= to_date($P{fechai},'DD-MM-YYYY')
		and anul.fecha_anul <= to_date($P{fechaf},'DD-MM-YYYY')
		where obl.ano_fiscal = $P{vigencia} and obl.id_vigencia=$P{id_vigencia}
		group by tov.id_asign, tov.ano_fiscal, tov.id_vigencia, obl.id_rp, tov.id_obj_gasto
		)anulacion ON prc.id_rp = anulacion.id_rp
		and pap.id = anulacion.id_asign
		and prc.id_obj_gasto = anulacion.id_obg
		and prc.vigencia = anulacion.vig
		and prc.id_vigencia = anulacion.idvig

		where prc.vigencia=$P{vigencia}and prc.id_vigencia=$P{id_vigencia} and prc.valor IS NOT NULL $P!{whereOpciones}


		)$P!{whereUltimo}]]>
	</queryString>
	<field name="CODIGO" class="java.lang.String"/>
	<field name="ID_RP" class="java.math.BigDecimal"/>
	<field name="OBJ" class="java.lang.String"/>
	<field name="FECHA" class="java.sql.Timestamp"/>
	<field name="DOCUMENTO" class="java.lang.String"/>
	<field name="TERCERO" class="java.lang.String"/>
	<field name="VALOR" class="java.math.BigDecimal"/>
	<field name="VALOB" class="java.math.BigDecimal"/>
	<field name="VALREIN" class="java.math.BigDecimal"/>
	<field name="PAGOS" class="java.math.BigDecimal"/>
	<field name="SALDO" class="java.math.BigDecimal"/>
	<field name="TIPODOC" class="java.lang.String"/>
	<field name="NRO" class="java.lang.String"/>
	<field name="ANUL" class="java.math.BigDecimal"/>
	<field name="ID_CDP" class="java.math.BigDecimal"/>
	<field name="FECHA_INICIO" class="java.sql.Timestamp"/>
	<field name="FECHA_TERMINACION" class="java.sql.Timestamp"/>
	<field name="FECHA_CDP" class="java.sql.Timestamp"/>
	<field name="SUPERVISOR" class="java.lang.String"/>
	<variable name="VALOR_1" class="java.math.BigDecimal" resetType="Group" resetGroup="CPO" calculation="Sum">
		<variableExpression><![CDATA[$F{VALOR}]]></variableExpression>
	</variable>
	<variable name="VALOB_1" class="java.math.BigDecimal" resetType="Group" resetGroup="CPO" calculation="Sum">
		<variableExpression><![CDATA[$F{VALOB}]]></variableExpression>
	</variable>
	<variable name="PAGOS_1" class="java.math.BigDecimal" resetType="Group" resetGroup="CPO" calculation="Sum">
		<variableExpression><![CDATA[$F{PAGOS}]]></variableExpression>
	</variable>
	<variable name="SALDO_1" class="java.math.BigDecimal" resetType="Group" resetGroup="CPO" calculation="Sum">
		<variableExpression><![CDATA[$F{SALDO}]]></variableExpression>
	</variable>
	<variable name="VALOR_2" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[$F{VALOR}]]></variableExpression>
	</variable>
	<variable name="VALOB_2" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[$F{VALOB}]]></variableExpression>
	</variable>
	<variable name="PAGOS_2" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[$F{PAGOS}]]></variableExpression>
	</variable>
	<variable name="SALDO_2" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[$F{SALDO}]]></variableExpression>
	</variable>
	<group name="CPO">
		<groupExpression><![CDATA[$F{CODIGO}]]></groupExpression>
		<groupFooter>
			<band height="20">
				<textField>
					<reportElement x="0" y="0" width="1400" height="20"/>
					<box topPadding="2" leftPadding="4" bottomPadding="2" rightPadding="2">
						<pen lineWidth="0.75"/>
						<topPen lineWidth="0.75"/>
						<leftPen lineWidth="0.75"/>
						<bottomPen lineWidth="0.75"/>
						<rightPen lineWidth="0.75"/>
					</box>
					<textElement>
						<font isBold="true"/>
					</textElement>
					<textFieldExpression class="java.lang.String"><![CDATA["Subtotal Proyecto "+$F{CODIGO}]]></textFieldExpression>
				</textField>
				<textField pattern="¤ #,##0.00">
					<reportElement x="1400" y="0" width="126" height="20"/>
					<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="4">
						<pen lineWidth="0.75"/>
						<topPen lineWidth="0.75"/>
						<leftPen lineWidth="0.75"/>
						<bottomPen lineWidth="0.75"/>
						<rightPen lineWidth="0.75"/>
					</box>
					<textElement textAlignment="Right"/>
					<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{VALOR_1}]]></textFieldExpression>
				</textField>
				<textField pattern="¤ #,##0.00">
					<reportElement x="1526" y="0" width="126" height="20"/>
					<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="4">
						<pen lineWidth="0.75"/>
						<topPen lineWidth="0.75"/>
						<leftPen lineWidth="0.75"/>
						<bottomPen lineWidth="0.75"/>
						<rightPen lineWidth="0.75"/>
					</box>
					<textElement textAlignment="Right"/>
					<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{VALOB_1}]]></textFieldExpression>
				</textField>
				<textField pattern="¤ #,##0.00">
					<reportElement x="1652" y="0" width="126" height="20"/>
					<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="4">
						<pen lineWidth="0.75"/>
						<topPen lineWidth="0.75"/>
						<leftPen lineWidth="0.75"/>
						<bottomPen lineWidth="0.75"/>
						<rightPen lineWidth="0.75"/>
					</box>
					<textElement textAlignment="Right"/>
					<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{PAGOS_1}]]></textFieldExpression>
				</textField>
				<textField pattern="¤ #,##0.00">
					<reportElement x="1778" y="0" width="126" height="20"/>
					<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="4">
						<pen lineWidth="0.75"/>
						<topPen lineWidth="0.75"/>
						<leftPen lineWidth="0.75"/>
						<bottomPen lineWidth="0.75"/>
						<rightPen lineWidth="0.75"/>
					</box>
					<textElement textAlignment="Right"/>
					<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{SALDO_1}]]></textFieldExpression>
				</textField>
			</band>
		</groupFooter>
	</group>
	<background>
		<band splitType="Stretch"/>
	</background>
	<title>
		<band height="60" splitType="Stretch">
			<staticText>
				<reportElement mode="Opaque" x="1745" y="16" width="151" height="12" forecolor="#000000" backcolor="#FFFFFF"/>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Fecha de Impresión:]]></text>
			</staticText>
			<textField pattern="dd-MMM-yyyy   hh:mm aaa">
				<reportElement x="1746" y="28" width="150" height="12"/>
				<box rightPadding="3"/>
				<textElement textAlignment="Right" verticalAlignment="Middle">
					<font size="8"/>
				</textElement>
				<textFieldExpression class="java.util.Date"><![CDATA[new java.util.Date()]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement x="728" y="0" width="460" height="20"/>
				<textElement textAlignment="Center" verticalAlignment="Middle" markup="none">
					<font fontName="SansSerif" size="12" isBold="true"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA["Informe General de Compromisos "+$P{mescorte}+" de "+$P{vigencia}]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement x="728" y="20" width="460" height="20"/>
				<textElement textAlignment="Center" verticalAlignment="Middle" markup="none">
					<font fontName="SansSerif" size="12" isBold="true"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA["Presupuesto de Gastos"]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement x="728" y="40" width="460" height="20"/>
				<textElement textAlignment="Center" verticalAlignment="Middle" markup="none">
					<font fontName="SansSerif" size="12" isBold="true"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA["De "+$P{fechainicial}+" a "+$P{fechafinal}]]></textFieldExpression>
			</textField>
			<image>
				<reportElement x="0" y="0" width="140" height="60"/>
				<imageExpression class="java.lang.String"><![CDATA["repo:ANMLogoEmpresa003.png"]]></imageExpression>
			</image>
		</band>
	</title>
	<pageHeader>
		<band height="20" splitType="Stretch"/>
	</pageHeader>
	<columnHeader>
		<band height="26" splitType="Stretch">
			<staticText>
				<reportElement mode="Opaque" x="0" y="0" width="73" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[CPO]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="73" y="0" width="67" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[CDP]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="140" y="0" width="100" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[FECHA CDP]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="240" y="0" width="68" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[RP]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="308" y="0" width="94" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[FECHA RP]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="402" y="0" width="129" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[TIPO DOCUMENTO]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="531" y="0" width="95" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[No. DOCUMENTO]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="626" y="0" width="93" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[FECHA INICIO]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="719" y="0" width="94" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[FECHA FINALIZACION]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="813" y="0" width="150" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[SUPERVISOR]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="963" y="0" width="103" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[NUM. DOC.]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="1066" y="0" width="220" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[BENEFICIARIO]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="1286" y="0" width="114" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[OBJETO GASTO]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="1400" y="0" width="126" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[VALOR COMPROMISO]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="1526" y="0" width="126" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[VALOR OBLIGACIONES]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="1652" y="0" width="126" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[VALOR PAGOS]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="1778" y="0" width="126" height="26" forecolor="#000000" backcolor="#64B0F7"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[SALDO]]></text>
			</staticText>
		</band>
	</columnHeader>
	<detail>
		<band height="16" splitType="Stretch">
			<textField>
				<reportElement stretchType="RelativeToTallestObject" x="0" y="0" width="73" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement/>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{CODIGO}]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement stretchType="RelativeToTallestObject" x="73" y="0" width="67" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement/>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{ID_CDP}]]></textFieldExpression>
			</textField>
			<textField pattern="dd MMMMM yyyy">
				<reportElement stretchType="RelativeToTallestObject" x="140" y="0" width="100" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center"/>
				<textFieldExpression class="java.util.Date"><![CDATA[$F{FECHA_CDP}]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement stretchType="RelativeToTallestObject" x="240" y="0" width="68" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement/>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{ID_RP}]]></textFieldExpression>
			</textField>
			<textField pattern="dd-MM-yyyy">
				<reportElement stretchType="RelativeToTallestObject" x="308" y="0" width="94" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center"/>
				<textFieldExpression class="java.util.Date"><![CDATA[$F{FECHA}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" pattern="" isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="402" y="0" width="129" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Justified"/>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{TIPODOC}]]></textFieldExpression>
			</textField>
			<textField isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="531" y="0" width="95" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement/>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{NRO}]]></textFieldExpression>
			</textField>
			<textField pattern="dd MMMMM yyyy" isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="626" y="0" width="93" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center"/>
				<textFieldExpression class="java.util.Date"><![CDATA[$F{FECHA_INICIO}]]></textFieldExpression>
			</textField>
			<textField pattern="dd MMMMM yyyy" isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="719" y="0" width="94" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center"/>
				<textFieldExpression class="java.util.Date"><![CDATA[$F{FECHA_TERMINACION}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="813" y="0" width="150" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Justified"/>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{SUPERVISOR}]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement stretchType="RelativeToTallestObject" x="963" y="0" width="103" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center"/>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{DOCUMENTO}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true">
				<reportElement stretchType="RelativeToTallestObject" x="1066" y="0" width="220" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Justified"/>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{TERCERO}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true">
				<reportElement stretchType="RelativeToTallestObject" x="1286" y="0" width="114" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement/>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{OBJ}]]></textFieldExpression>
			</textField>
			<textField pattern="¤ #,##0.00">
				<reportElement stretchType="RelativeToTallestObject" x="1400" y="0" width="126" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="4">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right"/>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{VALOR}]]></textFieldExpression>
			</textField>
			<textField pattern="¤ #,##0.00">
				<reportElement stretchType="RelativeToTallestObject" x="1526" y="0" width="126" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="4">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right"/>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{VALOB}]]></textFieldExpression>
			</textField>
			<textField pattern="¤ #,##0.00">
				<reportElement stretchType="RelativeToTallestObject" x="1652" y="0" width="126" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="4">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right"/>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{PAGOS}]]></textFieldExpression>
			</textField>
			<textField pattern="¤ #,##0.00" isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="1778" y="0" width="126" height="16"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="4">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right"/>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{SALDO}]]></textFieldExpression>
			</textField>
		</band>
	</detail>
	<columnFooter>
		<band height="24" splitType="Stretch"/>
	</columnFooter>
	<pageFooter>
		<band height="24" splitType="Stretch">
			<textField>
				<reportElement mode="Opaque" x="877" y="12" width="89" height="12" forecolor="#575757" backcolor="#FFFFFF"/>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="6" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA["Página "+$V{PAGE_NUMBER}+" de "]]></textFieldExpression>
			</textField>
			<textField evaluationTime="Report" pattern="" isBlankWhenNull="false">
				<reportElement mode="Opaque" x="967" y="12" width="60" height="12" forecolor="#575757" backcolor="#FFFFFF"/>
				<textElement verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="6" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$V{PAGE_NUMBER}]]></textFieldExpression>
			</textField>
			<staticText>
				<reportElement mode="Opaque" x="877" y="0" width="150" height="12" forecolor="#575757"/>
				<textElement textAlignment="Center" verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<text><![CDATA[Websafi - Presupuesto]]></text>
			</staticText>
		</band>
	</pageFooter>
	<summary>
		<band height="21" splitType="Stretch">
			<textField>
				<reportElement x="0" y="0" width="1400" height="20"/>
				<box topPadding="2" leftPadding="4" bottomPadding="2" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement>
					<font isBold="true"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA["TOTAL "+$V{CPO_COUNT}+" Registro(s)"]]></textFieldExpression>
			</textField>
			<textField pattern="¤ #,##0.00">
				<reportElement x="1400" y="0" width="126" height="20"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="4">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right">
					<font isBold="true"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{VALOR_2}]]></textFieldExpression>
			</textField>
			<textField pattern="¤ #,##0.00">
				<reportElement x="1526" y="0" width="126" height="20"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="4">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right">
					<font isBold="true"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{VALOB_2}]]></textFieldExpression>
			</textField>
			<textField pattern="¤ #,##0.00">
				<reportElement x="1652" y="0" width="126" height="20"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="4">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right">
					<font isBold="true"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{PAGOS_2}]]></textFieldExpression>
			</textField>
			<textField pattern="¤ #,##0.00">
				<reportElement x="1778" y="0" width="126" height="20"/>
				<box topPadding="2" leftPadding="2" bottomPadding="2" rightPadding="4">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right">
					<font isBold="true"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{SALDO_2}]]></textFieldExpression>
			</textField>
		</band>
	</summary>
	<noData>
		<band height="20">
			<staticText>
				<reportElement x="567" y="0" width="752" height="20"/>
				<textElement textAlignment="Center" verticalAlignment="Middle">
					<font isBold="true"/>
				</textElement>
				<text><![CDATA[No hay objetos a mostrar.]]></text>
			</staticText>
		</band>
	</noData>
</jasperReport>
