Option to specify column order for Pivot

Old Topic,

I bumped with this characteristic of Easymorph a few days ago.

I used the method describe in this post: Pivot Columns in Order - #3 by rebmanna to order the columns the same order as the rows.

@dgudkov Maybe I am not understanding the mechanic behind pivot action, but could you give more details why after pivoted a column is not keeping the order of the rows by default?

The current algorithm is hash-based and therefore it returns columns in a random order. To make them less random, we sort them.

Let’s make it a feature request. We’ll discuss it internally.

Moved to #feature-requests.

2 Likes