
18/08/2006, 16:59
|
| | Fecha de Ingreso: agosto-2006
Mensajes: 4
Antigüedad: 18 años, 8 meses Puntos: 0 | |
gracias la verdad es que ha sido facil no se por que se me complico tanto
select distinc NDBYCRCL.cliente_k , facturas.parte , max(NDBYCRCL.facfch) , facturas.Factura ,FACTURAS.dfacantenv, FACTURAS.dfaprecio ;
from NDBYCRCL, facturas , cliente ;
where NDBYCRCL.Factura = facturas.Factura and clientes.cliente_k = NDBYCRCL.cliente_k and (NDBYCRCL.facfch >= GETDATE() - 90) ;
order by NDBYCRCL.cliente_k, facturas.parte , NDBYCRCL.facfch;
group by NDBYCRCL.cliente_k, facturas.parte |