Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default OR Exact statement not working to compare values in two columns

Hi,

I am trying to compare two columns of numbers to see if values in one
column appear in the other.

Given something like the two columns on the left below, I have a thrid
column called "match?" that uses the statement: =OR(EXACT(b2, $a$2:$a
$16)) to compare values in columns.

value 1 value 2 match?
1 5 FALSE
2 3 FALSE
3 1 FALSE
4 2 FALSE
5 4 FALSE

However, the formula is returning FALSE for all comparisons.

Any help on how I can quickly or easily compare values in two columns?
Have a couple of hundred to do, above is just simple illustration.

Thanks in advance,

Lee
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,358
Default OR Exact statement not working to compare values in two columns

On your OR statement, did you enter it as an **array** formula? It looks as
if it should be. Type the formula, then, instead of JUST pressing the ENTER
key, press and hold CTRL+SHIFT+ENTER
--
** John C **

" wrote:

Hi,

I am trying to compare two columns of numbers to see if values in one
column appear in the other.

Given something like the two columns on the left below, I have a thrid
column called "match?" that uses the statement: =OR(EXACT(b2, $a$2:$a
$16)) to compare values in columns.

value 1 value 2 match?
1 5 FALSE
2 3 FALSE
3 1 FALSE
4 2 FALSE
5 4 FALSE

However, the formula is returning FALSE for all comparisons.

Any help on how I can quickly or easily compare values in two columns?
Have a couple of hundred to do, above is just simple illustration.

Thanks in advance,

Lee

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 751
Default OR Exact statement not working to compare values in two columns

It seems you have to array-enter the formula. Double-click the cell
and commit with Shift+Ctrl+Enter.

You can avoid array-entering with the scalar formula

=ISNUMBER(MATCH(b2, $a$2:$a$16, 0))

HTH
Kostis Vezerides

On Oct 30, 6:23*pm, wrote:
Hi,

I am trying to compare two columns of numbers to see if values in one
column appear in the other.

Given something like the two columns on the left below, I have a thrid
column called "match?" that uses the statement: =OR(EXACT(b2, $a$2:$a
$16)) to compare values in columns.

value 1 value 2 match?
1 * * * 5 * * * FALSE
2 * * * 3 * * * FALSE
3 * * * 1 * * * FALSE
4 * * * 2 * * * FALSE
5 * * * 4 * * * FALSE

However, the formula is returning FALSE for all *comparisons.

Any help on how I can quickly or easily compare values in two columns?
Have a couple of hundred to do, above is just simple illustration.

Thanks in advance,

Lee


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4,393
Default OR Exact statement not working to compare values in two columns

Let 1,2,3,4 ... be in column A; and 5,6,7... be in B
Let there be 500 entries
In C1 use =IF(COUNTIF($A$1:$A$500,B1),"Repeated","")

You never need EXACT to compare numbers (only text)
best wishes
--
Bernard V Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme
remove caps from email

wrote in message
...
Hi,

I am trying to compare two columns of numbers to see if values in one
column appear in the other.

Given something like the two columns on the left below, I have a thrid
column called "match?" that uses the statement: =OR(EXACT(b2, $a$2:$a
$16)) to compare values in columns.

value 1 value 2 match?
1 5 FALSE
2 3 FALSE
3 1 FALSE
4 2 FALSE
5 4 FALSE

However, the formula is returning FALSE for all comparisons.

Any help on how I can quickly or easily compare values in two columns?
Have a couple of hundred to do, above is just simple illustration.

Thanks in advance,

Lee



  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,344
Default OR Exact statement not working to compare values in two columns

Hi,

Or just the =COUNTIF(A$1:A$500,B1)

this returns 0 if there are no matches, and a number greater than 0 if there
are matches.


--
Thanks,
Shane Devenshire


" wrote:

Hi,

I am trying to compare two columns of numbers to see if values in one
column appear in the other.

Given something like the two columns on the left below, I have a thrid
column called "match?" that uses the statement: =OR(EXACT(b2, $a$2:$a
$16)) to compare values in columns.

value 1 value 2 match?
1 5 FALSE
2 3 FALSE
3 1 FALSE
4 2 FALSE
5 4 FALSE

However, the formula is returning FALSE for all comparisons.

Any help on how I can quickly or easily compare values in two columns?
Have a couple of hundred to do, above is just simple illustration.

Thanks in advance,

Lee

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
If statement with Vlookup - including ISNA function to compare two columns from different worksheets nakliwala Excel Worksheet Functions 3 September 25th 07 09:30 AM
I want to compare the values in two columns Dr. Darrell Excel Discussion (Misc queries) 4 September 14th 06 02:07 AM
Compare Two Columns (Exact and Wildcard) Xavier Excel Worksheet Functions 4 August 15th 06 06:29 PM
Compare 2 cells values with one IF statement jbsand1001 Excel Worksheet Functions 1 June 9th 05 06:15 PM
Excel Compare values in columns & display missing values in a new cpetta Excel Discussion (Misc queries) 1 April 2nd 05 05:51 AM


All times are GMT +1. The time now is 01:47 AM.

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"