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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
BigKev
Helper III
Helper III

Flag the last date of the month for extract date

Hi All,

 

I have multiple extract date in one month on my data set.

 

For my monthly reporting, I just need to pick the last extract date of every extract the month. How can I create a flag to only pick the last extract date of a month?

 

Thanks.

 

Cheers,

Kev

 

Capture.PNG

 

1 ACCEPTED SOLUTION

@BigKev ,

Just change the DAX like below:

Flag = If(Table[ExtractDate]=ENDOFMONTH(Table[ExtractDate]),1,0)

Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard

View solution in original post

3 REPLIES 3
Tahreem24
Super User
Super User

@BigKev ,

Create DAX like below:

Flag = If(Table[ExtractDate]=MAX(Table[ExtractDate]),1,0)

 

Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard

HI Tahreem24,

 

Thank you for the prompt response.

 

The Dax queries only give me the flag on the latest date, which  is 12/10/20.

 

I need to have flag '1' on the last date for every extract month, as per in the port scr.

 

Cheers,

Kev

@BigKev ,

Just change the DAX like below:

Flag = If(Table[ExtractDate]=ENDOFMONTH(Table[ExtractDate]),1,0)

Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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