# Question: Formula answer plus one/two cells down

I am using a SMALL formula and then a LOOKUP formula to automatically sort a table because that is the only way I have found how to do it. The problem is when looking up the same value I only get the first one returned.

Is there a way to add have the formula and then add something like +1 cell down?

I dont know how to put the formulas in but the table below demonstrates my problem. i want something like IF header 5 is the same, do the same formula, but then go one cell down so it returns green instead of another red.

If adding one cell down isn't an option, are there other formulas that I could add in to get the result i want?

Thanks

Header 1 | Header 2 | Header 3 | Header 4 | Header 5 |
---|---|---|---|---|

autosort table | ||||

red | 1 | red | 1 | |

green | 1 | red | 1 | |

blue | 2 | |||