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! Learn more

Reply
souhail98
Frequent Visitor

row data as column

Hi, 

 

For a transport analysis i want to know the all the activities/stops from the whole ride. 

Every ride has an unique ride header number and all the activities have also unique activity number. 

The activities are vertical stored in the table, i want them horinzontally to show and measure the time diffrence between them. 

Can some one help me with this? 

 

Thanks in advance. 

1 ACCEPTED SOLUTION

Hi @souhail98 ,

 

v-lionel-msft_0-1615355324810.png

Please refer to my .pbix file.

Note: The first thing you need to do is to pivot the table(refer to the step in Power Query).

 

Best regards,
Lionel Chen

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

6 REPLIES 6
souhail98
Frequent Visitor

Hi Amit, 

Thanks for your reply. 

The table below is my datasource, every row is an activity within the Transport ride. 

Ride header activity id activity name Timezip code, etc
313790180978start06:004844
313790180979Load06:154844
313790180980unload13:155001
313790180981end 17:004844

I want to make a table visual with calcultated (duration) columns, something like this below: 

Ride headerStartloadDuration load timeZipcode unload

Duration 

Drive and unload time 

Zipcodeend Duration drive back time Total time 
31379006:0006:1515 min484413:157 hours500117:003:4511 hours

 

I hope it is understandable. i dont know how to convert the vertical data to horizontal in a

chronological flow (start, load, unload, end ). 

 

Thanks in advance.

amitchandak
Super User
Super User

@souhail98 ,The information you have provided is not making the problem clear to me. Can you please explain with an example.
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.
Appreciate your Kudos.

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Hi Amit, 

Thanks for your reply. 

The table below is my datasource, every row is an activity within the Transport ride. 

Ride header activity id activity name Timezip code, etc
313790180978start06:004844
313790180979Load06:154844
313790180980unload13:155001
313790180981end 17:004844

I want to make a table visual with calcultated (duration) columns, something like this below: 

Ride headerStartloadDuration load timeZipcode unload

Duration 

Drive and unload time 

Zipcodeend Duration drive back time Total time 
31379006:0006:1515 min484413:157 hours500117:003:4511 hours

 

I hope it is understandable. i dont know how to convert the vertical data to horizontal in a

chronological flow (start, load, unload, end ). 

 

Thanks in advance.

Hi @souhail98 ,

 

v-lionel-msft_0-1615355324810.png

Please refer to my .pbix file.

Note: The first thing you need to do is to pivot the table(refer to the step in Power Query).

 

Best regards,
Lionel Chen

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

This is an example with multiple diffrent times, i want them in a chronological order. 
multiple times.PNG

 

Hi @v-lionel-msft

 

Thank you very much! Is it also possible to show the times on chronologic order? Sometimes there are more load and unload activities with diffrent times.

 

Thank in advance!

 

Best regards, 

Souhail

 

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.