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! Learn more
 
					
				
		
Hi all,
I want to show all tasks from a sellected month and the Delayed tasks from previous months.
Thanks!
| Month | Status | Task | 
| January | Delay | A | 
| January | On track | B | 
| January | Done | C | 
| March | Delay | D | 
| March | Done | E | 
| March | On track | F | 
Solved! Go to Solution.
You should be able to do this:
Count Measure = 
  VAR __Table = 
    ADDCOLUMNS(
      'Table',
      "__Selected",[Selected]
    )
RETURN
  COUNTROWS(FILTER(__Table,[__Selected] = 1))You will need a month number column and then you could do this:
Selected = 
  SWITCH(TRUE(),
    MAX('Table'[MonthNo]) = SELECTEDVALUE([MonthNo]),1,
    MAX('Table'[MonthNo]) < SELECTEDVALUE([MonthNo]) && [Status]="Delay",1,
    0
  )Hi @Greg_Deckler,
Thanks for the reply!
It's not working here, is this correct?
&& [Status]="Delay"
Regards,
Lucas
Thank you it worked, but now I have one problem. I need to count the number of tasks that are labeled as "1" and show it in a graph by Status, as it is not a collumn it's not working. Can you help with it?
You should be able to do this:
Count Measure = 
  VAR __Table = 
    ADDCOLUMNS(
      'Table',
      "__Selected",[Selected]
    )
RETURN
  COUNTROWS(FILTER(__Table,[__Selected] = 1))Thank you very much, It works!
But now I noticed one thing, I can't select more than one month, do you know how to solve this?
Is there a function to conver all values between MAX and MIN?
I want to select 1 or more months and have all tasks from them and the past "Delay" tasks.
For exemple, if selected March and April the output would be (K,A,D,E,F,G,H,I,J).
| Year | MonthNo | Month | Status | Task | 
| 2019 | 12 | December | Delay | K | 
| 2019 | 12 | December | On track | L | 
| 2019 | 12 | December | Done | M | 
| 2020 | 1 | January | Delay | A | 
| 2020 | 1 | January | On track | B | 
| 2020 | 1 | January | Done | C | 
| 2020 | 3 | March | Delay | D | 
| 2020 | 3 | March | Done | E | 
| 2020 | 3 | March | On track | F | 
| 2020 | 4 | April | Delay | H | 
| 2020 | 4 | April | Done | I | 
| 2020 | 4 | April | On track | J | 
I realized that the year is not being considered, if I select january, december would not be shown. I could use 2001 (January 2020) and 1912 (December) but it would no be user friendly, is there a way to transforme numbers (MonthNo) in text just to show in the slicer?
Thank you!
 
					
				
				
			
		
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.
 
            | User | Count | 
|---|---|
| 9 | |
| 5 | |
| 4 | |
| 4 | |
| 3 | 
| User | Count | 
|---|---|
| 23 | |
| 14 | |
| 11 | |
| 10 | |
| 9 |