Forum Discussion
Extract part of string
Dear experts,
I need to extract a part of a string either through calculated column or power query.
The code I'm looking for might or might not be in the target column and it's not always in the same position. It always starts with "AA25" and there are 8 numbers after it. Like: "AA2512345678"
I can identify the columns using:
Column = FIND("AA25", Payables[Subject],,BLANK())
but I need is the calculated column to display the actual code.
How can I approach this?
setis , a new column like
mid(Payables[Subject], FIND("AA25", Payables[Subject],,BLANK()),8)
//change 8 to 12 as per need
mid(Payables[Subject], FIND("AA25", Payables[Subject],,BLANK()),12)
1 Reply
- amitchandak
Super User
setis , a new column like
mid(Payables[Subject], FIND("AA25", Payables[Subject],,BLANK()),8)
//change 8 to 12 as per need
mid(Payables[Subject], FIND("AA25", Payables[Subject],,BLANK()),12)