Forum Discussion
RecycleBin_Rob
2 years agoFrequent Visitor
Working with NA data
Hi, I'm still learning and did some research into the topic. It looks like Power BI doesn't have an ifna function like excel and uses lookupvalue. I looked at those threads, but couldn't figure o...
- 2 years ago
Create a custom column and try this...
if List.Contains({"NW","SE","NE","SW"},[quadrant]) then [quadrant] else if List.Contains({"NW","SE","NE","SW"},[geo_area_quadrant]) then [geo_area_quadrant] else if Text.Contains([display_address],"NW") then "NW" else if Text.Contains([display_address],"SW") then "SW" else if Text.Contains([display_address],"NE") then "NE" else if Text.Contains([display_address],"SE") then "SE" else "who knows" - 2 years ago
DAX for add new column:
Derived Quadrant = SWITCH( TRUE(), 'Table'[quadrant] <> "N/A", 'Table'[quadrant], 'Table'[geo_area_quadrant] <> "N/A", 'Table'[geo_area_quadrant], 'Table'[quadrant] = "N/A" && 'Table'[geo_area_quadrant] = "N/A" , SWITCH( TRUE(), CONTAINSSTRING('Table'[display_address], "SE"), "SE", CONTAINSSTRING('Table'[display_address], "NE"), "NE", CONTAINSSTRING('Table'[display_address], "NW"), "NW", CONTAINSSTRING('Table'[display_address], "SW"), "SW" -- ... add more conditions of your needs , "N/A") , "N/A" -- you can chose if any of the above conditions do not meet, as default value! )
sevenhills
2 years agoSuper User
DAX for add new column:
Derived Quadrant =
SWITCH( TRUE(),
'Table'[quadrant] <> "N/A", 'Table'[quadrant],
'Table'[geo_area_quadrant] <> "N/A", 'Table'[geo_area_quadrant],
'Table'[quadrant] = "N/A" && 'Table'[geo_area_quadrant] = "N/A" ,
SWITCH( TRUE(),
CONTAINSSTRING('Table'[display_address], "SE"), "SE",
CONTAINSSTRING('Table'[display_address], "NE"), "NE",
CONTAINSSTRING('Table'[display_address], "NW"), "NW",
CONTAINSSTRING('Table'[display_address], "SW"), "SW"
-- ... add more conditions of your needs
, "N/A")
, "N/A" -- you can chose if any of the above conditions do not meet, as default value!
)