Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hello,
I am keeping a track of days that have an Accidents or Incidents in order to make a dashboard that shows the consucative days from last Accident till the day of today.
I am using Sharepoint list to keep a track of the data.
I am stuck in how to show the consecutive days from the last Accident till the day of today. any idea?
Solved! Go to Solution.
Hi @ELSH1978 ,
Based on your description, I created these data.
Create measure.
Days Since Last Accident =
VAR LastAccidentDate = MAXX(FILTER('Table', 'Table'[TYPE] = "ACCIDENT"), 'Table'[Date])
RETURN
DATEDIFF(LastAccidentDate, TODAY(), DAY)
If your Current Period does not refer to this, please clarify in a follow-up reply.
Best Regards,
Clara Gong
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @ELSH1978 ,
Based on your description, I created these data.
Create measure.
Days Since Last Accident =
VAR LastAccidentDate = MAXX(FILTER('Table', 'Table'[TYPE] = "ACCIDENT"), 'Table'[Date])
RETURN
DATEDIFF(LastAccidentDate, TODAY(), DAY)
If your Current Period does not refer to this, please clarify in a follow-up reply.
Best Regards,
Clara Gong
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi,
Share some data to work with and show the expected result. Share data in a format that can be pasted in an MS Excel file.
Days without accident = TODAY() - MAXX(Filter('Table',[Type]="Accident"),[Date])
Thanks @lbendlin for your reply.
It didn't work this way, it is not showing the count of days since the latest accident till today, the values I got are the following:
thanks
Format it as a number or use INT()
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.