I have to speed up calculation in a table, I'll explain it below. If possible the fastest solution "but without VBA" is preferred.
The below is a small sample of the table. Actual table now have 15,000 rows and is growing. The aim is to have the last column reflect the latest name on all the rows, corresponding to the same ID. I mean, if an added row has the same ID value of any row above, the last column for all the rows which have that ID, will change to the Name of the latest row, so all will be the same. Pay attention to the ID on the last row, it is same as the first and the second rows. Although name for each of them is different, the last column always shows "KKK", since the one on the last row is "KKK".
I tried XLOOKUP but it is very slow for the reverse order (You know, I have to run it in reverse order since the table grows to the below). That code is also below (2nd one). Actually it is sufficient to search from the curent row to the end of the table, so I also tried the 3rd example below but it is still slow. Any fast solutions are welcome. If I use absolute reference (4st code) it becomes a problem, as the "calculated column" of the table when the table is growing to the below.
The below is a small sample of the table. Actual table now have 15,000 rows and is growing. The aim is to have the last column reflect the latest name on all the rows, corresponding to the same ID. I mean, if an added row has the same ID value of any row above, the last column for all the rows which have that ID, will change to the Name of the latest row, so all will be the same. Pay attention to the ID on the last row, it is same as the first and the second rows. Although name for each of them is different, the last column always shows "KKK", since the one on the last row is "KKK".
I tried XLOOKUP but it is very slow for the reverse order (You know, I have to run it in reverse order since the table grows to the below). That code is also below (2nd one). Actually it is sufficient to search from the curent row to the end of the table, so I also tried the 3rd example below but it is still slow. Any fast solutions are welcome. If I use absolute reference (4st code) it becomes a problem, as the "calculated column" of the table when the table is growing to the below.
Cell Formulas | ||
---|---|---|
Range | Formula | |
H4:H7 | H4 | =LOOKUP(2,1/(G4:INDIRECT("g"&ROWS(Tablo1)+ROW(Tablo1)-1)=G4),F4:INDIRECT("F"&ROWS(Tablo1)+ROW(Tablo1)-1)) |
Cell Formulas | ||
---|---|---|
Range | Formula | |
H4:H7 | H4 | =XLOOKUP([@ID],[ID],[Name],,-1) |
Cell Formulas | ||
---|---|---|
Range | Formula | |
H4:H7 | H4 | =XLOOKUP([@ID],[@ID]:INDIRECT("G"&ROWS(Tablo1)+ROW(Tablo1)-1),[@Name]:INDIRECT("F"&ROWS(Tablo1)+ROW(Tablo1)-1),,-1) |
Cell Formulas | ||
---|---|---|
Range | Formula | |
H4:H7 | H4 | =XLOOKUP([@ID],[@ID]:G$7,[@Name]:F$7,,-1) |