Selecting Specific Characters In M

Chris Webb points out a new function in Power BI:

It’s very easy to use: the first parameter takes a text value, the second parameter takes either a text value containing a single text value or a list of single characters, and it returns the text from the first parameter minus all characters that are not in the second parameter. For example, the expression:

Text.Select("Hello", "l")

…returns the text value “ll”

Click through to see an example of how you can use this to filter out punctuation and other unwanted characters.

Related Posts

Substitution Variables In Power Query

Doug Burke gives us an example of here substitution variables make our lives easier in Power Query: A substitution variable substitutes a variable (a changing value) to get a different result     a + b = c (where ‘a’ and ‘b’ are substitution variables that define value ‘c’)         If a = 5 and b = 2 then c […]

Read More

Migrating Excel Power Pivot Models To SSAS

Imke Feldmann has a walkthrough to show how to migrate a Power Pivot model in Excel into SQL Server Analysis Services by way of Power BI: In Visual Studio there is a wizard to migrate an Excel Power Pivot model to a SSAS model. But this will not bring over the M-queries unfortunately. But there […]

Read More


December 2017
« Nov Jan »