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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
RPAI2812
Helper I
Helper I

Reorganizing data

Hi, I wanted some help to rearrange my table in Power Query 🙂
Currently, I have one column for each initial and end date for three different trips. 

 

PersonStart Trip 1End Trip 1Start Trip 2End Trip 2Start Trip 3End Trip 3
Peter01/01/202207/01/202228/01/202204/02/202216/02/202223/02/2022
Maria01/01/202207/01/202228/01/202204/02/202216/02/202223/02/2022
John06/01/202217/01/202218/02/202224/02/202208/03/202213/03/2022

 

I wanted to unpivot that so the table would like the one below. I have a column with the trip number and the start and end date from each trip.

 

PersonTripStart DateEnd Date
Peter101/01/202207/01/2022
Peter228/01/202204/02/2022
Peter316/02/202223/02/2022
Maria101/01/202207/01/2022
Maria228/01/202204/02/2022
Maria316/02/202223/02/2022
John106/01/202217/01/2022
John218/02/202224/02/2022
John308/03/202213/03/2022
1 ACCEPTED SOLUTION
HotChilli
Super User
Super User

Yes it's an Unpivot (all date columns).

Split the resulting column (by Space as far right as possible)-> that gets the numbers into a column.

Then Pivot the 'Start Trip'/End Trip' Column with Don't Aggregate

View solution in original post

1 REPLY 1
HotChilli
Super User
Super User

Yes it's an Unpivot (all date columns).

Split the resulting column (by Space as far right as possible)-> that gets the numbers into a column.

Then Pivot the 'Start Trip'/End Trip' Column with Don't Aggregate

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors
Top Kudoed Authors