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

Prepping for a Fabric certification exam? Join us for a live prep session with exam experts to learn how to pass the exam. Register now.

Reply
Locco
Helper III
Helper III

Merge names in a row

I need to merge names in a single row and I have been having trouble getting this to work. I would like to do this without using DAX and to have it in query but I am open to a DAX solution as well.

 

I have a column which lists three different machine names. I need to group two of the machines together.

 

Machine001

Machine002

Machine003

 

I would like a column to have 

 

Machine001 & Machine003

Machine002

 

I've tried various other similar solutions, but nothing is giving the expected result, or they just are not fit for my purpose.

 

Can anyone help me with this?

 

Thanks!

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Locco ,

 

Assume you have grouped the machines.

vjaywmsft_0-1651720151636.png

First add an index column to the table.

vjaywmsft_1-1651720170947.png

Then select the index column and use pivot feature.

vjaywmsft_2-1651720301059.png

At last, merge the selected columns(under Add column tag) and delete unneeded columns.

vjaywmsft_4-1651720576863.png

 

Best Regards,

Jay

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Hi @Locco ,

 

Assume you have grouped the machines.

vjaywmsft_0-1651720151636.png

First add an index column to the table.

vjaywmsft_1-1651720170947.png

Then select the index column and use pivot feature.

vjaywmsft_2-1651720301059.png

At last, merge the selected columns(under Add column tag) and delete unneeded columns.

vjaywmsft_4-1651720576863.png

 

Best Regards,

Jay

parry2k
Super User
Super User

@Locco what is the logic to combining machine 1 and machine 3?

 

 

Follow us on LinkedIn and YouTube.gif to our YouTube channel

I would  Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make effort to give Kudos to whoever helped to solve your problem. It is a token of appreciation!

 

Visit us at https://perytus.com, your one-stop shop for Power BI-related projects/training/consultancy.



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

@parry2k 

 

The machines have a combined waste limit. So both machines together cannot exceed X amount of waste. I have no real way of splitting up the waste limit because it's not equally divided between the machines. If I group the machines on this table then their waste is combined and I can compare that against their limit. I have a seperate table with the waste limits and that table has the machines grouped. I figured the easiest option was to group the machines on this table and create a relationship between the two tables.

Helpful resources

Announcements
PBIApril_Carousel

Power BI Monthly Update - April 2025

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

Notebook Gallery Carousel1

NEW! Community Notebooks Gallery

Explore and share Fabric Notebooks to boost Power BI insights in the new community notebooks gallery.

April2025 Carousel

Fabric Community Update - April 2025

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