home *** CD-ROM | disk | FTP | other *** search
- select f.typ,max(s.nazwa),max(s.kod),s.nr_tow,sum(s.ilosc),sum(s.korekta),
- sum(s.wartosc), max(s.st_vat)
- from faktury f,
- specyf s where
- (f.trns_nr=s.trns_nr) and (f.data between :od_daty and :do_daty)
- and (f.nr_magazynu=:nr_magazynu) and (s.ilosc<>0)
- group by s.nr_tow,f.typ
- order by s.nazwa;