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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
iou812
New Member

monthly kpi when only start and end date available

Hello All -

 

If I have a list of data that looks like this...

issue1 opendate1 closeddate1

issue2 opendate2 closeddate2

issue3 opendate3 closeddate3

...

 

[And some entries where there is no closeddate, because the issue is still open...]

 

What is the easiest/best way for me to produce a chart that shows the number of open issues per month?  For example,

NumberOfOpen   x      y      z   ...

Month                 Jan  Feb  Mar ...

 

Any/all insights greatly appreciated.  Thanks!

Tom

1 ACCEPTED SOLUTION

Take a look at this https://community.powerbi.com/t5/Desktop/Open-Tickets-per-group-by-date/m-p/9059#M1661 



* Matt is an 8 times Microsoft MVP (Power BI) and author of the Power BI Book Supercharge Power BI.

View solution in original post

2 REPLIES 2
AlexChen
Employee
Employee

Hi,

 

I assume you have a table like below.

 

1.png

 

Firstly Add  a new column called "Month" from "openDate" which shows the month of "openDate" in Query Editor.

 

4.png

 

In this table, If you want to calculate the issues that have blank closeDate for everymonth, you can use measure below.

 

NumOfIssues = CALCULATE(COUNTAX(issueTable, issueTable[issue]), Filter(issueTable, issueTable[closeDate] = BLANK()))

 

2.png

 

But If you also want to calculate the issues whose closeDate is after the current month of openDate, for example, issue2,

It is closed in February, not in January, you can use measure below:

 

NumOfIssues = CALCULATE(COUNTAX(issueTable, issueTable[issue]), Filter(issueTable, issueTable[closeDate] = BLANK() || And(issueTable[closeDate] <> BLANK(), FORMAT(issueTable[closeDate], "yyyymm") > FORMAT(issueTable[openDate], "yyyymm"))))

 

 

3.png

 

Best Regards

Alex

 

Take a look at this https://community.powerbi.com/t5/Desktop/Open-Tickets-per-group-by-date/m-p/9059#M1661 



* Matt is an 8 times Microsoft MVP (Power BI) and author of the Power BI Book Supercharge Power BI.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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