Thread: array search
View Single Post
  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default array search

Tinkered with 2 other result variations for you to try out over there

This will return the matched results in ascending order from right to left
Array-entered in S26, copied to U26:
=SMALL(IF(COUNTIF($P26:$R26,OFFSET($A25,-(SUM($Q25:$R25)+1),$P25,3,3))*OFFSET($A25,-(SUM($Q25:$R25)+1),$P25,3,3)0,COUNTIF($P26:$R26,O FFSET($A25,-(SUM($Q25:$R25)+1),$P25,3,3))*OFFSET($A25,-(SUM($Q25:$R25)+1),$P25,3,3)),COLUMNS($A:A))

Above returns #NUM! if element in P26:R26 is unmatched

This will return the matched results in descending order from right to left
Array-entered in S26, copied to U26:
=LARGE(COUNTIF($P26:$R26,OFFSET($A25,-(SUM($Q25:$R25)+1),$P25,3,3))*OFFSET($A25,-(SUM($Q25:$R25)+1),$P25,3,3),COLUMNS($A:A))

ABove returns zero if element in P26:R26 is unmatched

NB: Array-entered means press CTRL+SHIFT+ENTER to confirm the formula
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:22,500 Files:370 Subscribers:66
xdemechanik
---