Difference in Sales using LOD's vs Table Calculations

A session with Erica Hughes on advanced Table and Level of Detail Calculations showed us how to build the same chart using two different techniques. Before learning these, remember to read my blog on the difference between Table Calculations and LOD's. But for a quick refresher, table calculations involve computing calculations within the view with aggregated fields. LOD's involve controlling the level granularity and computing calculations at the data source level.

Difference in Sales Chart

Here is our Difference in Sales Chart, this can be computed in two ways, LOD's and Table Calculations.

Table Calculations

  1. Set up a table of Sales for each Sub Category
Step 1

2.  Create a calculated field and use WINDOW_SUM function from the Table Calculation drop down option, this will give the sales for copiers for every row.

Step 2 outcome

3. Create a calculated field which computes the difference in sales of other sub categories from copiers

Step 3
Step 3 outcome

Now that we have this in table form, we can create our bar chart. With sub category on rows and our sales difference calculated field on columns, you now have the bar chart.

LOD's

  1. After setting up a table of sales and sub category, create a calculated field to give the sales for copiers in every row.
Step 1 which gives Step 2 Table Calc outcome

2.  Create a calculated field which computes the difference of sales of every other sub category from sales of copiers, this creates the table needed for our bar chart.

*Important note: {SUM ...} can be considered the LOD version of the WINDOW_SUM function

Now we can create our bar chart by dragging sub category into rows and our sales difference calculated field onto columns. The important distinction between the two calculations is the syntax which LOD's require.

Author:
Reshika Chilakapati
Powered by The Information Lab
1st Floor, 25 Watling Street, London, EC4M 9BR
Subscribe
to our Newsletter
Get the lastest news about The Data School and application tips
Subscribe now
© 2025 The Information Lab