Forum Discussion

FaisalImam's avatar
FaisalImam
Icon for Helper I rankHelper I
4 years ago

Dax Query to get data opened before this month

Hi Team, 

 

I  need to show the count of tickets  that were opened  before this month and  are resolved or still open in the present month..

 

I have written a Measure but getting wrong count : 

backlog  = CALCULATE(COUNT(Incident[NUMBER]),FILTER(Incident,Incident[OPENED].[MonthNo] < MONTH(TODAY())),FILTER(Incident,Incident[RESOLVED].[MonthNo] = MONTH(TODAY()) || BLANK()))
 
I am getting wrong count because when filtering { month no < month(today)  , it excludes  tickets that are opened in month - (7-12) of previous years.. i need to include that. 
 
Please modify the query in best possible way
 

2 Replies