The Complete Excel Course with AI Integration

XLOOKUP and VLOOKUP for researchers

One participant's data is often spread over several sheets: a screening log, each questionnaire, the lab results and a codebook. The Complete Excel Course with AI Integration teaches the lookups that gather those pieces into one analysis table by ID, on PeopleInsight, an industry-standard HR workbook, and the path below runs through them in order: exact-match VLOOKUP, XLOOKUP with its own if-not-found answer and a two-way lookup, IFERROR, INDEX with MATCH, and the keys a lookup depends on.

Taught by Sagnik Bhattacharya and Virginia Thorn

The Complete Excel Course with AI Integration: Sagnik Bhattacharya and Virginia Thorn

What you will be able to do

At work, you will be able to:

  • Join a screening log, questionnaire sheets and lab results into one analysis table by participant ID with XLOOKUP, copying one formula across to bring several variables in from the same key.
  • Place a codebook's labels beside numeric codes with an exact-match VLOOKUP, so tables and figures read in words while the codes stay in place for the statistics package.
  • Surface every participant ID that matches nothing on the other sheet with XLOOKUP's if-not-found argument and IFERROR, and count those rows before the merged table is trusted.
  • Keep a lookup pointing at the right variable when a new item column is inserted, by giving XLOOKUP its return column instead of relying on VLOOKUP's column number.
  • Look up an ID wherever its column sits with XLOOKUP or INDEX and MATCH, and read the value where a row and a column meet with a two-way lookup.
  • Build a single key from a participant ID and a visit number with the & operator, and lift a site code out of a composite ID with LEFT, MID and RIGHT, ready to look up.
  • Compare two people's entry of the same forms by bringing one entry beside the other with XLOOKUP and testing them with a TRUE or FALSE comparison.
  • Lock every lookup range with an absolute reference so one formula fills down the whole sample without drifting into errors or zeros.

Projects

What you will build.

The course has 14 industry-standard projects. These two matter most here.

  • Project 06

    PeopleInsight HR workbook

    Employee data joined across sheets with one formula.

    An HR analytics workbook in the course, laid out the way a study file is: a main table of staff records beside department and location lookup tables, where every label you add is fetched from a code and nothing is retyped.

  • Project 12

    SalesFusion

    A sales report that refreshes itself from a folder of files.

    The course's Power Query project, whose merge step performs a lookup on a whole table in one go, the route to take when each wave of a study arrives as its own file.

Tap or pinch to zoom in, drag to move around. Click or scroll to zoom in, drag to move around.

Lessons

The lessons that matter, in course order.

The Complete Excel Course with AI Integration has 186 lessons. This page picks out 9 of them, 37 min of video. Each lesson keeps its number in the course.

Where to start

Lesson 67 Lookup functions in Excel

Start at Lesson 67 if you already write simple formulas and keep your data in tables: the lookups open there with the reason they exist, related data sitting on separate sheets. Lookups lean on locked references, so if F4 and a fixed range are unfamiliar, take Lesson 10 first, and if formulas themselves are new territory, the course's opening lessons from Lesson 1 come before both. Already fluent in VLOOKUP? Jump to Lesson 69 for XLOOKUP and carry on to INDEX and MATCH.

9 of 186 lessons · 37 min

01 Microsoft Excel fundamentals: building a foundation from scratch 1 of 13 lessons · 3 min Absolute and mixed references, with F4 to fix a range in place: the lock that stops a lookup table sliding down the sheet while one formula fills a whole sample. Its practice sheet is a personal budget.
  1. 10 Relative vs absolute references in Excel Dollar signs and mixed references 3 min
08 Advanced Excel functions: lookups, text and arrays 5 of 12 lessons · 21 min The lookups themselves, on an HR dataset whose main sheet meets department and location lookup sheets: why lookups beat copying between tabs, VLOOKUP with an exact match, XLOOKUP with its if-not-found answer and a two-way lookup, IFERROR for codes that fail to match, and INDEX with MATCH where VLOOKUP's limits bite.
  1. 67 Start here Lookup functions in Excel The PeopleInsight HR dataset and why lookups matter 2 min
  2. 68 VLOOKUP in Excel Find employee data across sheets with exact match 4 min
  3. 69 XLOOKUP in Excel Exact match, if not found and two-way lookup 6 min
  4. 70 IFERROR in Excel Handle lookup errors in VLOOKUP and XLOOKUP formulas 3 min
  5. 71 INDEX and MATCH in Excel A flexible alternative to VLOOKUP 6 min
