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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
Mikeellison
New Member

Count of parts with open status based on date

Hi,

I've read responses to similar request using open and close dates for tickets etc. My query is slightly different in that there is no close date in the table I have. The date value gets updated each time there is a status change. The final status is "closed".

 

I'd like to count number of parts/tickets that have an open status on any given day and show a running total trend chart over time.

 

Logic would count number of lines with a date based on date lines being counted (running total) and exclude any items which have a closed status on a given date.

 

Thanks, Michael 

1 ACCEPTED SOLUTION
v-xinruzhu-msft
Community Support
Community Support

Hi @Mikeellison 

You can refer to the following sample.

Sample data

vxinruzhumsft_0-1715914664150.png

1.Create a calendar table and create a relationship between tables.

 

Calendar = CALENDAR(DATE(2023,1,1),DATE(2024,4,30))

 

 

vxinruzhumsft_2-1715914835809.png

2.Create a measure

 

Measure = CALCULATE(DISTINCTCOUNT('Table'[ID]),'Table'[Status]="Open")

 

Then put the following field to visual field

vxinruzhumsft_3-1715914884201.png

 

Output

vxinruzhumsft_4-1715914893723.png

Best Regards!

Yolo Zhu

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

 

View solution in original post

1 REPLY 1
v-xinruzhu-msft
Community Support
Community Support

Hi @Mikeellison 

You can refer to the following sample.

Sample data

vxinruzhumsft_0-1715914664150.png

1.Create a calendar table and create a relationship between tables.

 

Calendar = CALENDAR(DATE(2023,1,1),DATE(2024,4,30))

 

 

vxinruzhumsft_2-1715914835809.png

2.Create a measure

 

Measure = CALCULATE(DISTINCTCOUNT('Table'[ID]),'Table'[Status]="Open")

 

Then put the following field to visual field

vxinruzhumsft_3-1715914884201.png

 

Output

vxinruzhumsft_4-1715914893723.png

Best Regards!

Yolo 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
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.