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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Zelbinian
Frequent Visitor

How to create new columns from compound values in a column with Power Query?

The data I have has a column called "Tags" that I need to transform into something more meaningful.

The "Tags" column is plain text and has contents that look like this: #store-aisle-product

There are other values in the Tags column as well, but this is the only one I care about. So what I need to do is the following:

  1. Isolate that tag
  2. Create a new column for the store, aisle, and product, respectively

 

I've been looking at the documenation and some examples here for various split and add column functions, but the Power Query syntax still reads like so much Greek to me 😞

 

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hey @Zelbinian

 

Try out the Column From Examples option in the Query Editor. It's codeless and you can tell Power BI which part of the field that you would like to extract and it can then infer from a couple of examples what it should do for the rest of the records. Give it a try and let me know if it works for your case!

 

Parker

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hey @Zelbinian

 

Try out the Column From Examples option in the Query Editor. It's codeless and you can tell Power BI which part of the field that you would like to extract and it can then infer from a couple of examples what it should do for the rest of the records. Give it a try and let me know if it works for your case!

 

Parker

Well that's some straight-up witchcraft. Thanks!

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.