cancel
Showing results for 
Search instead for 
Did you mean: 

How to get sum (sales) till last week?

BharatKankate
8 - Cloud Apps
8 - Cloud Apps

I have one scenario,

where I have to calculate sum(sale) start to till date---which I am able to get.

but I also want sum(sales) from start to last week (Means start to today -7 days), That I am unable to get.

Highly appreciate response on this.

 

1 ACCEPTED SOLUTION

harikm007
13 - Data Warehouse
13 - Data Warehouse

Hi @BharatKankate ,

Try the below approach:

Add a widget filter to the date field. In the filter popup, set 'Day' as level and add the below custom jaql (assuming the start date is within the last 99999999 days)

{
  "last": {
    "count": 99999999,
    "offset": 7
  }
}

 

harikm007_0-1741157678878.png

-Hari

 

View solution in original post

4 REPLIES 4

DRay
Community Team Leader
Community Team Leader

Hi @BharatKankate,

Thank you for reaching out. I want to make sure I understand the ask here. Are you wanted a total, but exclude the previous 7 days of data, or do you want the total as of the end of the previous week?

David Raynor (DRay)

I wanted a total, but exclude the previous 7 days of data.

harikm007
13 - Data Warehouse
13 - Data Warehouse

Hi @BharatKankate ,

Try the below approach:

Add a widget filter to the date field. In the filter popup, set 'Day' as level and add the below custom jaql (assuming the start date is within the last 99999999 days)

{
  "last": {
    "count": 99999999,
    "offset": 7
  }
}

 

harikm007_0-1741157678878.png

-Hari

 

BharatKankate
8 - Cloud Apps
8 - Cloud Apps

Thanks that works