#1   Report Post  
Gary T
 
Posts: n/a
Default Double lookup

Hi,

In Sheet 1, I have the following:

Employee Number Start Date Text
840320 01/01/2005 Temporary
810324 05/06/2004 Permanent
320567 02/06/2003 Manual

These are in columns A, B and C, and there are 1050 entries, which are
entered down to row 1051.

In sheet 2, in column A I want to enter an employee number, and in column B
I want to enter a start date. Then in column C I want to be able to display
the appropriate text string ONLY if there is a match for both employee and
Start Date.

So, for example, if I put in "810324" as the employee number in A1 on Sheet
2, and "05/06/2004" in B1 on Sheet 2, In C1 the formula would display
"Permanent", as there was a match.

However, if I put in "810324" in A2 on Sheet 2, and "02/06/2003" in B2 on
Sheet 2, C1 would display "No match" as there was no match.

Many Thanks,

Gary Thomson
  #2   Report Post  
Melissa
 
Posts: n/a
Default

In column C of your Sheet2, use:
=IF(B1=VLOOKUP(A1,Sheet1!$A$1:$C$3,2,FALSE),VLOOKU P(B1,Sheet1!$B$1:$C$3,2,FALSE),"No Match")

"Gary T" wrote:

Hi,

In Sheet 1, I have the following:

Employee Number Start Date Text
840320 01/01/2005 Temporary
810324 05/06/2004 Permanent
320567 02/06/2003 Manual

These are in columns A, B and C, and there are 1050 entries, which are
entered down to row 1051.

In sheet 2, in column A I want to enter an employee number, and in column B
I want to enter a start date. Then in column C I want to be able to display
the appropriate text string ONLY if there is a match for both employee and
Start Date.

So, for example, if I put in "810324" as the employee number in A1 on Sheet
2, and "05/06/2004" in B1 on Sheet 2, In C1 the formula would display
"Permanent", as there was a match.

However, if I put in "810324" in A2 on Sheet 2, and "02/06/2003" in B2 on
Sheet 2, C1 would display "No match" as there was no match.

Many Thanks,

Gary Thomson

  #3   Report Post  
Roger Govier
 
Posts: n/a
Default

Hi Gary
One way
=IF(SUMPRODUCT(--(Sheet1!$A$2:$A$1051=A1),--(Sheet1!$B$2:$B$1051=B1))0,"Permanent","No
Match")

--
Regards
Roger Govier
"Gary T" wrote in message
...
Hi,

In Sheet 1, I have the following:

Employee Number Start Date Text
840320 01/01/2005 Temporary
810324 05/06/2004 Permanent
320567 02/06/2003 Manual

These are in columns A, B and C, and there are 1050 entries, which are
entered down to row 1051.

In sheet 2, in column A I want to enter an employee number, and in column
B
I want to enter a start date. Then in column C I want to be able to
display
the appropriate text string ONLY if there is a match for both employee and
Start Date.

So, for example, if I put in "810324" as the employee number in A1 on
Sheet
2, and "05/06/2004" in B1 on Sheet 2, In C1 the formula would display
"Permanent", as there was a match.

However, if I put in "810324" in A2 on Sheet 2, and "02/06/2003" in B2 on
Sheet 2, C1 would display "No match" as there was no match.

Many Thanks,

Gary Thomson



  #4   Report Post  
bj
 
Posts: n/a
Default

two common ways to do this.

Use a helper column with =A1&B1
and use a lookup based on the concatination

Second use sumproduct()
=sumproduct(--(A1:A1050=number),--(B1:B1050=Date),C1:C1050)
the --( is to change a logical true false to a numeric 1,0 and the arrays in
each section must be the same size, and cannot be shorthand for entire
columns or rows.

"Gary T" wrote:

Hi,

In Sheet 1, I have the following:

Employee Number Start Date Text
840320 01/01/2005 Temporary
810324 05/06/2004 Permanent
320567 02/06/2003 Manual

These are in columns A, B and C, and there are 1050 entries, which are
entered down to row 1051.

In sheet 2, in column A I want to enter an employee number, and in column B
I want to enter a start date. Then in column C I want to be able to display
the appropriate text string ONLY if there is a match for both employee and
Start Date.

So, for example, if I put in "810324" as the employee number in A1 on Sheet
2, and "05/06/2004" in B1 on Sheet 2, In C1 the formula would display
"Permanent", as there was a match.

However, if I put in "810324" in A2 on Sheet 2, and "02/06/2003" in B2 on
Sheet 2, C1 would display "No match" as there was no match.

Many Thanks,

Gary Thomson

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Lookup Vector > Lookup Value Alec Kolundzic Excel Worksheet Functions 6 June 10th 05 02:14 PM
More help need with my double col lookup function KimberlyC Excel Worksheet Functions 10 April 14th 05 12:26 AM
Lookup function w/Text and Year Josh O. Excel Worksheet Functions 1 February 12th 05 11:27 PM
Double entry lookup Al Eaton Excel Worksheet Functions 2 December 13th 04 03:25 AM
double lookup, nest, or macro? Josef.angel Excel Worksheet Functions 1 October 29th 04 09:50 AM


All times are GMT +1. The time now is 04:51 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"