I have a collection of items, where each item has these fields: Title, DateCreated, and DateUpdated
I want to order these items so that the most recent items are displayed first, where the most recent item is the one that was just created or update.
So if I created Item2 three seconds ago, it will show up on top. But if I then go update Item1, it will now show up on top, because Item1’s DateUpdated is more recent than Item2’s DateCreated
Is there a way to order a collection this way based on two dates?
1 Answer