Motores del proyecto Forseti











 |
|
| RESUMEN DE COMPRAS POR MES Y ENTIDAD |
Documentación del reporte "RESUMEN DE COMPRAS POR MES Y ENTIDAD"
|
| Estructura del reporte |
| Datos del Cabecero |
| Clave |
Descripción |
Base |
Módulo |
|
| 300 |
RESUMEN DE COMPRAS POR MES Y ENTIDAD |
COMRAS |
COMPRAS |
|
|
| Filtro |
| Objeto |
Descripción |
Tipo de dato |
|
| Mes |
MES DEL PERIODO |
BYTE |
|
| Ano |
ANO DEL PERIODO |
INT |
|
| Entidad |
ENTIDAD DE COMPRA |
INT |
|
|
| Datos del Nivel 1 |
| Nombre de Columna |
Tipo de Dato |
| numero |
INT |
| fecha |
TIME |
| pro |
INT |
| nombre |
STRING |
| sts |
STRING |
| importe |
MONEY |
| descuento |
MONEY |
| subtotal |
MONEY |
| iva |
MONEY |
| total |
MONEY |
| Código fuente |
|
select fc.Numero, fc.Fecha,
fc.ID_CliPro as Pro, cl.Nombre, case when fc.Status = 'E' then '' else fc.Status end as STS,
round(fc.Importe * fc.TC,2) as Importe, round(fc.Descuento * fc.TC,2) as Descuento, round(fc.SubTotal * fc.TC,2) as SubTotal, round(fc.IVA * fc.TC,2) as IVA,
round(fc.Total * fc.TC,2) as Total
from TBL_COMPRAS_FACTURAS_CAB fc inner join TBL_PROVEE_PROVEE cl ON
cl.ID_Tipo = 'PR' and cl.ID_Clave = fc.ID_CliPro
where date_part('Month',fc.Fecha) = [Mes] and date_part('Year',fc.Fecha) = [Ano] and fc.ID_Entidad = [Entidad]
order by fc.Numero asc, fc.Fecha asc
|
|
|
| totales |
STRING |
| importe |
MONEY |
| descuento |
MONEY |
| subtotal |
MONEY |
| iva |
MONEY |
| total |
MONEY |
| Código fuente |
|
select 'TOTALES:' as Totales,
coalesce(sum(round(Importe * TC,2)),0) as Importe,
coalesce(sum(round(Descuento * TC,2)),0) as Descuento,
coalesce(sum(round(SubTotal * TC,2)),0) as SubTotal,
coalesce(sum(round(IVA * TC,2)),0) as IVA,
coalesce(sum(round(Total * TC,2)),0) as Total
from TBL_COMPRAS_FACTURAS_CAB where Status <> 'C' and date_part('Month',Fecha) = [Mes] and date_part('Year',Fecha) = [Ano] and ID_Entidad = [Entidad]
|
|
|
|
| |
| Páginas relacionadas con este tema |
Carga de reportes y gráficas Interfaz de la carga de reportes y gráficas en el CEF y SAF |
|
|