Well, how many part numbers do you have? If it's just a few, and you don't mind typing them out then you can use SUMIF:

Ex: (This range starts in A1 and ends in B21)

a 2

b 12

uioyu 18

iuy 80

iy 59

uioyu 31

uyi 52

uioyu 24

yui 93

yui 28

iyu 9

iuy 33

yui 8

yui 49

uioyu 81

uyi 41

yui 43

iuy 9

yui 67

a 26

a 86

and using this to find the sum of all occurrences of "a":

=SUMIF(A1:A21,"a",B1:B21)

If you are needing to find all unique part numbers, and then sum them, you can use this array formula:

=IF(ISERROR(INDEX($A$1:$A$21,MATCH(0,COUNTIF($I$1:I1,$A$1:$A$21),0))),"",INDEX($A$1:$A$21,MATCH(0,COUNTIF($I$1:I1,$A$1:$A$21),0)))

Where I1 is the cell directly about where you want the new list of unique part numbers, so then I2 is the beginning of the list of unique part numbers. A1:A21 is the range of all your part numbers.

Make this new list, and then use the SUMIF formula next to each part number, but replace "a" with the corresponding part number next to it.