Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 10-26-2015, 01:24 AM
xor xor is offline I can do it but I don't know why Windows 10 I can do it but I don't know why Office 2013
Expert
 
Join Date: Oct 2015
Posts: 1,101
xor is a name known to allxor is a name known to allxor is a name known to allxor is a name known to allxor is a name known to allxor is a name known to all
Default

To count the number of common values you can also use the simpler:

=SUM(--(ISNUMBER(MATCH($A$1:$A$12,$B$1:$B$10,0)))) (array-entered)

MATCH($A$1:$A$12,$B$1:$B$10,0) evaluates to:
{10,#N/A,#N/A,5,#N/A,1,2,#N/A,#N/A,#N/A,#N/A,2}
meaning that the first value in A1:A12 is in the tenth position in B1:B10. The values in the second and third value in A1:A12 are not in B1:B10 and so on.

ISNUMBER(MATCH($A$1:$A$12,$B$1:$B$10,0)) evaluates to:


{TRUE,FALSE,FALSE,TRUE,FALSE,TRUE,TRUE,FALSE,FALSE ,FALSE,FALSE,TRUE}
and by double negation (--) these Boolean values are converted from a lot of TRUE, FALSE's to:
{1,0,0,1,0,1,1,0,0,0,0,1}
which inserted in the SUM function returns 5.
Reply With Quote
  #2  
Old 11-06-2015, 04:33 AM
troggot troggot is offline I can do it but I don't know why Windows 7 64bit I can do it but I don't know why Office 2010 64bit
Novice
I can do it but I don't know why
 
Join Date: Oct 2015
Posts: 2
troggot is on a distinguished road
Default

Many thanks for the help and sorry for the delayed answer.
I guess I disabled the automated emails and I still believed no one answered!

Today I checked!
Reply With Quote
Reply



Other Forums: Access Forums

All times are GMT -7. The time now is 04:47 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft