Hello All, I need your assistance. See the tables below. So, I need to extract a unique list of vendor codes from the "DATA" below based on their area codes. Then, I need to sum the values under "Presence" corresponding to the vendor codes. The cell (B1) next to "Area Code" below is where I would enter the area code for which I would like to extract a unique list of vendor codes as well as their presence.The result of the area code SADF is illustrated below. I very much appreciate your time and effort in helping me out.
[TABLE="width: 223"]
<tbody>[TR]
[TD="colspan: 3"]DATA
Sheet1
A B C[/TD]
[/TR]
[TR]
[TD]Area Code[/TD]
[TD]Vendor Code[/TD]
[TD]Presence[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]1F090[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]1F090[/TD]
[TD="align: right"]0[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]1F090[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]2N031[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]9D001[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]2N031[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]9D001[/TD]
[TD="align: right"]0[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]1F090[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]FADR[/TD]
[TD]1F090[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]FADR[/TD]
[TD]1F090[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]FADR[/TD]
[TD]4R023[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]FADR[/TD]
[TD]1F090[/TD]
[TD="align: right"]0[/TD]
[/TR]
[TR]
[TD]CAER[/TD]
[TD]4R023[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]CAER[/TD]
[TD]5TA90[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]CAER[/TD]
[TD]5TA90[/TD]
[TD="align: right"]0[/TD]
[/TR]
[TR]
[TD]CAER[/TD]
[TD]2S0TY[/TD]
[TD="align: right"]1[/TD]
[/TR]
</tbody><colgroup><col><col><col></colgroup>[/TABLE]
[TABLE="width: 176"]
<tbody>[TR]
[TD="colspan: 2"]RESULT
Sheet 2
A B[/TD]
[/TR]
[TR]
[TD]Area Code:[/TD]
[TD]SADF[/TD]
[/TR]
[TR]
[TD] [/TD]
[TD] [/TD]
[/TR]
[TR]
[TD]Vendor Code[/TD]
[TD]Presence[/TD]
[/TR]
[TR]
[TD]1F090[/TD]
[TD="align: right"]3[/TD]
[/TR]
[TR]
[TD]2N031[/TD]
[TD="align: right"]2[/TD]
[/TR]
[TR]
[TD]9D001[/TD]
[TD="align: right"]1[/TD]
[/TR]
</tbody><colgroup><col span="2"></colgroup>[/TABLE]
[TABLE="width: 223"]
<tbody>[TR]
[TD="colspan: 3"]DATA
Sheet1
A B C[/TD]
[/TR]
[TR]
[TD]Area Code[/TD]
[TD]Vendor Code[/TD]
[TD]Presence[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]1F090[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]1F090[/TD]
[TD="align: right"]0[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]1F090[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]2N031[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]9D001[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]2N031[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]9D001[/TD]
[TD="align: right"]0[/TD]
[/TR]
[TR]
[TD]SADF[/TD]
[TD]1F090[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]FADR[/TD]
[TD]1F090[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]FADR[/TD]
[TD]1F090[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]FADR[/TD]
[TD]4R023[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]FADR[/TD]
[TD]1F090[/TD]
[TD="align: right"]0[/TD]
[/TR]
[TR]
[TD]CAER[/TD]
[TD]4R023[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]CAER[/TD]
[TD]5TA90[/TD]
[TD="align: right"]1[/TD]
[/TR]
[TR]
[TD]CAER[/TD]
[TD]5TA90[/TD]
[TD="align: right"]0[/TD]
[/TR]
[TR]
[TD]CAER[/TD]
[TD]2S0TY[/TD]
[TD="align: right"]1[/TD]
[/TR]
</tbody><colgroup><col><col><col></colgroup>[/TABLE]
[TABLE="width: 176"]
<tbody>[TR]
[TD="colspan: 2"]RESULT
Sheet 2
A B[/TD]
[/TR]
[TR]
[TD]Area Code:[/TD]
[TD]SADF[/TD]
[/TR]
[TR]
[TD] [/TD]
[TD] [/TD]
[/TR]
[TR]
[TD]Vendor Code[/TD]
[TD]Presence[/TD]
[/TR]
[TR]
[TD]1F090[/TD]
[TD="align: right"]3[/TD]
[/TR]
[TR]
[TD]2N031[/TD]
[TD="align: right"]2[/TD]
[/TR]
[TR]
[TD]9D001[/TD]
[TD="align: right"]1[/TD]
[/TR]
</tbody><colgroup><col span="2"></colgroup>[/TABLE]