What formula to use?

I like some advise about what formula to use. I have read the info on; Lookup, Vlookup and Match/Index but I don’t get it.

I need to give in data in columns. right from that I need to show the category name.

the categories are listed in another sheet from 1 to 12

For not typing out the name every time I like to use a number.
So I type my date, discription, amount, and then the code
So 1 for Category AAA, 2 must show Category BBB etc
So every row shows category name in 5th column

Hope you understand what I try to explain. Thanks for any advise. Ray

If the answers given aren’t exactly what is needed, then please upload a small example with pretend data and a hand-entered example of what is needed in the end. Use the up arrow icon button to upload an ODS.

You have to store both the code and the formula for extracting the category. Place the VLOOKUP formula in 5th column.
$Sheet1.E2: =VLOOKUP(D2;Categories;2;0)

Important: Assign a name to the range of categories, otherwise it will not work, because the data are on a different sheet. Edit: see below: not necessary, but recommended.
Categories: =$Sheet2.$A$2:$B$13
1st row contains category headers (column titles): Code, Name.
Search by code, and retrieve the name from the second column (2), the VLOOKUP parameter 0 means an exact code match.

2 Likes

Could, and it is easier to understand, but no needed. You can just use =VLOOKUP(D2;$Sheet2.$A$2:$B$13;2;0)

2 Likes

Yes, indeed. And that’s a good approach. I can’t figure out where I got this limitation from. Thanks.

1 Like

Thanks @eeigor and @LeroyG for the code line .

Will adjust cell references and go to work with it.
Hope it turns out.
If not I’ll be back with more questions :stuck_out_tongue_winking_eye:

Cheers