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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
lucianomagalhae
New Member

Sum of values ​​for the next month

I have a table with the following columns

lucianomagalhae_1-1711313362707.png

I need to put a wave matrix visual for each product, the value in the January column will be the value of the first date in February, in February it will be the value of the first date in March. In other words, the value in each month will always be the value of the first date of the following month. How could I do?

lucianomagalhae_2-1711313509048.png

 

1 ACCEPTED SOLUTION
v-nuoc-msft
Community Support
Community Support

Hi @lucianomagalhae 

 

Based on your question, here is my proposed method.


However, since your date column is broken down to days. Therefore the results may be somewhat different from your expectations.

 

Here's some dummy data

 

"Table"

vnuocmsft_0-1711332887255.png

 

Create a measure.

 

Measure = var _month = MONTH(SELECTEDVALUE('Table'[Date]))
RETURN
CALCULATE(MIN('Table'[Value]),
FILTER(
    ALL('Table'), 
    MONTH('Table'[Date]) = _month + 1
    &&
    'Table'[Product] = MAX('Table'[Product])
    
    )
)


Create a matrix.

vnuocmsft_2-1711333207868.png

 

Here is the result.

vnuocmsft_1-1711333025614.png

Regards,

Nono Chen

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

1 REPLY 1
v-nuoc-msft
Community Support
Community Support

Hi @lucianomagalhae 

 

Based on your question, here is my proposed method.


However, since your date column is broken down to days. Therefore the results may be somewhat different from your expectations.

 

Here's some dummy data

 

"Table"

vnuocmsft_0-1711332887255.png

 

Create a measure.

 

Measure = var _month = MONTH(SELECTEDVALUE('Table'[Date]))
RETURN
CALCULATE(MIN('Table'[Value]),
FILTER(
    ALL('Table'), 
    MONTH('Table'[Date]) = _month + 1
    &&
    'Table'[Product] = MAX('Table'[Product])
    
    )
)


Create a matrix.

vnuocmsft_2-1711333207868.png

 

Here is the result.

vnuocmsft_1-1711333025614.png

Regards,

Nono Chen

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

 

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.