case statement
2 TopicsIF calculation where IF dimension contains Text then Text (with ELSEIF conditions)
Hello! I’m a Tableau user switching over to Power BI/DAX. I’m trying to replicate a Tableau calculation I had but having trouble figuring out the best approach in Power BI/Query. I am looking for an IF Contains THEN formula for multiple instances... Here is the calculation in Tableau: IF CONTAINS ([Campaign Name], “XYZ”) Then “XYZ Campaign” ELSEIF CONTAINS ([Campaign Name], “ABC”) Then “ABC Campaign” ELSEIF CONTAINS ([Campaign Name], “JKL”) Then “JKL Campaign” END Thanks!Solved650Views0likes1CommentMultiple Case Statement in a measure
Hi I need help with creating a measure for below case statement. I am using direct query so unable to create a calculate column. sum(case when Table1[field1] in (10, 12, 13, 33, 35, 37, 39) THEN 0 when Table1[field1] in (71, 75) THEN Table1[amt] when Table2[name] = 'AB' THEN [amt] else 0 end) as 'Gross' Appreciate if you could help with getting the measure for the above case statementSolved2.4KViews0likes2Comments