or function
4 TopicsHow to use OR Operator in dax calculation?
How can I write this statement with OR operator so that if these conditions don't meet then I should get "Product Level" Product Level for Index = IF(ISBLANK(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Market Level]),"# Exclude", IF(ISBLANK(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Product Level]),"# Exclude", IF(ISBLANK(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Customer Level]),"# Exclude", IF(ISBLANK(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Customer Cluster]),"# Exclude", IF(SELECTEDVALUE(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Market Level])="","# Exclude", IF(SELECTEDVALUE(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Product Level])="","# Exclude", IF(SELECTEDVALUE(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Customer Level])="","# Exclude", IF(SELECTEDVALUE(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Customer Cluster])="","# Exclude", IF(SELECTEDVALUE(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Market Level])="# Exclude","# Exclude", IF(SELECTEDVALUE(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Product Level])="# Exclude","# Exclude", IF(SELECTEDVALUE(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Customer Level])="# Exclude","# Exclude", IF(SELECTEDVALUE(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Customer Cluster])="# Exclude","# Exclude", IF(SELECTEDVALUE(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Market Level])="Exclude","# Exclude", IF(SELECTEDVALUE(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Product Level])="Exclude","# Exclude", IF(SELECTEDVALUE(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Customer Level])="Exclude","# Exclude", IF(SELECTEDVALUE(RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Customer Cluster])="Exclude","# Exclude",RB_RGM_PAT_O_99_PowerBI_PAT_Output[◊ Product Level]))))))))))))))))Solved1.2KViews0likes3CommentsIF string equals A, or B, or C, then D
Hi all, I am pretty new to DAX, and I have been stuck on an IF statement since this morning. The problem is I have a list of countries as strings. I want to group them, using a new column, into continents. For instance: IF [country] = "Italy", "Europe". and this line works pretty well. The problem is I would like to specify also other nations. I don't want to create endless IF statements, you know. XD So I think I need something like that: IF [country] = "Italy", "Germany", "Spain", then "Europe" Thanks for any help you can give me. Also, if there are better solutions, my ears are open 😄 💙Solved11KViews0likes2CommentsConvert Calculated Calculated Column to Measure
Hi group! I'm stuck with something... I currently have a calculated column in power query like this: if [TEAM.IS_ROLE] = 1 or Text.Contains([TEAM.RESOURCE_NAME],"Dummy") then [ALLOC_HOURS]/[DWH_CMN_PERIOD_M_V.PERIOD_FTE] else 0 i would like to turn this into a measure instead, but i cant figure out how to get the OR part correct Can someone kindly advise! (or maybe in cant' be done?) Cheers Andy944Views0likes3CommentsDisplay distinct values with multiple OR filters
Hello! I would like to consult to you this problem --- so I have the an ID, name, Col1, Col2, and Col3 columns.. I would like to display the distinct ID and name column into a table with (col1>=5 and col1<10) OR (col2>=5 and col2<15) OR (col3>=5 and col3<15) filters. i created a calculated column like this, to serve as my filter.. ColumnFilter = SWITCH(TRUE(), Query1[col1] >=5 && Query1[col1] < 10, ">=5 & <10" , Query1[col2] >=5 && Query1[col2] < 15, ">=5 & <15" , Query1[col3] >=5 && Query1[col3] < 15, ">=5 & <15" ) but i am not sure if the SWITCH function functions like an OR operator. I am also not sure how to apply this and get the distinct values in my ID column. So basically i need to get the distinct ID values passed with any of the filters. Thank you in advance!Solved16KViews0likes4Comments