how to use cell contents as references in a formula

G

Guest

I want to use the EXACT function to compare fixed cell with a variable one.
this is an example
sheet1
A B
orange 45
apple 60

sheet2
A B
banana 50
apple 60
orange 45

my goal is to compare table1 with table2 to make sure that orange is
included in table 2 and return its index which is 3 (row is enough) in this
example, I did this step.
now I want to use EXACT to compare the price of the orange in table1(45)
which is B1 with the price of orange in the second table.
manual formula would be =EXACT(sheet1!B1,sheet2!B3)...
I want to do this automatically, i.e. after finidng the orange and its index
(row number) in the second table using MATCH function, and inserting that
index as a content of C1 for example, I want to EXACT B1 in the first table
with B[content of C1] which will be 3 in this example.
it is complicated to explain but I hope that I made it clear enough.
anyone can help?
 
G

Guest

Hussam 81

I think I understand what you want.

Try typing this into cell C1 on Sheet 1

=EXACT(B1,VLOOKUP(A1,Sheet2!$A$1:$B$3,2))

Here I assume that your Table on Sheet2 is in range A1:B3.

This formula will check what is in column A on sheet 1 (e.g. Oranges), then
find 'Oranges' in Sheet 2 and get the price, and then compare with the price
in Sheet 1.

Is that of any use?

Regards


Alex
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top