Advertisement
Guest User

Untitled

a guest
Oct 14th, 2019
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MySQL 0.49 KB | None | 0 0
  1. select
  2.     ordini.id as id_ordine,
  3.     items.id as id_prodotto,
  4.     items.prodotto,
  5.     items.pezzi,
  6.     items.qta,
  7.     items.netto_produttore,
  8.     items.imponibile,
  9.     ordini.de_cap
  10. from
  11.     ordini_2014 as ordini
  12. inner join
  13.     ordini_items_2014 as items
  14. on
  15.     ordini.middi = items.middi
  16. inner join
  17.     comuni as c
  18. on
  19.     ordini.de_cap = c.cap
  20. where
  21.     ordini.stato in ('CONSEGNATO', 'RIMBORSATO', 'SPEDITO')
  22. and
  23.     ordini.data_ordine between '2019-09-03' and '2019-10-03'
  24. and
  25.     ordini.agente_id = 87061
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement