Home > front end >  INDEX(FILTER(SORT not solving - Need an alternative?
INDEX(FILTER(SORT not solving - Need an alternative?

Time:01-17

Purpose: I'm trying to fetch the value from column c in the first sheet, where column a matches to column a in current sheet. If there are more than one matches in column a, fetch the most recent entry, according to the date in column b. If the most recent cell in column c was left blank, go back and fetch from the most recent matching row in which column c contains a value.

See the enter image description here

CodePudding user response:

You can try with QUERY and MAP:

=MAP(A2:A,C2:C,LAMBDA(ax,cx,IF(ax="","",QUERY('Visit log'!A2:C,"Select C where C is not null AND A = '"&ax&"' order by B desc limit 1"))))
  • Related