08 Advanced Excel functions: lookups, text and arrays 2 of 12 lessons · 10 min Keys and codes: CONCAT, TEXTJOIN and the & operator to join pieces of text, and LEFT, RIGHT and MID to take a code apart, the two moves that build a lookup key or recover a site code from a composite ID.
  1. 72 CONCAT and TEXTJOIN in Excel Combine employee names and text with a delimiter 3 min
  2. 73 LEFT, RIGHT and MID in Excel Extract parts of a text code like DAL-SAL-0001 7 min
08 Advanced Excel functions: lookups, text and arrays 1 of 12 lessons · 3 min A Ninja Challenge on an orders sheet and a products sheet: XLOOKUP by product ID for each name and its per-unit figure, a calculated total and a reformatted order ID, solved alone first and then checked against the solution file.
  1. 78 Excel Ninja Challenge XLOOKUP, totals and text concatenation lookup challenge 3 min

Instructors

Who teaches it.

Virginia Thorn smiling at the camera, dark hair tied back, wearing a navy top.

Instructor, Excel with AI

Virginia Thorn

Emmy Award winner. Teaches Excel with AI at Coding Liquids.

Questions

Asked before starting.

Now that XLOOKUP exists, does a researcher still need VLOOKUP, and which course teaches both for linking study sheets?

Yes, both earn their place, and The Complete Excel Course with AI Integration from Coding Liquids puts them side by side on one dataset. XLOOKUP is the one to write in your own files: it matches exactly unless told otherwise, finds an ID wherever its column sits and keeps pointing at the right variable when a column is inserted (Lesson 69). VLOOKUP is the one you will meet in files a supervisor, a lab or an earlier project made, and the one that still works when a co-author opens the workbook in an older Excel without XLOOKUP (Lesson 68). INDEX paired with MATCH (Lesson 71) rounds out the trio. All of them run on PeopleInsight, an industry-standard HR workbook whose main table meets department and location lookup sheets, the shape of a dataset beside its codebook. The 9 lessons of this path take 37 minutes, and they finish with a lookup challenge you solve on your own before any study data depends on it.

Can XLOOKUP bring several variables for each participant across from another sheet?

Yes: one XLOOKUP per variable, written once and copied across the row. The Complete Excel Course with AI Integration does exactly this in Lesson 69, where a location code in the main table brings back city, state, region and work arrangement from a lookup sheet, the formula copied across with its return range moved one column at a time and the lookup value reset to the code column after the copy shifts it. Swap the location code for a participant ID and the lookup sheet for your screening sheet, and age group, condition, site and consent date arrive beside every row of the outcome sheet. The lesson also names the slip that spoils a merge: errors or zeros lower down usually mean a range that was not locked with F4 before the formula was filled down. With every column in, the merged sheet holds one complete row per participant, ready for counts, charts or a statistics package.

My data holds numeric codes from a codebook: can lookups add the labels without retyping anything?

Yes: a codebook set out as a small table of codes and labels is exactly what a lookup reads. The Complete Excel Course with AI Integration teaches the pattern in Lesson 68, where each employee's department ID, a short code, is looked up in a department table and returns the department's full name, then the name of its HR business partner from the next column along. In a study, 1 in the condition column becomes Intervention, 2 becomes Control, and a site number becomes the site's name, each label pulled in beside the code rather than typed over it. Keep both columns: the labels make tables and charts readable, while the codes stay exactly as your analysis software expects them. Correct a label once in the codebook sheet and every row that uses it follows, which keeps one wording across a whole thesis and its appendices.

What happens when a participant ID on one sheet has no match on the other?

