Forum Discussion
CJ_96601
4 years agoHelper V
Extract Data based on requirements
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
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"})