Rank duplicate text values in Excel by order of occurrence for unique criteria -


in excel have results data ordered in list similar below. looking formula rank 'class' column. have come following seems work, without considering 'unique' raceid column.

={countif(class,"<"&c2)+sum(if(c2=$c$2:c2, 1, 0))-(sumproduct(--(c2>c$2:c$11))+1)} 

where 'class' refers 'c:c'.

unfortunately produce result of '4' class in cell e7, though daniel race winner raceid 0002.

the fifth column desired output.

col     col b          col c    col d     col e raceid    overall pos    class    name      class rank 0001      1                     jack      1 0001      2                     matt      2 0001      3                     daniel    3 0001      4              b        gordon    1 0001      5              b        phillip   2 0002      1                     daniel    1 0002      2                     matt      2 0002      3              b        günther   1 0002      4              b        gordon    2 0002      5                     jack      3 

what need able extend formula rank when raceid values match current row. i'm sure shouldn't difficult, i'm struggling complete formula.

if got correct, non-array formula do:

=countifs(a:a,a2,b:b,"<"&b2,c:c,c2)+1 

edit

if excel not support countifs formula do:

{=sum(if(($a$1:index(a:a,match("zzz",d:d))=a2)*($c$1:index(c:c,match("zzz",d:d))=c2),$b$1:index(b:b,match("zzz",d:d))<b2)*1)+1} 

this array formula , must confirmed ctrl+shift+enter.


Comments