Forum Discussion
sccoleman1189
Helper I
7 years agoChange value based on value in other column
New to the Power BI world.. I am looking to create a new column that takes the value from another column if the column has a specific value. Example: If the home_station column has the na...
- 7 years agoColumn = if(PBI_Report[HOME_STATION]="XYZ",PBI_Report[WORK_STATION],PBI_Report[HOME_STATION])Just change the PBI_Report with your report's name.
Diegoctn
7 years agoFrequent Visitor
Column = if(PBI_Report[HOME_STATION]="XYZ",PBI_Report[WORK_STATION],PBI_Report[HOME_STATION])
Just change the PBI_Report with your report's name.
- sccoleman11897 years ago
Helper I
Thank you. Now, one question, if there are multiple values I want to change do I include "and,if" and if so how do I set that up? Been working on that and its not working
- Anonymous7 years agoNot applicable
HI sccoleman1189,
Maybe you can try to use 'in' operator to handle multiple values.
OR Condition= IF ( PBI_Report[HOME_STATION] IN { "XYZ", "MNO" }, PBI_Report[WORK_STATION], PBI_Report[HOME_STATION] ) AND Condition = IF ( PBI_Report[HOME_STATION] = "XYZ" && PBI_Report[BU] = "XXX", PBI_Report[WORK_STATION], PBI_Report[HOME_STATION] )Reference links:
Regards,
Xiaoxin Sheng