Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
djwbaker
Frequent Visitor

cumulative sum current month but orders placed in previous mths

Hi

doing a current month sales report, showing a simple area graph with a cumulative total 
issue is there are orders placed prior to the current month
data table is date order placed, plant and value linked to a calendar table using the date field

cumulative with all dates in it works but i only want current mth dates on the graph
if the graph has only current mth starts from 0, and dismisses all the advance orders placed for current mth.

any thoughts?

CUMULATIVE TOTAL OPEN ORDERS =
CALCULATE(
SUM('DAILY_SALES_V1 0'[incoming orders valu]),
FILTER(
ALLselected('DAILY_SALES_V1 0'),
'DAILY_SALES_V1 0'[Calendar day.Calendar day Level 01] <= MAX('DAILY_SALES_V1 0'[Calendar day.Calendar day Level 01])
)
)




2 REPLIES 2
amitchandak
Super User
Super User

@djwbaker , Not very clear to me. It is starting with 0 and you do not want that? all can do that

 

CUMULATIVE TOTAL OPEN ORDERS =
CALCULATE(
SUM('DAILY_SALES_V1 0'[incoming orders valu]),
FILTER(
All ('DAILY_SALES_V1 0'),
'DAILY_SALES_V1 0'[Calendar day.Calendar day Level 01] <= MAX('DAILY_SALES_V1 0'[Calendar day.Calendar day Level 01])
)
)

 

It is not starting with 0 and you want that?

Can you share sample data and sample output in a table format? Or a sample pbix after removing sensitive data.

Hi
we are reciving a lot of orders in advance of the 1st so we should start the month with a lot of sales (my calendar is only current mth, and blank indicates orders placed before current month with a due date of this month)

djwbaker_0-1611147517805.png

if i restrict graph to just 01/01 to 31/01 the pre orders are lost
in excel i can just do sumif < [date] 

djwbaker_1-1611147653470.png

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors