From the course: Mastering Lookup Functions in Excel: Seven Powerful Formulas

Unlock the full course today

Join today to access over 24,600 courses taught by industry experts.

How to nest with XLOOKUP

How to nest with XLOOKUP

- [Instructor] In our earlier video, we spoke about how you can easily look up a value in either a vertical range or a horizontal range while using XLOOKUP. But what if we wanted to do both? That is, look up a value based off of two inputs, a row and a column. That's actually one of my favorite things to do with a LOOKUP function, and I found that few functions make this easy. Let's take a look at how we can do that. Here again, we have our employee table. Now, I want to specify an employee ID as well as one of these other metrics. When both of these are selected, I then want my value to get generated over here. Let's first see how I could get this if I just make my employee ID input dynamic while my header input will remain fixed at department. To do that, we'll enter =xlookup. We'll use our employee ID in the LOOKUP field and the employee ID column in the LOOKUP range. For the return array, we'll specify the department column as such. I'll then close my formula and hit Enter. Okay…

Contents