# Help with =SUMIF or =IF

1. ## Help with =SUMIF or =IF

Evening,

I am trying to find a formula that auto-sums a value based on matching numbers in 2 seperate columns, if the number appears more than once the value multiples accordingly.

Column A has only 18 random numbers A1:A18, Column B has 1-100 random numbers B1:B100, Column C has the \$ value of 1-100 numbers in B1:B100, Column D1:D100 then sums C1:C100 based on matching numbers in A:A & B:B once, twice or however many.

I tried =IF and it will SUM once but not any more a number shows up more than once in A1:A18.

Thanks for any assistance  Register To Reply

2. ## Re: Help with =SUMIF or =IF

Change the 94 in B1 to general, not text. then use:

=IF(ISNUMBER(MATCH(B1,\$A\$1:\$A\$18,0)),C1,"")  Register To Reply

3. ## Re: Help with =SUMIF or =IF

Thanks Glenn for the quick response

This formula is works great but the number 94 shows 3 times in A1:A18 how do I capture that so the total sum is \$6 not just \$2  Register To Reply

4. ## Re: Help with =SUMIF or =IF

That wasn't clear from col D, which I assumed was your expected answer.

=IF(ISNUMBER(MATCH(B1,\$A\$1:\$A\$18,0)),C1*COUNTIF(A:A,B1),"")  Register To Reply

5. ## Re: Help with =SUMIF or =IF

Awesome Glenn thanks for that sorry about lack of clarity but much appreciated for your assistance  Register To Reply

6. ## Re: Help with =SUMIF or =IF

You're welcome.

It'd also be appreciated if you were to click the Add Reputation button at the foot of any of the posts of all members who helped you reach a solution.  Register To Reply