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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Anonymous
Not applicable

Sum with filter selected

Hi all.

 

I have 3 cards wiht values.

 

1 - Values of month selected

2 - Values all Month

3 - I have to calculate the values until month selected.

 

1 and 2 are ok missing 3

 

ty.

1 ACCEPTED SOLUTION

@Anonymous,

Create measure using DAX below.

Measure = CALCULATE(SUM(Planilha1[values]),FILTER(ALL(Planilha1),Planilha1[month]<MAX(Planilha1[month])))

1.JPG

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

5 REPLIES 5
v-yuezhe-msft
Microsoft Employee
Microsoft Employee

@Anonymous,

Could you please share sample data of your table and post expected result in table format?

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Look this imagem

val.PNG

 

 

https://drive.google.com/file/d/11lCWE0-K-c7J9lAKC9KFnnlq8GAQyhWZ/view?usp=sharing

 

link for download this example

 

Ty

@Anonymous,

Create measure using DAX below.

Measure = CALCULATE(SUM(Planilha1[values]),FILTER(ALL(Planilha1),Planilha1[month]<MAX(Planilha1[month])))

1.JPG

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Anonymous
Not applicable

I use this

 

AllMonths = CALCULATE(SUM(CONTABIL[VALOR])+SUM(CUSTO[VALOR_OBJ]); ALL(MES[Mes]); CUSTO[Flag] = TRUE())+0

SelectMonth = CALCULATE(SUM(CONTABIL[VALOR])+SUM(CUSTO[VALOR_OBJ]); ALLEXCEPT(MES[Mes]); CUSTO[Flag] = TRUE())+0

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors