Guest User

Untitled

a guest
Feb 23rd, 2018
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.31 KB | None | 0 0
  1. SELECT
  2. SUM(vlr_fat_cli) "Total",
  3. nom_cad_cli "Nome"
  4. FROM
  5. cadastro_cliente
  6. WHERE
  7. --Seleciona as faturas em aberto
  8. cod_fat_cli = 'AB'
  9. --Seleciona as faturas vencidas entre 60 e 120 dias
  10. AND venc_fat_cli BETWEEN trunc(sysdate -120) AND trunc(sysdate - 60)
  11. group by
  12. nom_cad_cli
  13. order by
  14. 1 desc
Add Comment
Please, Sign In to add comment