Deals Of The Week - hours only!Up to 80% off on all courses and bundles.-Close
Introduction
Reports with revenue in categories
Revenue in time periods for selected categories
Summary

Instruction

Excellent! Let's try a similar exercise.

Exercise

Compare the category revenues for orders placed in December 2016 and December 2017. Show the following columns: CategoryName, December2016, and December2017.

Stuck? Here's a hint!

Use the following code to find orders placed in December 2016:

SUM(CASE
  WHEN OrderDate >= '20161201' AND OrderDate < '20170101'
    THEN OI.Amount
  ELSE 0.0
END) AS December2016