# V Look Up - reading duplicate codes and adding values together.

1. ## V Look Up - reading duplicate codes and adding values together.

Hello,

I was wondering if someone can help me, this is kind of hard to explain.

I'm doing a V Look Up, where I want to look up a SKU in one spreadsheet and transfer the amount across into my other spreadsheet.

However if there are the duplicate codes and values I want it to add the amounts together.

I've attached an example that will hopefully help.

Regards, Kirk.

2. ## Re: V Look Up

• Use concise, accurate thread titles.
• Responding to a request to change your thread title by doing so is mandatory.

To change a title go to your first post, click EDIT then Go Advanced and change your title.

No help to be offered, please, until the OP complies with this request.

3. ## Re: V Look Up

In C2 copied down:

=SUMIFS(Sales!\$C\$2:\$C\$18,Sales!\$A\$2:\$A\$18,Product!A2,Sales!\$B\$2:\$B\$18,Product!B2)

4. ## Re: V Look Up - reading duplicate codes and adding values together.

Hello Ali,

Regards, Kirk.

5. ## Re: V Look Up - reading duplicate codes and adding values together.

Better - thank you.

6. ## Re: V Look Up - reading duplicate codes and adding values together.

Can you help solve my problem?

7. ## Re: V Look Up - reading duplicate codes and adding values together.

Lookup formula
Formula:
`=VLOOKUP(A2&B2,Sales!D:E,2,0)`

Add a couple of helper columns in lookup table
in D2 copied down
Formula:
`=A2&B2`

in E2 copied down
Formula:
`=IF(COUNTIF(D\$2:D2,D2)=1,SUMIF(D:D,D2,C:C),"")`

8. ## Re: V Look Up - reading duplicate codes and adding values together.

Hi Kev and Ali,

I've got it up and running, thank you for all your help.

9. ## Re: V Look Up - reading duplicate codes and adding values together.

You are welcome
Thanks for marking thread as SOLVED