Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Mark Rucker
 
Posts: n/a
Default Improve SUMIF function to sum more than one column

In using the SUMIF function in Excel, I wanted to sum values in more than one
column, but it would only sum the first column.

Desired Function
=SUMIF(F16:F21,"A",G16:H21)

Workaround
=SUMIF(F16:F21,"A",G16:G21)+=SUMIF(F16:F21,"A",H16 :H21)

Mark


----------------
This post is a suggestion for Microsoft, and Microsoft responds to the
suggestions with the most votes. To vote for this suggestion, click the "I
Agree" button in the message pane. If you do not see the button, follow this
link to open the suggestion in the Microsoft Web-based Newsreader and then
click "I Agree" in the message pane.

http://www.microsoft.com/office/comm...et.f unctions
  #3   Report Post  
Harlan Grove
 
Posts: n/a
Default

Bob Phillips wrote...
One way

=SUM(IF(F16:F21="A",G16:H21,0))

which is an array formula, so commit with Ctrl-Shift-Enter

....

And another that's not an array formula,

=SUMPRODUCT((F16:F21="A")*G16:H21)

or, getting tricky,

=SUMPRODUCT(SUMIF(F16:F21,"A",OFFSET(G16:G21,0,{0, 1})))

which can handle multiple NONADJACENT columns in the same
worksheet.

  #4   Report Post  
Aladin Akyurek
 
Posts: n/a
Default

I16:

=G16+H16

Then invoke:

=SUMIF(F16:F21,"A",I16:I21)

Mark Rucker wrote:
In using the SUMIF function in Excel, I wanted to sum values in more than one
column, but it would only sum the first column.

Desired Function
=SUMIF(F16:F21,"A",G16:H21)

Workaround
=SUMIF(F16:F21,"A",G16:G21)+=SUMIF(F16:F21,"A",H16 :H21)

Mark


----------------
This post is a suggestion for Microsoft, and Microsoft responds to the
suggestions with the most votes. To vote for this suggestion, click the "I
Agree" button in the message pane. If you do not see the button, follow this
link to open the suggestion in the Microsoft Web-based Newsreader and then
click "I Agree" in the message pane.

http://www.microsoft.com/office/comm...et.f unctions

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Can SUMIF function include AND function ShaneS Excel Worksheet Functions 1 May 17th 05 03:24 AM
I need help with the Sumif Function Mark Excel Worksheet Functions 3 May 4th 05 11:07 PM
Dynamic sumif function Jimbola Excel Worksheet Functions 5 May 4th 05 01:10 AM
How to group similar column titles together???? vrk1 Excel Discussion (Misc queries) 2 April 30th 05 12:17 AM
How can I sort an entire spreadsheet from a list prod sorter Excel Worksheet Functions 4 November 17th 04 03:43 AM


All times are GMT +1. The time now is 10:38 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"