You see it at once, as a message you chose, instead of a silent gap. The Complete Excel Course with AI Integration teaches both ways to get there. XLOOKUP has an if-not-found argument of its own, set to n/a in Lesson 69, so a missing match reads as a word rather than an error. Lesson 70 breaks a code on purpose to show how little it takes, a single extra letter, then wraps VLOOKUP in IFERROR so the cell reads NOT MATCHED. In research these flags are findings in their own right: an ID typed one way in the screening log and another way in the lab sheet, a participant who withdrew, a sample that never came back. Count the flags with COUNTIF (Lesson 36) before the merged table is trusted, and read each one before deciding whether it is a typing error to correct or a record that genuinely has no partner.

If I insert a new item column into a questionnaire sheet, will my lookups break?

XLOOKUP carries on unharmed, and The Complete Excel Course with AI Integration shows you exactly why VLOOKUP would not. In Lesson 68 a column is inserted into the lookup table on purpose and the VLOOKUP results change at once, because VLOOKUP counts its way to the answer by column number and the count now lands on a different column. The lesson undoes the insert, and Lesson 69 shows the cure: XLOOKUP is handed the column to return, not a number, so an inserted column shifts nothing it relies on. For a researcher this is no small point. Instruments gain items and derived scores between waves, and a VLOOKUP left counting the old way can bring back the wrong variable for every participant without a single error to warn you. Write new lookups with XLOOKUP, and check any inherited VLOOKUP whenever its sheet's columns move.

How does the course make sure a lookup never hands a participant someone else's data?

With an exact match and a locked range, both taught from the very first lookup in The Complete Excel Course with AI Integration. In Lesson 68 the last argument of VLOOKUP is set to FALSE, which demands an exact match: left out, VLOOKUP falls back on an approximate match that can return a neighbouring row's values without raising any error at all. In Lesson 69 XLOOKUP is given 0, its exact-match setting and its default. The second safeguard is the lock: the lookup table is fixed with F4 so it cannot slide as the formula fills down, and the lessons teach you to read errors or zeros lower in the column as the sign that it did. With exact matching and locked ranges together, each participant can only ever receive their own record, which is the whole point of a merge you will one day describe in a methods section.

My participant ID is not in the first column of the sheet: can I still look it up?

Yes: XLOOKUP and INDEX with MATCH both find an ID wherever its column sits, and The Complete Excel Course with AI Integration teaches the problem along with both answers. VLOOKUP searches only from its first column rightwards, so an ID kept in the third column of a lab export defeats it. XLOOKUP (Lesson 69) takes the column to search and the column to return separately, so it reads to the left as readily as to the right. INDEX with MATCH (Lesson 71) reaches the same result in two steps: MATCH finds the position of the row where the ID sits, and INDEX returns the value in that row of whichever column you name. The lesson writes it against named tables, with an @ reference that takes the current row's ID. INDEX and MATCH also work in older versions of Excel, so a workbook shared with a collaborator who has not upgraded keeps working.

Can a lookup read a reference table laid out as a grid, such as conversion factors by analyte and unit?

Yes: that is a two-way lookup, and the XLOOKUP lesson of The Complete Excel Course with AI Integration includes one (Lesson 69). A two-way lookup finds the value where a row and a column meet: one match picks the row, the other picks the column, and the cell at the crossing comes back. Research is full of such grids, conversion factors by analyte and unit, a scoring key by item and response, a reference value by group and measure, and a two-way lookup reads them as they stand instead of forcing them into one long column first. INDEX with MATCH (Lesson 71) is the other way to read a grid, since INDEX accepts a row number and a column number together. A table of cut-offs written as ranges calls for an approximate match, which the lessons leave aside; for grids of exact labels, both methods are in your hands.

Each participant has a row per visit: how do I build a key that lets a lookup find one particular visit?

By joining the participant ID and the visit number into one key that names both. The Complete Excel Course with AI Integration teaches the two pieces. Lesson 72 joins text with CONCAT, TEXTJOIN and the & operator, which builds that key in a helper column, made the same way on both sheets so the two always agree. XLOOKUP (Lesson 69) then finds that key and returns the visit's result, its if-not-found answer marking a visit that never took place. Where the visit is buried inside a longer code, LEFT, RIGHT and MID (Lesson 73) lift it out first, as the lesson does with a three-part position code. XLOOKUP's option to search upwards from the last row, handy for the latest visit, is not a lesson of the course; FILTER (Lesson 76) lists every visit of one participant instead, in a modern Excel, which serves the same review.

