Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 281
Default Sumif with multiple criteria

Hi all,

i have a sheet and want to sum a column with 3 criteria like below:

A B C D
1 date kind1 kind2 amount
2 1/1/2006 silic toronto 10000
3 2/1/2006 Cab Quebec 2000
..
..

i want to sum amounts if dates are less than a date and kind1 is for example
silic and the kind2 is toronto can i use sumif?

any sugestion,

Thanks
--
Farhad Hodjat
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 10,593
Default Sumif with multiple criteria

=SUMPRODUCT(--(A2:A20<M1),--(B2:B20="silic"),--(C2:C20="toronto"),D2:D20)

where M1 is the testdate.

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"Farhad" wrote in message
...
Hi all,

i have a sheet and want to sum a column with 3 criteria like below:

A B C D
1 date kind1 kind2 amount
2 1/1/2006 silic toronto 10000
3 2/1/2006 Cab Quebec 2000
.
.

i want to sum amounts if dates are less than a date and kind1 is for

example
silic and the kind2 is toronto can i use sumif?

any sugestion,

Thanks
--
Farhad Hodjat



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default Sumif with multiple criteria

Nope to =sumif()

But you could use:

=sumproduct(--(a1:a100<date(2006,12,1)),--(b1:b100="silic"),
--(c1:c100="toronto"),(d1:d100))

Adjust the ranges to match--but you can't use whole columns (except in xl2007).

=sumproduct() likes to work with numbers. The -- stuff changes trues and falses
to 1's and 0's.

Bob Phillips explains =sumproduct() in much more detail he
http://www.xldynamic.com/source/xld.SUMPRODUCT.html

And J.E. McGimpsey has some notes at:
http://mcgimpsey.com/excel/formulae/doubleneg.html

Farhad wrote:

Hi all,

i have a sheet and want to sum a column with 3 criteria like below:

A B C D
1 date kind1 kind2 amount
2 1/1/2006 silic toronto 10000
3 2/1/2006 Cab Quebec 2000
.
.

i want to sum amounts if dates are less than a date and kind1 is for example
silic and the kind2 is toronto can i use sumif?

any sugestion,

Thanks
--
Farhad Hodjat


--

Dave Peterson
  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 58
Default Sumif with multiple criteria


Here it is :-) enjoy!!
A B C D
date kind1 kind2 amount
1/1/2007 slic toronto 2
1/1/2005 slic toronto 1
1/2/2007 cab quebec 1
1/1/2007 slic toronto 2
1/4/2007 slic quebec 1
1/5/2007 cab quebec 1

1/1/2007 slic toronto 2 in this box you write:

6 =SUMPRODUCT(--(A2:A8DATE(2006,1,1)),--(B2:B8="slic"),--(C2:C8="toronto"), D2:D8)






"Farhad" wrote in message ...
Hi all,

i have a sheet and want to sum a column with 3 criteria like below:

A B C D
1 date kind1 kind2 amount
2 1/1/2006 silic toronto 10000
3 2/1/2006 Cab Quebec 2000
.
.

i want to sum amounts if dates are less than a date and kind1 is for example
silic and the kind2 is toronto can i use sumif?

any sugestion,

Thanks
--
Farhad Hodjat

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 281
Default Sumif with multiple criteria

Thakns Dave & Bob
--
Farhad Hodjat


"Farhad" wrote:

Hi all,

i have a sheet and want to sum a column with 3 criteria like below:

A B C D
1 date kind1 kind2 amount
2 1/1/2006 silic toronto 10000
3 2/1/2006 Cab Quebec 2000
.
.

i want to sum amounts if dates are less than a date and kind1 is for example
silic and the kind2 is toronto can i use sumif?

any sugestion,

Thanks
--
Farhad Hodjat



  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 14
Default Sumif with multiple criteria

I wanted to do something similar, and it does not sum it up.
Can you please help.
Thanks in advance

=SUMPRODUCT( --(C1:C10 1), --(C1:C10 < 2), D1:D10 )
C D
1.1 3
1.2 2
1.3 1
2.2 3
2.1 1


"Dave Peterson" wrote:

Nope to =sumif()

But you could use:

=sumproduct(--(a1:a100<date(2006,12,1)),--(b1:b100="silic"),
--(c1:c100="toronto"),(d1:d100))

Adjust the ranges to match--but you can't use whole columns (except in xl2007).

=sumproduct() likes to work with numbers. The -- stuff changes trues and falses
to 1's and 0's.

Bob Phillips explains =sumproduct() in much more detail he
http://www.xldynamic.com/source/xld.SUMPRODUCT.html

And J.E. McGimpsey has some notes at:
http://mcgimpsey.com/excel/formulae/doubleneg.html

Farhad wrote:

Hi all,

i have a sheet and want to sum a column with 3 criteria like below:

A B C D
1 date kind1 kind2 amount
2 1/1/2006 silic toronto 10000
3 2/1/2006 Cab Quebec 2000
.
.

i want to sum amounts if dates are less than a date and kind1 is for example
silic and the kind2 is toronto can i use sumif?

any sugestion,

Thanks
--
Farhad Hodjat


--

Dave Peterson

  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 14
Default Sumif with multiple criteria

Btw, It does work, My bad.
I had an error in one of the other columns.
....

"Shan" wrote:

I wanted to do something similar, and it does not sum it up.
Can you please help.
Thanks in advance

=SUMPRODUCT( --(C1:C10 1), --(C1:C10 < 2), D1:D10 )
C D
1.1 3
1.2 2
1.3 1
2.2 3
2.1 1


"Dave Peterson" wrote:

Nope to =sumif()

But you could use:

=sumproduct(--(a1:a100<date(2006,12,1)),--(b1:b100="silic"),
--(c1:c100="toronto"),(d1:d100))

Adjust the ranges to match--but you can't use whole columns (except in xl2007).

=sumproduct() likes to work with numbers. The -- stuff changes trues and falses
to 1's and 0's.

Bob Phillips explains =sumproduct() in much more detail he
http://www.xldynamic.com/source/xld.SUMPRODUCT.html

And J.E. McGimpsey has some notes at:
http://mcgimpsey.com/excel/formulae/doubleneg.html

Farhad wrote:

Hi all,

i have a sheet and want to sum a column with 3 criteria like below:

A B C D
1 date kind1 kind2 amount
2 1/1/2006 silic toronto 10000
3 2/1/2006 Cab Quebec 2000
.
.

i want to sum amounts if dates are less than a date and kind1 is for example
silic and the kind2 is toronto can i use sumif?

any sugestion,

Thanks
--
Farhad Hodjat


--

Dave Peterson

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
MULTIPLE CRITERIA RETURNING SUM OF RESULTS [email protected] Excel Worksheet Functions 0 November 15th 06 05:11 PM
SUMIF - multiple criteria in different columns SUMIF Multiple Criteria in diff columns Excel Worksheet Functions 1 September 22nd 06 04:06 PM
SUMIF multiple criteria HLS Excel Discussion (Misc queries) 5 March 24th 06 03:43 PM
SUMIF with multiple criteria stacyjhaskins Excel Worksheet Functions 4 August 29th 05 08:22 PM
SUMIF in multiple columns based on other criteria in Excel? Scott Powell Excel Discussion (Misc queries) 9 April 13th 05 02:32 PM


All times are GMT +1. The time now is 07:19 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"