Loading

How To Calculate The Value Of The Same Day Of The Previous Month

Publiceringsdatum: Mar 27, 2026
Uppgift

How to calculate the value of the same day of the previous month.

Steg

Using a Table Calculation and the LOOKUP function, you can calculate the value on the same day of the previous month.
 
  1. Connect to Sample - Superstore data source.
  2. Right click [Order Date] and drag and drop it to the Columns shelf and select [MONTH(Order Date)].
  3. Right click [Order Date] and drag and drop it to the Columns shelf and select [DAY(Order Date)].
  4. Double click [Sales] measure and to add it to the view.
  5. Create a new Calculation field named "Sales(Previous Month)" with the following calculations:
         LOOKUP(SUM([Sales]),-1)
  6. Double click [Sales(Previous Month)] and to add it to the view.
  7. Right click [Sales(Previous Month)] in Measure Values, and select [Edit Table Calculation]. Set the following values.
         Compute Using : Specific Dimensions
         Check only Month of Order Date.
         Sort order : Specific Dimensions.

Knowledge-artikelnummer

001460235

 
Laddar
Salesforce Help | Article