functiongoogle-sheetstimefilter

How to use FILTER function to get the previous row data based on certain fixed conditions in google sheet?


enter image description here

Hi everyone,

I'm using the Filter function to get the Category based on 2 conditions below:

Based on the 2 conditions above, it will return category I as the answer. However, I hope to get the Category before I which is Category H. Is there any ways to modified the Filter function so that the answer return will always be the previous category without changing the 2 conditions? First thing came out in my mind is something like =FILTER(...)-1, but it doesn't work that way.

Any help will be greatly appreciated!


Solution

  • try:

    =INDIRECT(ADDRESS(MATCH(FILTER(B3:B19, E3:E19<=I4, A3:A19>=I3), B:B, 0)-1, 2))