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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
fabd
Helper I
Helper I

Extract string from collumn to a new collumn

Hello Community,

 

I am trying to convert an excel function to Power BI. Excel is good, but i need Power BI to automate some stuff.

In excel the function is text.before and text.after (appeared in last version of office 365)

 

So, here is the content of a single column :

 

[<Company-PEPSI>, <Backup-No_backup>, <Rubrik-GOLD>, <Environnement-Production>, <Datacenter-NorthEurope>]

 

I would like to populate 3 new column named "Company","Environnement","Datacenter"

 

The string can be populated by different order:

[<Company-PEPSI>, <Backup-No_backup>, <Rubrik-GOLD>, <Environnement-Production>, <Datacenter-NorthEurope>]

[<Rubrik-GOLD>,<Company-PEPSI>, <Backup-No_backup>,  <Environnement-Production>, <Datacenter-NorthEurope>]

[<Datacenter-NorthEurope>,<Rubrik-GOLD>,<Company-PEPSI>, <Backup-No_backup>,  <Environnement-Production>]

 

I tried with SEARCH and LEFT/RIGHT function, but no success

 

application = 
LEFT(
    'VM'[vSphere Tag],
    SEARCH(
        "<Application-", 
        'VM'[vSphere Tag],
        ,
        SEARCH(
            ">",
            'VM'[vSphere Tag],
            LEN('VM'[vSphere Tag])
    )
))

 

 
Do you have an idea ?
 
Thanks for your time 🙂
1 ACCEPTED SOLUTION
fabd
Helper I
Helper I

YEAH that's right.

 

I found the solution by using, in the transform data GUI, the add collumn function and then extract text before and after.

 

Thats the same function that has been implemented in excel. I was looking for it in PBI but i didn't look at the right place

View solution in original post

2 REPLIES 2
fabd
Helper I
Helper I

YEAH that's right.

 

I found the solution by using, in the transform data GUI, the add collumn function and then extract text before and after.

 

Thats the same function that has been implemented in excel. I was looking for it in PBI but i didn't look at the right place

freginier
Super User
Super User

Instead of search try to split then you should have your 3 columns.. it's difficult to help without pbix file

 

______________________________________________________

If you found this post helpful, please give Kudos C

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 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.