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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
dcrios
Frequent Visitor

Previous Month with problems

Hello everybody,

 

I faced many times people trying to bring values from the previous month. But in my case, I was trying to bring de last date from previous month, like the formula in this link

https://community.powerbi.com/t5/Desktop/Last-date-Previous-Month/m-p/304830

But when I try this formula to get this value, didn't work as well when I put the measure in a Column chart. It must be appear the value from the date 30-11-2017 (9.057.180.489.18). Can anyone please help me with this?

 

 

power bi.png

 

1 ACCEPTED SOLUTION

Oh ty @Ashish_Mathur I already did what I need. I created a filter to the current and the previous month and putted on the sheet. So in the measure, I created a DAX calculation with calculate(sum(measure), lastdate(date)) and it worked fine for me. But thanks for replying this question. Have a great day

View solution in original post

9 REPLIES 9
rocky09
Solution Sage
Solution Sage

did you have any page leve/report level filters applied?

No, it doesn't. I just created in a new Dashboard to test this formula

can you post sample data

vlr_liquidoData Foto
905723602412/1/2017 
905722209511/29/2017
905718048911/30/2017

Capture.PNG

 

 

is this what you are trying?

No. I tried to explain that I want to show the last date from previous month, like in the formula I posted in the first post. So if I got 01-12-2017 as my current date in the database and all dates from november, I want to show the value of 30 nov 2017 because Its the last date from previous month. 

Hi,

 

So if the last date in your Data Table is March 10, 2018, then do you want to see a single column in the column chart with the value from Feb 28, 2018?  If the answer is yes, then what result would you expect if in your Data Table, there is no data at all for Feb 28, 2018?


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Oh ty @Ashish_Mathur I already did what I need. I created a filter to the current and the previous month and putted on the sheet. So in the measure, I created a DAX calculation with calculate(sum(measure), lastdate(date)) and it worked fine for me. But thanks for replying this question. Have a great day

@dcrios,

 

Glad to hear that. You may help accept solution. Your contribution is highly appreciated.

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

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors