A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » General Discussion
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

VLOOKUP several conditions



 
 
Thread Tools Display Modes
  #1  
Old June 12th, 2004, 05:39 AM
Ron H
external usenet poster
 
Posts: n/a
Default VLOOKUP several conditions

I have two worksheets, one with customer data and financial data, and a
second with salesperson information. I need to "import" the
salesperson from the second worksheet into the first worksheet.

Worksheet 1:
Col A Customer Last Name
Col B First Name
Col C Date
Col D Part Number
Remaining columns have financial info


Worksheet 2:
Col A Customer Last Name
Col B First Name
Col C Date
Col D Part Number
Col E Salesperson


I want to have the appropriate salesperson for each sale shown in
Worksheet 1.

There are a few minor problems.
1) Customer last names are sometimes repeated and are not unique.
2) Date of sale is not unique
3) There is no consistency between the two sheets for the column of
customer first name. In one sheet you may have a customer middle
initial or middle name in the column for "First Name"

I though that if I can nest a VLOOKUP it matches a column A, C, and D
from Worksheet 1 to the salesman in Worksheet 2, and places that
salesperson in a new column it may work, but have been unsuccessful.

Any thoughts?


---
Message posted from http://www.ExcelForum.com/

  #2  
Old June 12th, 2004, 05:51 AM
Frank Kabel
external usenet poster
 
Posts: n/a
Default VLOOKUP several conditions

Hi
try the following array formula (entered with CTRL+SHIFT+ENTER):
=INDEX('sheet2'!$E$1:$E$100,MATCH(1,('sheet2'!$A$1 :$A$100=A1)*('sheet2'
!$C$1:$C$100=C1)*('sheet2'!$D$1:$D$100=D1),0))




--
Regards
Frank Kabel
Frankfurt, Germany


I have two worksheets, one with customer data and financial data, and
a second with salesperson information. I need to "import" the
salesperson from the second worksheet into the first worksheet.

Worksheet 1:
Col A Customer Last Name
Col B First Name
Col C Date
Col D Part Number
Remaining columns have financial info


Worksheet 2:
Col A Customer Last Name
Col B First Name
Col C Date
Col D Part Number
Col E Salesperson


I want to have the appropriate salesperson for each sale shown in
Worksheet 1.

There are a few minor problems.
1) Customer last names are sometimes repeated and are not unique.
2) Date of sale is not unique
3) There is no consistency between the two sheets for the column of
customer first name. In one sheet you may have a customer middle
initial or middle name in the column for "First Name"

I though that if I can nest a VLOOKUP it matches a column A, C, and D
from Worksheet 1 to the salesman in Worksheet 2, and places that
salesperson in a new column it may work, but have been unsuccessful.

Any thoughts?


---
Message posted from http://www.ExcelForum.com/


  #3  
Old June 12th, 2004, 06:32 AM
Ron H
external usenet poster
 
Posts: n/a
Default VLOOKUP several conditions

Frank,
I neglected to tell you I have column headings.
When I pasted your function into E2 in my Worksheet 1, I got the text
value for the header of the column E.

I changed your forumula to start at row 2

=INDEX('sheet2'!$E$2:$E$100,MATCH(1,('sheet2'!$A$2 :$A$100=A2)*('sheet2'!$C$2:$C$100=C2)*('sheet2'!$D $2:$D$100=D2),0))

but got ##N/A

Help!




Frank Kabel wrote:
*Hi
try the following array formula (entered with CTRL+SHIFT+ENTER):
=INDEX('sheet2'!$E$1:$E$100,MATCH(1,('sheet2'!$A$1 :$A$100=A1)*('sheet2'
!$C$1:$C$100=C1)*('sheet2'!$D$1:$D$100=D1),0))




--
Regards
Frank Kabel
Frankfurt, Germany


I have two worksheets, one with customer data and financial data,

and
a second with salesperson information. I need to "import" the
salesperson from the second worksheet into the first worksheet.

Worksheet 1:
Col A Customer Last Name
Col B First Name
Col C Date
Col D Part Number
Remaining columns have financial info


Worksheet 2:
Col A Customer Last Name
Col B First Name
Col C Date
Col D Part Number
Col E Salesperson


I want to have the appropriate salesperson for each sale shown in
Worksheet 1.

There are a few minor problems.
1) Customer last names are sometimes repeated and are not unique.
2) Date of sale is not unique
3) There is no consistency between the two sheets for the column

of
customer first name. In one sheet you may have a customer middle
initial or middle name in the column for "First Name"

I though that if I can nest a VLOOKUP it matches a column A, C, and

D
from Worksheet 1 to the salesman in Worksheet 2, and places that
salesperson in a new column it may work, but have been

unsuccessful.

Any thoughts?


---
Message posted from http://www.ExcelForum.com/ *



---
Message posted from http://www.ExcelForum.com/

  #4  
Old June 12th, 2004, 06:37 AM
Ron H
external usenet poster
 
Posts: n/a
Default VLOOKUP several conditions

HOLD ON FRANK!

I think it works.
I have some data on worksheet 1 that is not on worksheet 2; I think
that was the problem.


---
Message posted from http://www.ExcelForum.com/

  #5  
Old June 12th, 2004, 06:44 AM
Ron H
external usenet poster
 
Posts: n/a
Default VLOOKUP several conditions

HOLD ON FRANK!

I think it works.
I have some data on worksheet 1 that is not on worksheet 2; I think
that was the problem.


---
Message posted from http://www.ExcelForum.com/

  #6  
Old June 12th, 2004, 08:22 AM
Frank Kabel
external usenet poster
 
Posts: n/a
Default VLOOKUP several conditions

Hi
yes, in this case you get a #NA error :-)

--
Regards
Frank Kabel
Frankfurt, Germany


HOLD ON FRANK!

I think it works.
I have some data on worksheet 1 that is not on worksheet 2; I think
that was the problem.


---
Message posted from http://www.ExcelForum.com/

  #7  
Old June 13th, 2004, 08:33 AM
Aladin Akyurek
external usenet poster
 
Posts: n/a
Default VLOOKUP several conditions

See also:

http://tinyurl.com/2yvn2

"Ron H " wrote in message
...
I have two worksheets, one with customer data and financial data, and a
second with salesperson information. I need to "import" the
salesperson from the second worksheet into the first worksheet.

Worksheet 1:
Col A Customer Last Name
Col B First Name
Col C Date
Col D Part Number
Remaining columns have financial info


Worksheet 2:
Col A Customer Last Name
Col B First Name
Col C Date
Col D Part Number
Col E Salesperson


I want to have the appropriate salesperson for each sale shown in
Worksheet 1.

There are a few minor problems.
1) Customer last names are sometimes repeated and are not unique.
2) Date of sale is not unique
3) There is no consistency between the two sheets for the column of
customer first name. In one sheet you may have a customer middle
initial or middle name in the column for "First Name"

I though that if I can nest a VLOOKUP it matches a column A, C, and D
from Worksheet 1 to the salesman in Worksheet 2, and places that
salesperson in a new column it may work, but have been unsuccessful.

Any thoughts?


---
Message posted from http://www.ExcelForum.com/



 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


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


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