Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hi all,
Does anyone know how to extract the year from this text string? I trired "Text Extraction" and "Delimiter" but it is not coming out the way I want.
I want the year in one column but I am also showing "Gen".
Thank you for your help
Solved! Go to Solution.
Thank you but this solution works
List.RemoveNulls (
List.Transform (
Text.Split ( _[Campaign Name], "-" ),
each try Number.From ( _ ) otherwise null
)
){0}
Hi @ysherriff - you could try something like Text.Remove - PowerQuery M | Microsoft Learn or Text.Select - PowerQuery M | Microsoft Learn
Select = Text.Select( [Text] , {"0".."9"} )
Remove = Text.Remove( [Text] , {"a".."z", "A".."Z"})
Thank you but this solution works
List.RemoveNulls (
List.Transform (
Text.Split ( _[Campaign Name], "-" ),
each try Number.From ( _ ) otherwise null
)
){0}
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
17 | |
9 | |
8 | |
7 | |
7 |