# reverse lookup

#### lmcd5666

##### New Member
Hi all,

Hope someone can help.
Situation:
.....A.....B......C......D
1....0.....1......400....0
2....0.....2......300....0
3....0.....3......350....0
4....0.....4......150...150
5....2.....0.......0.....0
6....3.....0.......0.....0
7....1.....0.......0.....0

I need a formula that make values in column D match the value in column C (same row) but only if the value in column B(same row)
is NOT find in column A range. Values in column A are not in any order. Values in column B are in ascending order. If there is a match then the value in column is zero.

As you can see from the above example..D4 equals c4 because there was no matching of B4 in the column A range. The first three row...there are matches, so the values in the D's cells are zero.

Any help would be greatly appreciated.

Toan

### Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop

#### Asala42

##### Well-known Member
Situation:
.....A.....B......C......D
1....0.....1......400....0
2....0.....2......300....0
3....0.....3......350....0
4....0.....4......150...150
5....2.....0.......0.....0
6....3.....0.......0.....0
7....1.....0.......0.....0

I need a formula that make values in column D match the value in column C (same row) but only if the value in column B(same row)
is NOT find in column A range. Values in column A are not in any order. Values in column B are in ascending order. If there is a match then the value in column is zero.

As you can see from the above example..D4 equals c4 because there was no matching of B4 in the column A range. The first three row...there are matches, so the values in the D's cells are zero.

Try:
=IF(Countif(\$A\$2:\$A\$10,B2)>0,0,D2)

#### lmcd5666

##### New Member
Thank you, Asala42. It worked out great.

Replies
6
Views
197
Replies
5
Views
162
Replies
3
Views
173
Replies
13
Views
437
Replies
10
Views
656

Excel contains over 450 functions, with more added every year. That’s a huge number, so where should you start? Right here with this bundle.

1,152,119
Messages
5,768,221
Members
425,460
Latest member
Astros1243

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.

### Which adblocker are you using?

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back