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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
brslagle
New Member

Sort Matrix by descending timestamp

Hi all, I have a matrix table that has a list of timestamps as the columns (see below)... I want to be able to have the most recent timestamp show first (left most) and then progress (right) in a descending order (the timestamps also can repeat)... I have tried multiple different solutions with index columns and then selecting that to sort the timestamp column but I have not had any luck... Any help would be appreicated. 

 

brslagle_1-1709862705718.png

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @brslagle 

 

First, you can create an index column in Power Query, and then sort your date column by index column.

vjialongymsft_0-1710136660966.png
vjialongymsft_1-1710136712047.png

This is the result you want:

vjialongymsft_2-1710136752174.png

 

 

 

 

 

 

Best Regards,

Jayleny

 

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

2 REPLIES 2
Anonymous
Not applicable

Hi @brslagle 

 

First, you can create an index column in Power Query, and then sort your date column by index column.

vjialongymsft_0-1710136660966.png
vjialongymsft_1-1710136712047.png

This is the result you want:

vjialongymsft_2-1710136752174.png

 

 

 

 

 

 

Best Regards,

Jayleny

 

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

 

 

lbendlin
Super User
Super User

Index column is going in the right direction.  However, you need to reverse its order.  Say you have 10000 rows, then use 10001 -[Index]  as your "sort by"  column.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.