Get Id from value in Excel

enter image description here

How can I get the value 10 in the selected cell (B8), from the text in the C8?

I tried =VLOOKUP(C8,B3:C5,1) but don't really achieved something #N/A as result...


Solution 1:

For vlookup your value to be picked should be on right side of the array so instead of storing your id in column B, store it in column D then try with you updated vlook up formula, this time it should work also put a ,False before closing paranthesis in your forumula

Or if you dont want your id on right side, check Xlookup function here

Solution 2:

@Usmaan Waheed is correct about VLOOKUP and the advice about XLOOKUP (if you have Excel 365). Another method to obtain the result is to use INDEX and MATCH functions as shown on the formula below:

=INDEX(B3:B5,MATCH(C8,C3:C5,0))

Result