Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hello ,
i need to find the position of the first number in a column
Thank you i find this command but it gives me an error
SEARCH(\"[0-9]\", <string>)
thank you
Solved! Go to Solution.
Hi @cristianj
You need to use Power Query and the Text.PositionOfAny function.
Text.PositionOfAny - PowerQuery M | Microsoft Learn
Here's the query
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMkxMSlaK1YlWSkwyhDAqKquMYIKGiUZJxgj5FKPUNGOl2FgA", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [String = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"String", type text}}),
#"Added Custom" = Table.AddColumn(#"Changed Type", "Pos of First Number", each Text.PositionOfAny([String], {"0".."9"}))
in
#"Added Custom"
Regards
Phil
Proud to be a Super User!
pls txry this
Hi @cristianj
You need to use Power Query and the Text.PositionOfAny function.
Text.PositionOfAny - PowerQuery M | Microsoft Learn
Here's the query
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMkxMSlaK1YlWSkwyhDAqKquMYIKGiUZJxgj5FKPUNGOl2FgA", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [String = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"String", type text}}),
#"Added Custom" = Table.AddColumn(#"Changed Type", "Pos of First Number", each Text.PositionOfAny([String], {"0".."9"}))
in
#"Added Custom"
Regards
Phil
Proud to be a Super User!
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.