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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
Gaizka
Regular Visitor

How to condense rows with diferent number of columns

I have an excel file with the first column the date, that fix always, but in the following columns are listed numbers of services that have provided in that date. The point is that:

 

- one day they might have 2 services, next day 8 services, next one 1 and so on.

- A service can appear in the second column one day and the 10th next day

 

 

Day1  Service1  Service2 Service 3

Day2  Service3

Day3  

Day4  Service3 Service1 Service5 Service2 Service2

 

And so on

 

How can I handle this with power BI to be able to be able to filter per Service?

 

I know that ideally for Power BI that data should be something like this:

Day1  Service1

Day1  Service2

Day1  Service3

Day2  Service3

Day4  Service3 

 

and so on

 

But is there a quick way to amend it?

 

Thanks a lot 

1 ACCEPTED SOLUTION
jthomson
Solution Sage
Solution Sage

Fairly sure that in the query editor you can just pick your day column and then unpivot others, and it should automatically adapt to however many there are

View solution in original post

2 REPLIES 2
jthomson
Solution Sage
Solution Sage

Fairly sure that in the query editor you can just pick your day column and then unpivot others, and it should automatically adapt to however many there are

Wow! amazing, thanks a lot! you´re a star Smiley Happy

Helpful resources

Announcements
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.