English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

I have data in column A, B, and C. I want to search text "X" in column A and search text "Y" in column B, if in the same raw, column A ="X", and column B = "Y", then I want the value of column C. (if "X" and "Y" are not in the same raw, that's not wanted)
Please help!

2007-08-12 15:57:13 · 4 answers · asked by imjscn 1 in Computers & Internet Programming & Design

In Excel, I mean, I don't know any computer language.
Thanks.

2007-08-12 18:57:50 · update #1

Thanks for the first 3 answers! But the problem is not solved yet, --sorry, I didn't make my question clear. Here it is:
A B C D
w xy 1 D1=search A and B to find
x wz 2 "wx", return "3" in D1
y wx 3
z xz 4

2007-08-12 23:50:48 · update #2

4 answers

Assuming u are referring to columns in MS-Excel, then use the following command
=IF(AND(FIND("aa",A2,1)>0, FIND("aa",B2,1)>0),"Yes","No")

Where "aa" -> is the text to be found
Cell Address "A2" is the text in which "aa" is searched
AND(condition1,condition2) gives true if both the conditions are YES, i.e. required text is available in the string being searched.

2007-08-12 22:12:48 · answer #1 · answered by iqbal 4 · 0 0

There are two methods of cell dressing in Excel. One relative and one absolute, you have to select the relative one (as the absolute one is the default). There's some jargon they use for them both. It's some time since I've played with Excel but the switch is in Tools->Options->General and the box is R1C1 and then you can address a column relative to the current column. C[-1] (the last column) or something like that.

2016-05-21 02:56:13 · answer #2 · answered by alene 3 · 0 0

Which language are you using? C? C++?

2007-08-12 16:02:18 · answer #3 · answered by mdigitale 7 · 0 0

I believe you are looking for SQL?

SELECT T.C
FROM TABLE_NAME T
WHERE T.A LIKE "%X%"
AND T.B LIKE "%Y%"

2007-08-12 16:56:27 · answer #4 · answered by Dr Cog 3 · 0 0

fedest.com, questions and answers