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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
Anonymous
Not applicable

First day of month in a date

Hello everyone,

 

How to find an earlierst date in a date column but groupped  by year and month? Is there any simple formula for this? 
Example below:

Phillip_92_0-1651136979238.png

* Left table is a final one. On a right side you can find a source.

 

My goal is to create a matrix so I think, first step would be to create a "Y axis" measure and then "Values" measure taking into account date must be the same as Y axis ?

 

Would be grateful for help 🙂 

3 REPLIES 3
amitchandak
Super User
Super User

@Anonymous ,

 

Calculate(firstnonblankvalue('Date'[Date], [Measure]), filter(allselected('Date'), 'Date'[Month Year] = max( 'Date'[Month Year]) ) )

 

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

Hello! Thank you for quick respond. What "[Measure]" means exactly ?

Hi @Anonymous ,

 

Maybe you can try this method.

1 create a measure.

Measure =
if(CALCULATE(MIN('Table'[Date]), FILTER(ALL('Table'),[Year Month]=SELECTEDVALUE('Table'[Year Month]))) =SELECTEDVALUE('Table'[Date]),1)
 
2 put this measure in fiilter pane and set it show items is 1.
vchenwuzmsft_0-1651566890173.png

Pbix in the end you can refer.

Best Regards

Community Support Team _ chenwu zhu

 

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

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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