Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 52
Default IF FUCTION WITH 2 SETS OF CRITERIA

Good afternoon all, I am looking for some help if possible

I need excel to take a sum based on 2 sets of critiera

I put cells in just for reference

For example

Office Band Amount
A1: London B1: 4 C1: 2000
A2: Geneva B2: 3 C2: 3000
A3: Stuttgart B3: 2 C3: 4000

So I am trying to do the following

=IF(A1="London" AND, B1=4,c1)

I know the calculation above isnt right but I am trying like mad to work it
out and am stuck.

Any help greatly appreciated.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,533
Default IF FUCTION WITH 2 SETS OF CRITERIA

Hi
Try this sumproduct formula:

=Sumproduct(--(A1:A100="London"),--(B1:B100=4),C1:C100)

Regards,
Per

"Mark D" skrev i meddelelsen
...
Good afternoon all, I am looking for some help if possible

I need excel to take a sum based on 2 sets of critiera

I put cells in just for reference

For example

Office Band Amount
A1: London B1: 4 C1: 2000
A2: Geneva B2: 3 C2: 3000
A3: Stuttgart B3: 2 C3: 4000

So I am trying to do the following

=IF(A1="London" AND, B1=4,c1)

I know the calculation above isnt right but I am trying like mad to work
it
out and am stuck.

Any help greatly appreciated.


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,718
Default IF FUCTION WITH 2 SETS OF CRITERIA

=sumproduct((a1:a3="London")*(b1:b3=4),c1:c4)


"Mark D" wrote:

Good afternoon all, I am looking for some help if possible

I need excel to take a sum based on 2 sets of critiera

I put cells in just for reference

For example

Office Band Amount
A1: London B1: 4 C1: 2000
A2: Geneva B2: 3 C2: 3000
A3: Stuttgart B3: 2 C3: 4000

So I am trying to do the following

=IF(A1="London" AND, B1=4,c1)

I know the calculation above isnt right but I am trying like mad to work it
out and am stuck.

Any help greatly appreciated.

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,718
Default IF FUCTION WITH 2 SETS OF CRITERIA

Oops...

Column C should be c1:c3

"Mark D" wrote:

Good afternoon all, I am looking for some help if possible

I need excel to take a sum based on 2 sets of critiera

I put cells in just for reference

For example

Office Band Amount
A1: London B1: 4 C1: 2000
A2: Geneva B2: 3 C2: 3000
A3: Stuttgart B3: 2 C3: 4000

So I am trying to do the following

=IF(A1="London" AND, B1=4,c1)

I know the calculation above isnt right but I am trying like mad to work it
out and am stuck.

Any help greatly appreciated.

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,520
Default IF FUCTION WITH 2 SETS OF CRITERIA

Try the below
=SUMPRODUCT(($A$1:$A$100="London")*($B$1:$B$100=4) ,$C$1:$C$100)

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


"Mark D" wrote:

Good afternoon all, I am looking for some help if possible

I need excel to take a sum based on 2 sets of critiera

I put cells in just for reference

For example

Office Band Amount
A1: London B1: 4 C1: 2000
A2: Geneva B2: 3 C2: 3000
A3: Stuttgart B3: 2 C3: 4000

So I am trying to do the following

=IF(A1="London" AND, B1=4,c1)

I know the calculation above isnt right but I am trying like mad to work it
out and am stuck.

Any help greatly appreciated.



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 52
Default IF FUCTION WITH 2 SETS OF CRITERIA

Thanks for all the replies, but one more quick question

What if it's Geneva and Level 2??

Do i just replicate the sumproduct formula??

"Jacob Skaria" wrote:

Try the below
=SUMPRODUCT(($A$1:$A$100="London")*($B$1:$B$100=4) ,$C$1:$C$100)

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


"Mark D" wrote:

Good afternoon all, I am looking for some help if possible

I need excel to take a sum based on 2 sets of critiera

I put cells in just for reference

For example

