Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!
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.
Solved! Go to Solution.
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 _ Rongtie
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
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 _ Rongtie
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Is this what you are looking for?
| User | Count |
|---|---|
| 53 | |
| 37 | |
| 31 | |
| 21 | |
| 19 |
| User | Count |
|---|---|
| 138 | |
| 102 | |
| 59 | |
| 36 | |
| 35 |