Forum Discussion

formerlyknownas's avatar
5 years ago
Solved

trimming text strings in columns with multiple patterns

Hello!

 

I'd like to remove / trim any text after the hyphen in order to consolidate minor variations in batches.  As you can see in the graphic below, there are variations of the batch numbers and I'd like like to remove any text past the hyphen so that there are two batches: B10107 and B10108.  I'm bringing in this data from a SQL query, and could address this issue there.  However, I'm curious from a Power BI perspective how this could be solved.