Can lookups help me verify double data entry, where two people keyed the same forms?

Yes: bring the second entry beside the first by participant ID and let a comparison mark every disagreement. The Complete Excel Course with AI Integration supplies each step. XLOOKUP (Lesson 69) fetches the second person's value for the same ID and variable onto the first person's sheet. A comparison of the two cells returns TRUE where they agree and FALSE where they do not (Lesson 28), and COUNTIF on that column (Lesson 36) totals the disagreements, so you know the size of the problem before reading a single form. Text compared this way ignores capitals, so male and Male agree, which suits labels; numbers must match exactly. Any ID that the lookup cannot find on the second sheet is itself a discrepancy, flagged by the if-not-found answer. Every FALSE then sends you back to the paper form, which is the purpose of entering the data twice.

Our study's waves arrive as separate files: are lookups enough, or do I need Power Query?

Lookups handle the join inside one workbook, and The Complete Excel Course with AI Integration adds Power Query for the files that keep arriving. Within a workbook, XLOOKUP (Lesson 69) brings baseline values beside follow-up outcomes one column per variable, and the formulas recalculate the moment a value changes. When every wave comes as its own export, the same join is better made a single time for the entire table: Power Query's merge (Lesson 163) attaches names to codes from a lookup table without dropping any row of the main one, and in the SalesFusion project the whole pipeline runs again on refresh. Many researchers use both, Power Query to stack and clean the files, lookups to add a codebook label or a single value on the sheet itself. Both tools are taught in the one course, so the choice can follow the data rather than your training.

I have never written a lookup: what should I be comfortable with before these lessons?

Two things, both taught earlier in The Complete Excel Course with AI Integration, and a third that helps. The first is the locked reference: a lookup's table must stay put while the formula fills down, and Lesson 10 shows the F4 key that fixes a range in place and the drift that happens without it. The second is the Excel table, used throughout the lookup lessons: Lesson 19 creates and formats one and introduces the structured references that INDEX and MATCH later rely on. The third is IFERROR, met first on everyday errors in Lesson 12 before Lesson 70 applies it to lookups. With those in place, the section opens gently: Lesson 67 explains why lookups exist before any formula is typed, and every lesson after it adds a single function, so nothing arrives before you are ready for it.

Which lessons must I finish before I can merge a second questionnaire into my main sheet?

Lesson 68 and Lesson 69, with Lesson 10 first if a locked range is new to you; the whole path runs to 37 minutes, and the merge is ready well before its end. In The Complete Excel Course with AI Integration the first working lookup arrives in Lesson 68, and by the close of Lesson 69 you can bring any number of columns across from a second sheet by ID, with unmatched IDs marked. Lesson 70 adds the IFERROR wrapper for VLOOKUP formulas, and Lesson 71 the INDEX and MATCH alternative, so the merge can be checked a second way. Build the merge on your own two sheets lesson by lesson: the PeopleInsight files show every step, and the completed workbook is there to check your result against. The Ninja Challenge at Lesson 78 then sets a fresh lookup task to solve alone, the best proof that the skill is yours before real data counts. With lifetime access, the lessons stay within reach for the next instrument and the next wave.

Does PeopleInsight's layout of a main table beside lookup sheets match the way a study file is organised?

Closely, which is why it teaches lookups so well. PeopleInsight in The Complete Excel Course with AI Integration keeps its records the way a study does: a main table with one row per person and an ID for each, separate sheets of compensation and engagement survey data, and two lookup tables of departments and locations that play the part of a codebook (Lesson 67). Its position codes pack location, department and number into one string, as a composite participant ID packs site and sequence (Lesson 73). Like every project in the course, it was designed after talking with people from many different industries, so its sheets look like files that working teams keep rather than a classroom example. Replace staff with participants, departments with conditions and locations with sites, and each formula carries straight over to your own data.

Excel with AI

See the whole course.

The Complete Excel Course with AI Integration: 16 hours of video in 186 lessons, built around 14 industry-standard projects, with lifetime access, a Certificate of Completion and a 14-day money-back guarantee.