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
Shruthi96
Helper III
Helper III

Help DAX command - If else statement

Hi Team , 

Need Help 

I am looking for the Dax column formula, where I have 3 work types and 2 products:
Product A : It should pull all the rows
For Product B :
                        Feature - It should pull all the rows
                        Bug Fix - It should pull all the rows
                        For Enhancement - It should pull only the rows which as "a11y" anywhere in the description column.

 

Shruthi96_1-1652867235970.png

 

Many thanks 

1 ACCEPTED SOLUTION
SpartaBI
Community Champion
Community Champion

@Shruthi96 

 

 

Required_Output_Column = 
SWITCH(
	TRUE(),
        'Table'[Product] = "A", "Y",
	'Table'[Work Type] IN {"Feature", "Bug Fix" }, "Y",
	SEARCH("a11y", 'Table'[Description], 1, 0 ) >=1 , "Y",
	"N"
)

 

 


2022-05-09 22_36_04-Power BI Workspace Datasets License Permissions - Microsoft Power BI Community.png

Showcase Report – Contoso By SpartaBI


SpartaBI_3-1652115470761.png  SpartaBI_1-1652115142093.png   SpartaBI_2-1652115154505.png

Full-Logo11.png

View solution in original post

4 REPLIES 4
Shruthi96
Helper III
Helper III

Thanks @SpartaBI 

Shruthi96
Helper III
Helper III

Thanks @SpartaBI  for replying. Formula should look for Product also. 

@Shruthi96 oh ye, missed that. I edited the furmula in the original message

SpartaBI
Community Champion
Community Champion

@Shruthi96 

 

 

Required_Output_Column = 
SWITCH(
	TRUE(),
        'Table'[Product] = "A", "Y",
	'Table'[Work Type] IN {"Feature", "Bug Fix" }, "Y",
	SEARCH("a11y", 'Table'[Description], 1, 0 ) >=1 , "Y",
	"N"
)

 

 


2022-05-09 22_36_04-Power BI Workspace Datasets License Permissions - Microsoft Power BI Community.png

Showcase Report – Contoso By SpartaBI


SpartaBI_3-1652115470761.png  SpartaBI_1-1652115142093.png   SpartaBI_2-1652115154505.png

Full-Logo11.png

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.

Top Solution Authors