Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- SELECT BusinessEntityID,
- GETDATE() QuotaDate,
- SalesQuota
- FROM Sales.SalesPerson
- WHERE salesQuota > 0
- UNION ALL
- SELECT BusinessEntityID,
- QuotaDate,
- SalesQuota
- FROM Sales.SalesPersonQuotaHistory
- WHERE SalesQuota > 0
- ORDER BY BusinessEntityID DESC,
- SalesQuota DESC
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement