TechArena Community How to check if a number belongs to a column or not in Excel

#1
07-04-2009
 Member Join Date: Nov 2008 Posts: 1,221
How to check if a number belongs to a column or not in Excel

I am on Excel. I would just like a formula that might check if a number belongs to a column or not.

Style:

= IF (A1 "is in column B," "YES"; "NO")

The question is: how to translate "belongs to in column B"?
#2
07-04-2009
 Member Join Date: May 2008 Posts: 685
Re: How to check if a number belongs to a column or not in Excel

Good evening

= if (Column (A1) = 2; "Column B", "No column B") <(--- is necessarily the "No column B"...

The function column relates to column number and not the index "B"

To find "B" share a table with a match I can not tell you.

Best regards
#3
07-04-2009
 Member Join Date: Nov 2008 Posts: 1,221
Re: How to check if a number belongs to a column or not in Excel

Hmmm ... I think it does not help me at all.

What is it a match?
#4
07-04-2009
 Member Join Date: May 2008 Posts: 685
Re: How to check if a number belongs to a column or not in Excel

It can not help you at all, yet that is exactly what you require. So may be more accurate ... Because A1, before the cell is in column B, it will rain in a rainstorm ...

As = IF (A1 "is in column B," "YES"; "NO")
and
= if (Column (A1) = 2; "Column B", "No column B")

that's exactly what you want ...
#5
07-04-2009
 Member Join Date: Feb 2008 Posts: 194
Re: How to check if a number belongs to a column or not in Excel

When you speak of A1 is a value to search, or it represents cell A1? A value, I suppose, since you are looking for a value in column B. What I want to do everything really does seem silly.

Let's say in column A, I have the following values:

1 2 3 4 5 6 7 8 9 10

And in column B, I:

3 4 6 8 9

The result in column C would be:

NO NO YES YES NO YES NO YES YES

In column C, for each line in column A, I would like to display "YES" if Ax is also in column B, and "NO" otherwise.

 Tags: excel