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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
SimonMalberg
Regular Visitor

Transforming columns into row values

Hi,

 

I am doing a Net Promoter Score report were our customers are being asked different questions.

In six of the questions they can write comment.

 

In my dataset all questions is a column, and the answer the to question are the rows.

 

I would like to get the subject of the question and transform it into a row value before the answer to the question in a new column called Comment category.

 

At this moment all I can figure is to filter the six questions into six different tables. But i need to export this to excel afterwards for serveral differents routes.(working with ferries)

 

1. image is what i have now.

SimonMalberg_2-1681470127219.png

 

Additional info: all six tables are basically the same except the last column which differs in the question the customer is being asked which is optional to answer. I would like column no. 4 to be merged into one column. The tricky part is the customer can comment in serveral questions, so to concenate is not preferable.

 

2. image is what i prefer it to look like without having to do too much manual work, where column 4 (Kategori) is the question right before column 5(the answer to the question)

SimonMalberg_1-1681469511345.png

 

I hope I have explained my question in an understandable way and one of you might be able to help me.

 

Best,

Simon

1 ACCEPTED SOLUTION
DOLEARY85
Resident Rockstar
Resident Rockstar

Hi,

 

in power query select all the question columns, right click and unpivot them, this will put all the questions in one column and the answers in the column next to them.

 

If I answered your question, please mark my post as solution, Appreciate your Kudos 👍

View solution in original post

2 REPLIES 2
krishb1414
Helper III
Helper III

hi @SimonMalberg  You can merge all those tables by clicking Merge at top of ribbon and select columns you want to unpivot then click on UNPIVOT.

See the images below for your reference.

krishb1414_1-1681471384233.png

krishb1414_2-1681471440387.png

 

DOLEARY85
Resident Rockstar
Resident Rockstar

Hi,

 

in power query select all the question columns, right click and unpivot them, this will put all the questions in one column and the answers in the column next to them.

 

If I answered your question, please mark my post as solution, Appreciate your Kudos 👍

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

Top Solution Authors
Top Kudoed Authors