Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now

Reply
patri0t82
Post Patron
Post Patron

Search for Word in String, bring back Word +

Hello, I'm trying to look in [Column] for the word "Scenario". If it finds it, I need to return "Scenario " + the next 2 characters. For example, the string may read "2040 3m Scenario 1 **DO NOT CHANGE**" and I need to return "Scenario 1"

2 ACCEPTED SOLUTIONS
patri0t82
Post Patron
Post Patron

Actually, I'll just look for Text.Contains "Scenario 1" or "Scenario 2" etc. That should do what I need, too. Sorry to bother!

View solution in original post

serpiva64
Solution Sage
Solution Sage

Hi,

from this

serpiva64_1-1679322622030.png

to achieve this 

serpiva64_2-1679322649842.png

 

 

 you have to add a custom column

Text.Range([Column1], Text.PositionOf([Column1],"Scenario"),10)

serpiva64_0-1679322572195.png

If this post is useful to help you to solve your issue, consider giving the post a thumbs up and accepting it as a solution!

View solution in original post

3 REPLIES 3
serpiva64
Solution Sage
Solution Sage

Hi,

from this

serpiva64_1-1679322622030.png

to achieve this 

serpiva64_2-1679322649842.png

 

 

 you have to add a custom column

Text.Range([Column1], Text.PositionOf([Column1],"Scenario"),10)

serpiva64_0-1679322572195.png

If this post is useful to help you to solve your issue, consider giving the post a thumbs up and accepting it as a solution!

That's perfect! Thanks so much for figuring this out for me!!

patri0t82
Post Patron
Post Patron

Actually, I'll just look for Text.Contains "Scenario 1" or "Scenario 2" etc. That should do what I need, too. Sorry to bother!

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

February Power BI Update Carousel

Power BI Monthly Update - February 2026

Check out the February 2026 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.