Lookup data in the table you are working in and add the result in the same table

Copper Contributor
At a gate, numbered tickets are scanned.
All scanning data are collected in a table, first colum, containing the time stamps starting with oldest scanning. New scans are added at bottom of table. Ticketnumber is stored in secondth colum.
In a  third colum, called "previous scan", on each line, I would like to add previous time of scanning of this particular ticket.

 

An example of table is attached. Which formula to enter in to the cells of column "previous scan" in order to obtain the required result? Thanks a lot for your help. Fîlip

 

3 Replies

@Filip_u 

= MAXIFS( scan.time, ticket, ticket, scan.time, "<" & scan.time )

For me, the formula is in one cell and spills to fill the column but similar formulae can be used for CSE arrays, Excel Tables or basic formulas, the last using implicit intersection.  Of these, the table appears the least alike

= MAXIFS( [Time of scanning],

[Ticket], [@Ticket],

[Time of scanning], "<" & [@[Time of scanning]] )