Filling out cells based on another cell in Google Sheets

Viewed 83

I am trying to fill out cells in Google sheets based on another cell. That is, I have drop down list in column J and based on what I choose in that column, I need cells in column K to fill with a specific number. I tried conditional formatting, but that works for colours only, not values. I tried IF function, but this doesn´t work either:

enter image description here

Anyone has any ideas? Thanks a lot!

1 Answers

use in empty column in K2 cell:

=INDEX(IFNA(VLOOKUP(J2:J; 
 {"Cyklistické bundy"\ "2642"; 
  "Dámske bundy"\      "1763"; 
  "Pánske bundy"\      "1739"}; 2; 0)))
Related