Office Band Amount
A1: London B1: 4 C1: 2000
A2: Geneva B2: 3 C2: 3000
A3: Stuttgart B3: 2 C3: 4000

So I am trying to do the following

=IF(A1="London" AND, B1=4,c1)

I know the calculation above isnt right but I am trying like mad to work it
out and am stuck.

Any help greatly appreciated.

  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,520
Default IF FUCTION WITH 2 SETS OF CRITERIA

You can refer that to a cell
D1 = Geneva
E1 = 5
=SUMPRODUCT(($A$1:$A$100=D1)*($B$1:$B$100=E1),$C$1 :$C$100)

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


"Mark D" wrote:

Thanks for all the replies, but one more quick question

What if it's Geneva and Level 2??

Do i just replicate the sumproduct formula??

"Jacob Skaria" wrote:

Try the below
=SUMPRODUCT(($A$1:$A$100="London")*($B$1:$B$100=4) ,$C$1:$C$100)

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


"Mark D" wrote:

Good afternoon all, I am looking for some help if possible

I need excel to take a sum based on 2 sets of critiera

I put cells in just for reference

For example

Office Band Amount
A1: London B1: 4 C1: 2000
A2: Geneva B2: 3 C2: 3000
A3: Stuttgart B3: 2 C3: 4000

So I am trying to do the following

=IF(A1="London" AND, B1=4,c1)

I know the calculation above isnt right but I am trying like mad to work it
out and am stuck.

Any help greatly appreciated.

  #8   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 5
Default IF FUCTION WITH 2 SETS OF CRITERIA

Hi. This is probably far too late because it looks like you've solved it
another way, but I just thought you were on the right lines with your IF and
AND except your AND was in the wrong place and you didn't finish off the IF
statement results at the end. The following would have worked fine, which is
near to what you had:

=IF(AND(A1="london",B1=1),C1,"")

The 2 speech marks at the end of the IF would leave a blank cell if the
criteria of London and 1 were not met. You can continue adding ANDs to look
at up to 30 different columns so this is just the AND nested once to look at
2 columns.

Sall

"Jacob Skaria" wrote:

You can refer that to a cell
D1 = Geneva
E1 = 5
=SUMPRODUCT(($A$1:$A$100=D1)*($B$1:$B$100=E1),$C$1 :$C$100)

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


"Mark D" wrote:

Thanks for all the replies, but one more quick question

What if it's Geneva and Level 2??

Do i just replicate the sumproduct formula??

"Jacob Skaria" wrote:

Try the below
=SUMPRODUCT(($A$1:$A$100="London")*($B$1:$B$100=4) ,$C$1:$C$100)

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


"Mark D" wrote:

Good afternoon all, I am looking for some help if possible

I need excel to take a sum based on 2 sets of critiera

I put cells in just for reference

For example

Office Band Amount
A1: London B1: 4 C1: 2000
A2: Geneva B2: 3 C2: 3000
A3: Stuttgart B3: 2 C3: 4000

So I am trying to do the following

=IF(A1="London" AND, B1=4,c1)

I know the calculation above isnt right but I am trying like mad to work it
out and am stuck.

Any help greatly appreciated.

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
4 SETS OF CRITERIA USED TO DISPLAY ANSWER Mally Excel Discussion (Misc queries) 5 November 24th 08 12:33 PM
Sumif as a fuction of If using multiple criteria AMB Excel Worksheet Functions 2 June 11th 08 03:47 PM
Vlookup for 2 sets of Criteria (or do I need to use something else Buzz07 Excel Discussion (Misc queries) 9 August 23rd 07 10:16 PM
vlookup with 2 sets of criteria laf2day Excel Discussion (Misc queries) 2 June 9th 07 03:36 AM
SUMIF with two sets of criteria luvthavodka Excel Discussion (Misc queries) 5 May 29th 06 08:02 PM


All times are GMT +1. The time now is 03:19 PM.

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

About Us

"It's about Microsoft Excel"