In one of Afinity webinars they give an example of using argMin/argMax aggregate functions to find the first/last value in some table. They are using the following table: