# Sumif columns within a column?

#### tahir9

##### New Member
I have 12 columns that are months and for each month column there are about 7 other columns. I want to sum the column sales within august using a sumifs. But this formula doesn't really work I was wondering if there was another way or if I am using the wrong formula? SUMIFS(INDEX('Burg History_Sale NM'!A9:KX550,,MATCH(\$E\$2,'Burg History_Sale NM'!8:8,0)),'Burg History_Sale NM'!\$8:\$8,\$D\$4), where E2 Is my month cell, and D4 is the cell that contains my column header with my month?

### Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.

#### ExcelMercy

##### Board Regular
I have 12 columns that are months and for each month column there are about 7 other columns.

I'm a little unclear what you're saying.

You have 12 columns: January, February, Match.. etc. And for each of these columns you have 7 other columns? So 84 columns all together?

Could you supply a piece of sample data?

#### tahir9

##### New Member
 August September Sale Inventory Sale Inventory 10 11 10 15 8 10 5 9 2 3 5 6

<tbody>
</tbody>

Sorry I tried to copy and paste date but it looked weird so I just made a sample table on a much smaller scale but it should demonstrate what I am asking.

I want to sum with sale column but only for August or September or any other month depending on the values I want.

#### FDibbins

##### Well-known Member
Seed if this will help. Based on your table (I changed some numbers to differences are more easily seen)...
 A​ B​ C​ D​ E​ F​ G​ 1​ August September August 2​ Sale Inventory Sale Inventory Sales Inv 3​ aa 10 11 11 12 33​ 36​ 4​ bb 11 12 12 13 22​ 24​ 5​ aa 12 13 13 14

F2=SUM(OFFSET(\$A\$1,2,MATCH(\$F\$1,\$B\$1:\$D\$1,0),COUNTA(A:A),1))
This will sum all values in the selected column for Sales
=SUM(OFFSET(\$A\$1,2,MATCH(\$F\$1,\$B\$1:\$D\$1,0)+1,COUNTA(A:A),1))
This will sum all values for the selected month for its 2nd column

F4=SUMIF(\$A\$3:\$A\$5,"aa",OFFSET(\$A\$1,2,MATCH(\$F\$1,\$B\$1:\$D\$1,0),COUNTA(A:A),1))
This will do the same sum, but ONLY for the "aa" items

Again for "aa" for treh 2nd column...
=SUMIF(\$A\$3:\$A\$5,"aa",OFFSET(\$A\$1,2,MATCH(\$F\$1,\$B\$1:\$D\$1,0)+1,COUNTA(A:A),1))

Replies
3
Views
630
Replies
6
Views
255
Replies
3
Views
1K
Replies
12
Views
483
Replies
5
Views
648

1,191,273
Messages
5,985,690
Members
439,974
Latest member
sjoerdbosch

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.

### Which adblocker are you using?

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back