#1   Report Post  
Posted to microsoft.public.excel.misc
Nic Nic is offline
external usenet poster
 
Posts: 25
Default Sumif Criteria

I have a list of accounts and account numbers eg

A B C
1 11012 Personal exp 12000
2 11019 Business exp 10000
3 12089 Hotel exp 25000

i want to sum coulmn C if coulmn A falls between 11012 and 12089 the result
should show 10000

I have tried sumif(A1:A3,11012<12089,C1:C3) value is shown as 0 which is
wrong.

I have also tried the sum(if( function but that will only work with one
coulmn.

Any ideas please help
Thanks
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Sumif Criteria

Try

=SUMPRODUCT(--(A1:A10011012),--(A1:A100<12089),C1:C100)

If this post helps click Yes
---------------
Jacob Skaria


"Nic" wrote:

I have a list of accounts and account numbers eg

A B C
1 11012 Personal exp 12000
2 11019 Business exp 10000
3 12089 Hotel exp 25000

i want to sum coulmn C if coulmn A falls between 11012 and 12089 the result
should show 10000

I have tried sumif(A1:A3,11012<12089,C1:C3) value is shown as 0 which is
wrong.

I have also tried the sum(if( function but that will only work with one
coulmn.

Any ideas please help
Thanks

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,856
Default Sumif Criteria

Try this:

=SUMIF(A1:A3,"<12089",C1:C3) - SUMIF(A1:A3,"<=11012",C1:C3)

Hope this helps.

Pete

On Aug 4, 9:53*am, Nic wrote:
I have a list of accounts and account numbers eg

* * * * * * A * * * * * * * * * * * B * * * * * * * * * * * * *C
1 * * * *11012 * * * * * *Personal exp * * * * * * 12000
2 * * * *11019 * * * * * *Business exp * * * * * * 10000
3 * * * *12089 * * * * * *Hotel exp * * * * * * * * *25000

i want to sum coulmn C if coulmn A falls between 11012 and 12089 the result
should show 10000

I have tried sumif(A1:A3,11012<12089,C1:C3) value is shown as 0 which is
wrong.

I have also tried the sum(if( function but that will only work with one
coulmn.

Any ideas please help
Thanks


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Sumif Criteria

As you mentioned you can also try with SUM(IF( as below. Please note that
this is an array formula. Within the cell in edit mode (F2) paste this
formula and press Ctrl+Shift+Enter to apply this formula. If successful in
'Formula Bar' you can notice the curly braces at both ends like "{=<formula}"

=SUM(IF(A1:A10011012,IF(A1:A100<12089,C1:C100)))

If this post helps click Yes
---------------
Jacob Skaria


"Jacob Skaria" wrote:

Try

=SUMPRODUCT(--(A1:A10011012),--(A1:A100<12089),C1:C100)

If this post helps click Yes
---------------
Jacob Skaria


"Nic" wrote:

I have a list of accounts and account numbers eg

A B C
1 11012 Personal exp 12000
2 11019 Business exp 10000
3 12089 Hotel exp 25000

i want to sum coulmn C if coulmn A falls between 11012 and 12089 the result
should show 10000

I have tried sumif(A1:A3,11012<12089,C1:C3) value is shown as 0 which is
wrong.

I have also tried the sum(if( function but that will only work with one
coulmn.

Any ideas please help
Thanks

  #5   Report Post  
Posted to microsoft.public.excel.misc
Nic Nic is offline
external usenet poster
 
Posts: 25
Default Sumif Criteria

Thanks this works perfectly, just a question though what is the need for the
-- in the formula?

"Jacob Skaria" wrote:

Try

=SUMPRODUCT(--(A1:A10011012),--(A1:A100<12089),C1:C100)

If this post helps click Yes
---------------
Jacob Skaria


"Nic" wrote:

I have a list of accounts and account numbers eg

A B C
1 11012 Personal exp 12000
2 11019 Business exp 10000
3 12089 Hotel exp 25000

i want to sum coulmn C if coulmn A falls between 11012 and 12089 the result
should show 10000

I have tried sumif(A1:A3,11012<12089,C1:C3) value is shown as 0 which is
wrong.

I have also tried the sum(if( function but that will only work with one
coulmn.

Any ideas please help
Thanks



  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Sumif Criteria

-- is used to convert boolean values to numeric values . Check out the below
link
http://mcgimpsey.com/excel/formulae/doubleneg.html

Alternatively you can try

=SUMPRODUCT((A1:A10111012)*(A1:A101<12089),C1:C10 1)

If this post helps click Yes
---------------
Jacob Skaria


"Nic" wrote:

Thanks this works perfectly, just a question though what is the need for the
-- in the formula?

"Jacob Skaria" wrote:

Try

=SUMPRODUCT(--(A1:A10011012),--(A1:A100<12089),C1:C100)

If this post helps click Yes
---------------
Jacob Skaria


"Nic" wrote:

I have a list of accounts and account numbers eg

A B C
1 11012 Personal exp 12000
2 11019 Business exp 10000
3 12089 Hotel exp 25000

i want to sum coulmn C if coulmn A falls between 11012 and 12089 the result
should show 10000

I have tried sumif(A1:A3,11012<12089,C1:C3) value is shown as 0 which is
wrong.

I have also tried the sum(if( function but that will only work with one
coulmn.

Any ideas please help
Thanks

  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default Sumif Criteria

Double unary minus:
a.. http://www.mcgimpsey.com/excel/formulae/doubleneg.html
b.. http://xldynamic.com/source/xld.SUMPRODUCT.html
--
David Biddulph

"Nic" wrote in message
...
Thanks this works perfectly, just a question though what is the need for
the
-- in the formula?

"Jacob Skaria" wrote:

Try

=SUMPRODUCT(--(A1:A10011012),--(A1:A100<12089),C1:C100)

If this post helps click Yes
---------------
Jacob Skaria


"Nic" wrote:

I have a list of accounts and account numbers eg

A B C
1 11012 Personal exp 12000
2 11019 Business exp 10000
3 12089 Hotel exp 25000

i want to sum coulmn C if coulmn A falls between 11012 and 12089 the
result
should show 10000

I have tried sumif(A1:A3,11012<12089,C1:C3) value is shown as 0 which
is
wrong.

I have also tried the sum(if( function but that will only work with one
coulmn.

Any ideas please help
Thanks



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
SUMIF with criteria jj Excel Worksheet Functions 2 May 16th 08 03:16 AM
SUMIF Criteria JC Excel Worksheet Functions 5 May 7th 08 06:58 PM
SUMIF with four criteria Ken Excel Worksheet Functions 2 January 30th 07 08:27 AM
Sumif with 2 criteria Mike Excel Discussion (Misc queries) 4 May 16th 06 09:21 PM
nested sumif or sumif with two criteria dshigley Excel Worksheet Functions 5 April 5th 05 03:34 AM


All times are GMT +1. The time now is 11:07 AM.

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"