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

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
gauravg3
Helper I
Helper I

Ratio of Closed Tickets in Month

Hi,

Can someone please help me in calculating a measure on ratio of Closed Incidents in a month. 

Criteria is for any given month, find ratio of closed incidents compared to open incidents. As an example, in the below table, if I want to calculate the ratio for month of Jan-22, it should be 100% (i.e. 2 x closed in Jan / 2 x opened in Jan).

 

Incident NumberCreate MonthClosed Month
INC1Jan-22 
INC2Dec-21Dec-21
INC3Dec-21Dec-21
INC4Jan-22Jan-22
INC5Nov-21Nov-21
INC6Dec-21Jan-22
INC7Oct-21Nov-21
INC8Nov-21Dec-21
INC9Nov-21Nov-21
INC10Oct-21Oct-21

 

Thanks

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @gauravg3 ,

 

Since there are two date columns with different values, I suggest you create a new table with all distinct Month-Year:

Distinct Month Year = 
var _t1=VALUES('Table'[Create Month])
var _t2=VALUES('Table'[Closed Month])
var _t=DISTINCT( UNION(_t1, _t2))
return SELECTCOLUMNS(FILTER(_t,[Create Month]<>BLANK()),"Month Year",FORMAT([Create Month],"mmm-yy"))

Eyelyn9_0-1645683994670.png

And then calculate the %:

Measure = 
var _create=CALCULATE(COUNTROWS('Table'),FILTER('Table',FORMAT([Create Month],"mmm-yy")=MAX('Distinct Month Year'[Month Year])))
var _close=CALCULATE(COUNTROWS('Table'),FILTER('Table',FORMAT([Closed Month],"mmm-yy")=MAX('Distinct Month Year'[Month Year])))
return DIVIDE(_create,_close)

Output:

Eyelyn9_1-1645684053960.png

 

Best Regards,
Eyelyn Qin
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

5 REPLIES 5
Anonymous
Not applicable

Hi @gauravg3 ,

 

Since there are two date columns with different values, I suggest you create a new table with all distinct Month-Year:

Distinct Month Year = 
var _t1=VALUES('Table'[Create Month])
var _t2=VALUES('Table'[Closed Month])
var _t=DISTINCT( UNION(_t1, _t2))
return SELECTCOLUMNS(FILTER(_t,[Create Month]<>BLANK()),"Month Year",FORMAT([Create Month],"mmm-yy"))

Eyelyn9_0-1645683994670.png

And then calculate the %:

Measure = 
var _create=CALCULATE(COUNTROWS('Table'),FILTER('Table',FORMAT([Create Month],"mmm-yy")=MAX('Distinct Month Year'[Month Year])))
var _close=CALCULATE(COUNTROWS('Table'),FILTER('Table',FORMAT([Closed Month],"mmm-yy")=MAX('Distinct Month Year'[Month Year])))
return DIVIDE(_create,_close)

Output:

Eyelyn9_1-1645684053960.png

 

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

Fowmy
Super User
Super User

@gauravg3 

Before answering your question, I would like to know if you have a dates table in your model and how the model is organized, this will help provide a better answer. share screenshot of your model

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

There is no separate date table in the model...All the values are in the same table.

amitchandak
Super User
Super User

@gauravg3 , Please refer to the blog on the same topic. The open ticket is same as a current employee, Hire is this month new, terminate is closed

https://community.powerbi.com/t5/Community-Blog/HR-Analytics-Active-Employee-Hire-and-Termination-tr...

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Hi Amit,

 

I tried the calculations mentioned in your separate post, but the output is same for all months on each calculation. Is there any other way to get % of closed tickets for each month.

 

gauravg3_0-1645497193307.png

 

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.