How to use PROCV to search for code in two spreadsheets?

Asked

Viewed 123 times

0

In Excel 365, version 1907, and Windows 10, I have an XLSX file with two almost equal sheets - Sheet 1 and Sheet 2.

Contents of the Spreadsheet1:

inserir a descrição da imagem aqui

Contents of the Spreadsheet2:

inserir a descrição da imagem aqui

I want to check in Worksheet 2 if the numbers of "doc" exist in Worksheet 1

So I did so in a new column in Spreadsheet 2:

=SEERRO(PROCV(B2;Planilha1!A$2:B$5;2;FALSO); "Não")

But all results appear as "No", although three codes in "doc" exist in both worksheets

Please, someone knows what could be wrong?

1 answer

2


You are using the references and the wrong form, see the result in the image below.

1) Consider having worksheet 2 active, which you want to put the formula in cell C3;

2) You start by writing in C3 "=SEERRO(PROCV(", select in worksheet 2 cell B3, as you want to start your search from that cell;

3) Go to worksheet 1 and select the entire B column, as this is where the searched data is. At this point the form will look like this: "=SEERRO(PROCV(B3;Planilha1! B:B;"...

4) Note that you have selected only column B on sheet 1, so your index starts at 1 (you have written 2 in your formula).

5) Then then continue the writing of your formula which should be so:

=SEERRO(PROCV(B3;Planilha1!B:B;1;FALSO); "Não")

inserir a descrição da imagem aqui

Browser other questions tagged

You are not signed in. Login or sign up in order to post.