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! Get ahead of the game and start preparing now! Learn more
Need help to get the following result based on a given data:
| Code | Required Result |
| E1S | E1 |
| E2W | E2 |
| E3S | E3 |
| M2E | 2 |
| EE.1 | 1 |
| EE.2 | 2 |
| EE.11 | 11 |
| M11W | 11 |
Thanks for your help
Solved! Go to Solution.
@CJ_96601
Based on my understanding of the pattern I created a column in Power Query:
if (Text.Start([Code],1) = "E" and Text.Start([Code],2) <> "EE") then "E"&Text.Select([Code],{"0".."9"}) else Text.Select([Code],{"0".."9"})
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group
@CJ_96601
Based on my understanding of the pattern I created a column in Power Query:
if (Text.Start([Code],1) = "E" and Text.Start([Code],2) <> "EE") then "E"&Text.Select([Code],{"0".."9"}) else Text.Select([Code],{"0".."9"})
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group
thanks...it works perfectly well
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 38 | |
| 36 | |
| 33 | |
| 32 | |
| 29 |
| User | Count |
|---|---|
| 129 | |
| 88 | |
| 79 | |
| 68 | |
| 63 |