I need to use either sumif or match or whatever using multiple criteria. The
data is on 2 different worksheets.
Each sheet has 4 columns of data: Name, Company, Date, Charge
Because of the sheet layout, I'm not using lables
I need to search the second sheet and add the charges of every row that
matches the Name, Company and Date for each line on the first sheet.
Example: First Sheet
| Name | Company | Date | Charge |
| Joe | Shop | Mar 3 | $100.00 |
| Bill | Office | Mar 3 | $50.00 |
| Tom | Shop | Dec 6 | $100.00 |
Second Sheet
| Joe | Shop | Mar 3 | $25.00 |
| Bill | Office | Dec 6 | $50.00 |
| Joe | Shop | Mar 3 | $75.00 |
| Tom | Shop | Dec 6 | $100.00 |
For the first row of the first sheet, the search will add the charges from
rows 1 amp; 3 on the second sheet because the first three values match.
Any ideas out there?Hi
D2=SUMPRODUCT(--('First Sheet'!$A$2:$A$1000=A2),--('First
Sheet'!$B$2:$B$1000=B2),--('First Sheet'!$C$2:$C$1000=C2),'First
Sheet'!$D$2:$D$1000)
Adjust ranges for your layout, and copy the formula down. You can enchance
the formula above, defining all ranges referred to as dynamic named ranges,
so the formula will adjust automatically whenever rows are added/deleted on
sheet 'First Sheet'.
Arvi Laanemets
quot;Space Elfquot; gt; wrote in message
...
gt; I need to use either sumif or match or whatever using multiple criteria.
The
gt; data is on 2 different worksheets.
gt; Each sheet has 4 columns of data: Name, Company, Date, Charge
gt; Because of the sheet layout, I'm not using lables
gt; I need to search the second sheet and add the charges of every row that
gt; matches the Name, Company and Date for each line on the first sheet.
gt; Example: First Sheet
gt; | Name | Company | Date | Charge |
gt; | Joe | Shop | Mar 3 | $100.00 |
gt; | Bill | Office | Mar 3 | $50.00 |
gt; | Tom | Shop | Dec 6 | $100.00 |
gt; Second Sheet
gt; | Joe | Shop | Mar 3 | $25.00 |
gt; | Bill | Office | Dec 6 | $50.00 |
gt; | Joe | Shop | Mar 3 | $75.00 |
gt; | Tom | Shop | Dec 6 | $100.00 |
gt; For the first row of the first sheet, the search will add the charges from
gt; rows 1 amp; 3 on the second sheet because the first three values match.
gt;
gt; Any ideas out there?
gt;
quot;Space Elfquot; gt; wrote in message
...
gt;I need to use either sumif or match or whatever using multiple criteria.
gt;The
gt; data is on 2 different worksheets.
gt; Each sheet has 4 columns of data: Name, Company, Date, Charge
gt; Because of the sheet layout, I'm not using lables
gt; I need to search the second sheet and add the charges of every row that
gt; matches the Name, Company and Date for each line on the first sheet.
gt; Example: First Sheet
gt; | Name | Company | Date | Charge |
gt; | Joe | Shop | Mar 3 | $100.00 |
gt; | Bill | Office | Mar 3 | $50.00 |
gt; | Tom | Shop | Dec 6 | $100.00 |
gt; Second Sheet
gt; | Joe | Shop | Mar 3 | $25.00 |
gt; | Bill | Office | Dec 6 | $50.00 |
gt; | Joe | Shop | Mar 3 | $75.00 |
gt; | Tom | Shop | Dec 6 | $100.00 |
gt; For the first row of the first sheet, the search will add the charges from
gt; rows 1 amp; 3 on the second sheet because the first three values match.
gt;
gt; Any ideas out there?
Use SUMPRODUCT to test multiple criteria (SUMIF used simply can use only one
criterion).
See this:
www.xldynamic.com/source/xld.SUMPRODUCT.html
Ian
- Oct 18 Sat 2008 20:46
Creating Array formulas with multiple criteria
close
全站熱搜
留言列表
發表留言
留言列表

