Yet another vlookup problem

rabarnes

New Member
Joined
Sep 7, 2006
Messages
26
Hi

I'm sure this question has been answered before but I've been wading through all the vlookup posts and can't find the answer. So here goes:

I have a spreadsheet set up with columns as follows:

A. Job number B. Quote Number C. Customer Name D. Material E. Price

I am running a standard vlookup for job number however it returns #N/A when I have the lookup range set to false and the wrong value when it is set to true. My data is arranged in ascending order however the same job number does appear more than once within the data. I'm guessing this is why I'm getting #N/A. An example of columns A and B would be:

Job No ......... Quote No
71300 ......... 1958
71301 ......... 2054
71302 ......... 2068
71302 ......... 2101
71302 ......... 1996
71303 ......... 1759

Quote number (column B) has an individual number each time. I need to use job number however for my lookup. What I want to do is return the values from 1. the job number that i specify and 2. the most recent quote number (the highest value). In other words, if I lookup job number 71302, I want it to return quote number 2101.

Can anyone help me out?

Thanks

Rowan
 

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().
try
Code:
=max(if(G1=a1:a100,b1:b100,0))
confirmed with Ctrl+shift+Enter, where G1 contains the job number you are looking for. The ranges MUST be discreet and the same size... this will return an error if you try to search on the entire column...
 
Upvote 0
Hi,

Try:

=MAX(IF(A2:A7=E2,B2:B7))

Confirmed with Ctrl + shift + enter.

Job number in E2.
 
Upvote 0
Try:

=MAX(($A$2:$A$20=$F$1)*$B$2:$B$20)

Entered with CTRL+SHIFT+ENTER, where A2:A20 is your Job No column and B2:B20 is your Quote No Column and F1 is the Job No you want to look up.
 
Upvote 0

Forum statistics

Threads
1,214,897
Messages
6,122,141
Members
449,066
Latest member
Andyg666

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.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

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

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

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
Back
Top