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
MarineAngola
New Member

Find and remove last occurence in a serial of dates

Good afternoon,

 

I'm trying to aggregate one planning in order to generate Time sheet and I would like to find a way to remove the last day worked in a serial. This could happen several times a month, my idea is to detect a change of value in the serial of date (e.g : man at work = 1 then 0 when off) and remove the day before the value change from 1 to 0.

I have no idea how to proceed, either on Query or in DAX.

 

Here below in yellow the value to remove (column are days in month, value are activities (work = 1, off = 0))

MarineAngola_0-1689180291107.png

 

Many thanks for your help !

 

Best regards

1 REPLY 1
lbendlin
Super User
Super User

Please provide sample data (with sensitive information removed) that covers your issue or question completely, in a usable format (not as a screenshot).
https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-...
Please show the expected outcome based on the sample data you provided.

https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447...

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!

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