Order by using date

adambc
New Member

I’ve been trying for a few hours now to get ORDERBY to work but I am not having any luck. It won’t change the order of the list that is displayed

ORDERBY(
Table[ID],
[Creation Timestamp],
false)

I always get the below result. I’ve tried changing last param from false to true and it has no effect on the order.
|ID|Creation Timestamp|
|KSi4tjVp|19/07/2019 07:48:31|
|g27eJF0F|19/07/2019 08:18:59|
|C8WUReaF|24/07/2019 08:23:39|

Does anyone have any tips?

0 5 357
5 REPLIES 5

Is your ID a key column?

Steve
Platinum 4
Platinum 4

ORDERBY() cannot be used to change the order of entries in a view, if that’s what you’re trying to do. To affect the order of entries in a view, you need to configure the view itself.

adambc
New Member

Hi there, yes my ID is a key column and not using a view.

I’ve tried a different tack and used a Sort instead. This is working to sort the this. However now I can’t get the Top() function to work to pick the first item in the list. It is picking the last item.

Here is the list my query produces:
09/08/2019, 09:58:03 am , 02/08/2019, 09:46:33 am , 26/07/2019, 09:32:23 am , 19/07/2019, 11:03:49 am , 12/07/2019, 10:56:13 am

When I use Top(List, 1) the value I get back is 12/07/2019, 10:56:13 am, which is the last item in the list. Really weird.

adambc
New Member

Solved it by using Index() instead of Top() . I can’t see the Index function in the set of functions for LISTS, which is why I didn’t think such a thin existing until I did more searching.

In generally when you want to opposite order, you can sort it like TOP(SORT(Table[Column],FALSE),1)

Top Labels in this Space