![Antiguo](http://static.forosdelweb.com/fdwtheme/images/statusicon/post_old.gif)
24/10/2008, 10:07
|
![Avatar de masterojitos](http://static.forosdelweb.com/customavatars/avatar250746_1.gif) | | | Fecha de Ingreso: julio-2008 Ubicación: Lima Callao Chucuito
Mensajes: 1.931
Antigüedad: 16 años, 6 meses Puntos: 105 | |
Respuesta: Php/mssql Cita:
Iniciado por masterojitos y prueba asi: select *
from clientes a
where exists ( select sum(importe)
from faclin b
inner join faclinprod c on b.faclincod = c.faclincod where c.fecha between '01/01/2007' and '31/12/2008' and b.cliente = a.cliente and b.grupcli = a.grupcli
having sum(importe)>0 )
and a.grupcli = 'AGEN'
__________________ Atte. MasterOjitos :ojotes:
Todo sobre Programación Web
Las ultimas tendencias en Efectos y Recursos Web: MasterOjitos Blog |