Forum Discussion
New Measure For Column Data Replacement
Hi, I have a column of data that specifies shift/crew A, B, or C for different manufactured products and I would like to create a New Measure to replace A, B, and C with 1, 2, and 3 instead. I used the following code:
NewMeasure =
SWITCH(
SELECTEDVALUE('RS'[Crew]),
"A", 1,
"B",2,
"C",3
)
The new measure doesn't seem to work. Can anybody help me with this please? Thanks.
- Anonymous3 years ago
hHi AsalN ,
There doesn't seem to be anything wrong with this Measure.
I have also created a column.
Column = SWITCH(RS[Crew],"A",1,"B",2,"C",3)How to Get Your Question Answered Quickly
If it does not help, please provide more details with your desired output and pbix file without privacy information (or some sample data) .
Best Regards
Community Support Team _ RongtieIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
2 Replies
- Ahmedx
Super User
Is this what you are looking for?
- AnonymousNot applicable
hHi AsalN ,
There doesn't seem to be anything wrong with this Measure.
I have also created a column.
Column = SWITCH(RS[Crew],"A",1,"B",2,"C",3)How to Get Your Question Answered Quickly
If it does not help, please provide more details with your desired output and pbix file without privacy information (or some sample data) .
Best Regards
Community Support Team _ RongtieIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.