I'm not entirely sure I follow you but if I do... a simple route would be as follows (avoiding use of Arrays)
Adapt your index key in Column J such that:
J19:
=IF(COUNTA($H19:$I19)=2,SUM(COUNTIF($H$19:$H$495,"<"&$H19),COUNTIF($I$19:$I19,"<="&$I19)/1000),"")
copied down to J495
Then
count of records to be returned
A1: =COUNT($J$19:$J$495)
A2:
=IF(ROWS(A$2:A2)>$A$1,"",INDEX(H$19:H$495,MATCH(SMALL($J$19:$J$495,ROWS(A$2:A2)),$J$19:$J$495,0)))
copied across matrix A2:Bx where x is last row you wish to use
You could also use a Pivot Table...
Bookmarks