Motores del proyecto Forseti











 |
|
| RESUMEN DE VENTAS POR NUMERO Y ENTIDAD |
Documentación del reporte "RESUMEN DE VENTAS POR NUMERO Y ENTIDAD"
|
| Estructura del reporte |
| Datos del Cabecero |
| Clave |
Descripción |
Base |
Módulo |
|
| 607 |
RESUMEN DE VENTAS POR NUMERO Y ENTIDAD |
VENTAS |
FACTURAS |
|
|
| Filtro |
| Objeto |
Descripción |
Tipo de dato |
|
| Numero |
INDICA EL RANGO DE LA NUMERACION PARA LAS FACTURAS |
INT |
 |
| Entidad |
ENTIDAD DE VENTA |
BYTE |
|
|
| Datos del Nivel 1 |
| Nombre de Columna |
Tipo de Dato |
| numero |
INT |
| fecha |
TIME |
| cli |
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 Cli, 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_VENTAS_FACTURAS_CAB fc inner join TBL_CLIENT_CLIENT cl ON cl.ID_Tipo = 'CL' and cl.ID_Clave = fc.ID_CliPro
where fc.Numero between [Numero] and [Numero2] 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_VENTAS_FACTURAS_CAB where Status <> 'C' and Numero between [Numero] and [Numero2] 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 |
|
|