Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 10
Default SUMIF with multiple variables HELP!!!!

I have an Array formula below that works perfect. It sums amounts of project
expenses (DataFile.xls) based on specified criteria from multiple combo
boxes. This part works perfectly.

{=SUM(IF((DataFile.xls!Account=$A15)*(DataFile. xls!Dept=C$6)*(DataFile.xls!Project=$H$1*(Da taFile.xls!Date=$M$1)*(DataFile.xls!Date<=$ N$1),DataFile.xls!Amount))}

However, there are several incorrect project Codes that could also be used
in this expense file (DataFile.xls) from Fiscal Yeas 08, 07 and 06.

So, from the combo box, when a project is selected, I also with vlookup pull
the other possible Fiscal year project names. That way I was hopping we
could sum all the expenses for that project even if it were posted to the
incorrect Fiscal Year project name.

The lookup data table is below:


My problem is that if there is no data in the Data file that fits all 3
possible project names, it doesnt pull up anything. Sometimes there can be
3 project names, sometimes 2, sometimes only 1. How do I write this formula
so that it adds amounts for all three if there are three; only 2 if there are
only two; and just 1 if there is just 1?

Below is the formula to include all 3 fiscal year project names IF THEY
APPEAR in the expense file
{=SUM(IF((DataFile.xls!Account=$A15)*(DataFile. xls!Dept=C$6)*(DataFile.xls!Project=$H$1)*(D ataFile.xls!Project=$J$1)*(DataFile.xls!Proj ect=$L$1)*(DataFile.xls!Date=$M$1)*(DataFile.x ls!Date<=$N$1),DataFile.xls!Amount))}

Oh, I do hope I have explained this properly and SOMEONE can help me out
there!

Thanks soo much,

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,058
Default SUMIF with multiple variables HELP!!!!

Consider using the SUMPRODUCT function instead.
--
Gary''s Student - gsnu200860


"Gwynne" wrote:

I have an Array formula below that works perfect. It sums amounts of project
expenses (DataFile.xls) based on specified criteria from multiple combo
boxes. This part works perfectly.

{=SUM(IF((DataFile.xls!Account=$A15)*(DataFile. xls!Dept=C$6)*(DataFile.xls!Project=$H$1*(Da taFile.xls!Date=$M$1)*(DataFile.xls!Date<=$ N$1),DataFile.xls!Amount))}

However, there are several incorrect project Codes that could also be used
in this expense file (DataFile.xls) from Fiscal Yeas 08, 07 and 06.

So, from the combo box, when a project is selected, I also with vlookup pull
the other possible Fiscal year project names. That way I was hopping we
could sum all the expenses for that project even if it were posted to the
incorrect Fiscal Year project name.

The lookup data table is below:


My problem is that if there is no data in the Data file that fits all 3
possible project names, it doesnt pull up anything. Sometimes there can be
3 project names, sometimes 2, sometimes only 1. How do I write this formula
so that it adds amounts for all three if there are three; only 2 if there are
only two; and just 1 if there is just 1?

Below is the formula to include all 3 fiscal year project names IF THEY
APPEAR in the expense file
{=SUM(IF((DataFile.xls!Account=$A15)*(DataFile. xls!Dept=C$6)*(DataFile.xls!Project=$H$1)*(D ataFile.xls!Project=$J$1)*(DataFile.xls!Proj ect=$L$1)*(DataFile.xls!Date=$M$1)*(DataFile.x ls!Date<=$N$1),DataFile.xls!Amount))}

Oh, I do hope I have explained this properly and SOMEONE can help me out
there!

Thanks soo much,

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 10
Default SUMIF with multiple variables HELP!!!!

Gary's Student - thank's so much for your quick response. However, when I
looked up how to use SUBPRODUCT, I could not figure out how to apply it to my
formula. Can U help with this too? Do I just replace the =SUM(IF(( with
=SUBPRODUCT(IF((...?

"Gary''s Student" wrote:

Consider using the SUMPRODUCT function instead.
--
Gary''s Student - gsnu200860


"Gwynne" wrote:

I have an Array formula below that works perfect. It sums amounts of project
expenses (DataFile.xls) based on specified criteria from multiple combo
boxes. This part works perfectly.

{=SUM(IF((DataFile.xls!Account=$A15)*(DataFile. xls!Dept=C$6)*(DataFile.xls!Project=$H$1*(Da taFile.xls!Date=$M$1)*(DataFile.xls!Date<=$ N$1),DataFile.xls!Amount))}

However, there are several incorrect project Codes that could also be used
in this expense file (DataFile.xls) from Fiscal Yeas 08, 07 and 06.

So, from the combo box, when a project is selected, I also with vlookup pull
the other possible Fiscal year project names. That way I was hopping we
could sum all the expenses for that project even if it were posted to the
incorrect Fiscal Year project name.

The lookup data table is below:


My problem is that if there is no data in the Data file that fits all 3
possible project names, it doesnt pull up anything. Sometimes there can be
3 project names, sometimes 2, sometimes only 1. How do I write this formula
so that it adds amounts for all three if there are three; only 2 if there are
only two; and just 1 if there is just 1?

Below is the formula to include all 3 fiscal year project names IF THEY
APPEAR in the expense file
{=SUM(IF((DataFile.xls!Account=$A15)*(DataFile. xls!Dept=C$6)*(DataFile.xls!Project=$H$1)*(D ataFile.xls!Project=$J$1)*(DataFile.xls!Proj ect=$L$1)*(DataFile.xls!Date=$M$1)*(DataFile.x ls!Date<=$N$1),DataFile.xls!Amount))}

Oh, I do hope I have explained this properly and SOMEONE can help me out
there!

Thanks soo much,

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 2 variables Dave Excel Discussion (Misc queries) 3 July 14th 08 09:39 AM
SUMIF with two or more variables B Benton Excel Worksheet Functions 1 October 13th 07 07:12 PM
Sumif with multiple variables les8 Excel Discussion (Misc queries) 5 April 8th 06 02:16 AM
SUMIF Formuale with 2 variables CiaraG Excel Worksheet Functions 3 February 15th 06 02:10 PM
SUMIF variables Steve Excel Discussion (Misc queries) 2 February 18th 05 01:32 PM


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