Search code examples
arraysgoogle-sheetsgoogle-sheets-formulavlookuparray-formulas

Is there any possibilities to change normal vlookup formula to array formula


I have a sheet below, in that I used a formula in "WEEKLY" tab B3 to find the latest price against the code in the "INDIVIDUAL" sheet. I have the formula for my need, but that formula is a normal VLOOKUP. I want to convert the same formula to array formula. so that I can protect that cell to avoid human error. please see the formula in B3, and pls put the array formula in C3. that must give the same result in Col B.

Thank you

here is the sheet

https://docs.google.com/spreadsheets/d/10fxGKhiBwFfv1osdwTI3wu8i3knqmKQKHC8V1ffca5M/edit#gid=107749899


Solution

  • try:

    =ARRAYFORMULA(IFNA(VLOOKUP(A3:A, 
     SORTN(SORT({Individual!C3:C, 
             ROW(Individual!C3:C), 
                 Individual!A3:E}, 2, 0), 9^9, 2, 2, 0), 7, 0)))