3 Replies Latest reply: Oct 26, 2018 2:09 AM by fredrik olsson RSS

    Categorize pivot table

    fredrik olsson

      Hi,

       

      I have a SQL table with sales data that I want to "categorize" in a pivot table.

       

      InvoiceLines:

      SKU
      PriceCostUnitsDate
      123120902
      12498451
      12575701

       

      I want to categorize my pivot table to look like this:

      JanFebMar
      Salessum(Price*Units)sum(Price*Units)sum(Price*Units)
      Costsum(Cost*Units)sum(Cost*Units)sum(Cost*Units)
      Profitsum((Price-Cost)*Units)sum((Price-Cost)*Units)sum((Price-Cost)*Units)

       

      How do I create categories like in the left column? Any help are appreciated.