Forum Discussion
AlGrant
3 years agoFrequent Visitor
New conditional Column based on two status columns in the same table
Hello, I'm a new Powerbi user and am having issues creating a measure, any help would be appreciated. Within a single table I have two columns for item status, one based on Migration Status a...
- 3 years ago
You can do that with a calcualted column using a SWITCH statement like this.
Actual Program Status = SWITCH ( TRUE(), YourTable[Migration Status] = "Complete" && YourTable[Decom Status] = "Complete", "Complete", YourTable[Migration Status] <> "Not Started" && YourTable[Decom Status] = "Not Started", "In Progress", YourTable[Migration Status] = "Complete" && YourTable[Decom Status] <> "Complete", "Decom Pending", YourTable[Migration Status] = "Not Started" && YourTable[Decom Status] = "Not Started", "Not Started", "Other" )You would just need to change the name of the table to match your model.
jdbuchanan71
3 years agoSuper User
You can do that with a calcualted column using a SWITCH statement like this.
Actual Program Status =
SWITCH (
TRUE(),
YourTable[Migration Status] = "Complete" && YourTable[Decom Status] = "Complete", "Complete",
YourTable[Migration Status] <> "Not Started" && YourTable[Decom Status] = "Not Started", "In Progress",
YourTable[Migration Status] = "Complete" && YourTable[Decom Status] <> "Complete", "Decom Pending",
YourTable[Migration Status] = "Not Started" && YourTable[Decom Status] = "Not Started", "Not Started",
"Other"
)
You would just need to change the name of the table to match your model.
- AlGrant3 years agoFrequent Visitor
Thanks you for your help jdbuchanan71!