ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Returning a text result from 2 lookup columns (https://www.excelbanter.com/excel-discussion-misc-queries/146482-returning-text-result-2-lookup-columns.html)

Sam

Returning a text result from 2 lookup columns
 
Hi,

I'm trying to return a text result based upon a lookup of two columns. For
example, if column A = Medium, Column B = High, I'd like to be able to return
a result in a third column of MH. How can I go about doing this.

Thanks as always,
Sam

Mike H

Returning a text result from 2 lookup columns
 
Sam,

In C1 try:-

=IF(AND(A1="Medium",B1="High"),"MH","")

Mike

"sam" wrote:

Hi,

I'm trying to return a text result based upon a lookup of two columns. For
example, if column A = Medium, Column B = High, I'd like to be able to return
a result in a third column of MH. How can I go about doing this.

Thanks as always,
Sam


Toppers

Returning a text result from 2 lookup columns
 
Are the results always the first letter of each of A & B

if so:

=LEFT(A1,1)& LEFT(B1,1)

"sam" wrote:

Hi,

I'm trying to return a text result based upon a lookup of two columns. For
example, if column A = Medium, Column B = High, I'd like to be able to return
a result in a third column of MH. How can I go about doing this.

Thanks as always,
Sam


David Biddulph[_2_]

Returning a text result from 2 lookup columns
 
=IF(AND(A1="Medium",B1="High"),"MH","output undefined") might be one option.
=LEFT(A1)&LEFT(B1) might be an alternative approach.
You'll have to define what output you want for which inputs.
--
David Biddulph

"sam" wrote in message
...
Hi,

I'm trying to return a text result based upon a lookup of two columns. For
example, if column A = Medium, Column B = High, I'd like to be able to
return
a result in a third column of MH. How can I go about doing this.

Thanks as always,
Sam




Bernard Liengme

Returning a text result from 2 lookup columns
 
This is the data I have in G1:J4 (I did not want to have to scroll all the
way to MN to experiment)
data a b c
x 1 4 7
y 2 5 8
z 3 6 9


In A1 I have the text: y and in B1 the text: b
IN C1 this formula =VLOOKUP(A1,G2:J4,MATCH(B1,G1:J1,0),FALSE)
returns the value 5
best wishes
--
Bernard V Liengme
www.stfx.ca/people/bliengme
remove caps from email

"sam" wrote in message
...
Hi,

I'm trying to return a text result based upon a lookup of two columns. For
example, if column A = Medium, Column B = High, I'd like to be able to
return
a result in a third column of MH. How can I go about doing this.

Thanks as always,
Sam





All times are GMT +1. The time now is 03:00 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com