F2 - =LEFT(E2,2)
G2 - =COUNTIFS(F$1:F2,"1-",B$1:B2,B2)
[TABLE="width: 448"]
<colgroup><col width="64" span="7" style="width:48pt"> </colgroup><tbody>[TR]
[TD="class: xl65, width: 64"]Code[/TD]
[TD="class: xl65, width: 64"]Dept[/TD]
[TD="class: xl65, width: 64"]Dept Code[/TD]
[TD="class: xl65, width: 64"]Dept Head[/TD]
[TD="class: xl65, width: 64"]Job Code[/TD]
[TD="class: xl65, width: 64"]left[/TD]
[TD="class: xl65, width: 64"]result[/TD]
[/TR]
[TR]
[TD="class: xl65, width: 64"]1-AR[/TD]
[TD="class: xl65, width: 64"]AR[/TD]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Bob[/TD]
[TD="class: xl65, width: 64"]1-123[/TD]
[TD="class: xl65, width: 64"]1-[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]AR[/TD]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Bob[/TD]
[TD="class: xl65, width: 64"]2-123[/TD]
[TD="class: xl65, width: 64"]2-[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]AR[/TD]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Bob[/TD]
[TD="class: xl65, width: 64"]3-123[/TD]
[TD="class: xl65, width: 64"]3-[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]AR[/TD]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Bob[/TD]
[TD="class: xl65, width: 64"]4-123[/TD]
[TD="class: xl65, width: 64"]4-[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl65, width: 64"]2-AR[/TD]
[TD="class: xl65, width: 64"]AR[/TD]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Bob[/TD]
[TD="class: xl65, width: 64"]1-677[/TD]
[TD="class: xl65, width: 64"]1-[/TD]
[TD="align: right"]2[/TD]
[/TR]
[TR]
[TD="class: xl65, width: 64"]3-AR[/TD]
[TD="class: xl65, width: 64"]AR[/TD]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Bob[/TD]
[TD="class: xl65, width: 64"]1-789[/TD]
[TD="class: xl65, width: 64"]1-[/TD]
[TD="align: right"]3[/TD]
[/TR]
[TR]
[TD="class: xl65, width: 64"]4-AR[/TD]
[TD="class: xl65, width: 64"]AR[/TD]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Bob[/TD]
[TD="class: xl65, width: 64"]1-801[/TD]
[TD="class: xl65, width: 64"]1-[/TD]
[TD="align: right"]4[/TD]
[/TR]
[TR]
[TD="class: xl65, width: 64"]1-Retail[/TD]
[TD="class: xl65, width: 64"]Retail[/TD]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Joe[/TD]
[TD="class: xl65, width: 64"]1-875[/TD]
[TD="class: xl65, width: 64"]1-[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]REtail[/TD]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Joe[/TD]
[TD="class: xl65, width: 64"]2-875[/TD]
[TD="class: xl65, width: 64"]2-[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl65, width: 64"]2-Retail[/TD]
[TD="class: xl65, width: 64"]Retial[/TD]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Joe[/TD]
[TD="class: xl65, width: 64"]1-982[/TD]
[TD="class: xl65, width: 64"]1-[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Retail[/TD]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Joe[/TD]
[TD="class: xl65, width: 64"]2-982[/TD]
[TD="class: xl65, width: 64"]2-[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl65, width: 64"]1-Online[/TD]
[TD="class: xl65, width: 64"]Online[/TD]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Amy[/TD]
[TD="class: xl65, width: 64"]1-654[/TD]
[TD="class: xl65, width: 64"]1-[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Online[/TD]
[TD="class: xl65, width: 64"] [/TD]
[TD="class: xl65, width: 64"]Amy[/TD]
[TD="class: xl65, width: 64"]2-654[/TD]
[TD="class: xl65, width: 64"]2-[/TD]
[TD="align: right"]1[/TD]
[/TR]
</tbody>[/TABLE]