Advertisement
Fhernd

ResumenVentasDiarias.sql

Jul 10th, 2016
852
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
T-SQL 0.26 KB | None | 0 0
  1. SELECT OrderDate AS 'Fecha Orden',
  2.     SUM(TotalDue) AS 'Total por día'
  3.     FROM Sales.SalesOrderHeader
  4.     WHERE OrderDate >= '2005-07-01T00:00:00'
  5.         AND OrderDate < '2005-08-01T00:00:00'
  6.     GROUP BY OrderDate
  7.     HAVING SUM(TotalDue) >= 15000;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement