#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 16
Default Sumproduct

I have a cost worksheet where I need to calculate a sum based on 2 different
critera that are entered onto 2 seperate worksheets. One worksheet is an
order entry worksheet where an order # and value are entered, the second
worksheet is an invoice worksheet where the invoice # and invoice value are
entered, the order # is also entered here for cross referencing, there is
also a delivery code on each invoice line, the delivery code may apply to
several invoices. What I need is a formula to sum up the total order value on
sheet #1 for corresponding order #'s on sheet #2 that all have matching
delivery codes.

The current formula I am tryin is:

=SUMPRODUCT(--(Invoices!F2:F2001=A2)--('Wholesale
Orders'!F2:F2001))--(Invoices!B:B1)

The result is the total order value for all orders on the order sheet.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 169
Default Sumproduct

3 immediate points. The ranges must be the same. You can't use B:B, it nees
to be B2:B2001 and your arguments should be separated by commas. Also, your
whole sale orders don't need the parens or -- because it isn't a criteria.

=SUMPRODUCT(--(Invoices!F2:F2001=A2),'Wholesale
Orders'!F2:F2001,--(Invoices!B2:B20011))

--
Tips for Excel, Word, PowerPoint and Other Applications
http://www.kan.org/tips


"ocuhcs" wrote:

I have a cost worksheet where I need to calculate a sum based on 2 different
critera that are entered onto 2 seperate worksheets. One worksheet is an
order entry worksheet where an order # and value are entered, the second
worksheet is an invoice worksheet where the invoice # and invoice value are
entered, the order # is also entered here for cross referencing, there is
also a delivery code on each invoice line, the delivery code may apply to
several invoices. What I need is a formula to sum up the total order value on
sheet #1 for corresponding order #'s on sheet #2 that all have matching
delivery codes.

The current formula I am tryin is:

=SUMPRODUCT(--(Invoices!F2:F2001=A2)--('Wholesale
Orders'!F2:F2001))--(Invoices!B:B1)

The result is the total order value for all orders on the order sheet.

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,651
Default Sumproduct

I think you may have missed a few commas from your formula.

=SUMPRODUCT(--(Invoices!F2:F2001=A2)--('Wholesale
Orders'!F2:F2001))--(Invoices!B:B1) is equivalent to
=SUMPRODUCT((Invoices!F2:F2001=A2)+('Wholesale
Orders'!F2:F2001))+(Invoices!B:B1)

You may have intended
=SUMPRODUCT(--(Invoices!F2:F2001=A2),--('Wholesale
Orders'!F2:F2001),--(Invoices!B:B1))
but in that case you would have tried to ask for a whole column for column B
whereas you've asked for rows 2 to 2001 for column F on the 2 sheets. You
need the same dimensions for all the arrays in your SUMPRODUCT.

Perhaps you may have wanted
=SUMPRODUCT(--(Invoices!F2:F2001=A2),--('Wholesale
Orders'!F2:F2001),--(Invoices!B2:B20011)) ?

But what are you looking for in your --('Wholesale Orders'!F2:F2001)) test?
Is it just looking for a non-zero value?
--
David Biddulph

"ocuhcs" wrote in message
...
I have a cost worksheet where I need to calculate a sum based on 2
different
critera that are entered onto 2 seperate worksheets. One worksheet is an
order entry worksheet where an order # and value are entered, the second
worksheet is an invoice worksheet where the invoice # and invoice value
are
entered, the order # is also entered here for cross referencing, there is
also a delivery code on each invoice line, the delivery code may apply to
several invoices. What I need is a formula to sum up the total order value
on
sheet #1 for corresponding order #'s on sheet #2 that all have matching
delivery codes.

The current formula I am tryin is:

=SUMPRODUCT(--(Invoices!F2:F2001=A2)--('Wholesale
Orders'!F2:F2001))--(Invoices!B:B1)

The result is the total order value for all orders on the order sheet.



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 16
Default Sumproduct

The column 'Wholesale Orders'!F2:F2001 contains the order value that I want
summed up. I think the trick here that I am missing is that this value is
only summed up when (Invoices!B2:B2000) is equal to 'Wholesale
Orders'!B2:B2000
and Invoices!F2:F20011

"David Biddulph" wrote:

I think you may have missed a few commas from your formula.

=SUMPRODUCT(--(Invoices!F2:F2001=A2)--('Wholesale
Orders'!F2:F2001))--(Invoices!B:B1) is equivalent to
=SUMPRODUCT((Invoices!F2:F2001=A2)+('Wholesale
Orders'!F2:F2001))+(Invoices!B:B1)

You may have intended
=SUMPRODUCT(--(Invoices!F2:F2001=A2),--('Wholesale
Orders'!F2:F2001),--(Invoices!B:B1))
but in that case you would have tried to ask for a whole column for column B
whereas you've asked for rows 2 to 2001 for column F on the 2 sheets. You
need the same dimensions for all the arrays in your SUMPRODUCT.

Perhaps you may have wanted
=SUMPRODUCT(--(Invoices!F2:F2001=A2),--('Wholesale
Orders'!F2:F2001),--(Invoices!B2:B20011)) ?

But what are you looking for in your --('Wholesale Orders'!F2:F2001)) test?
Is it just looking for a non-zero value?
--
David Biddulph

"ocuhcs" wrote in message
...
I have a cost worksheet where I need to calculate a sum based on 2
different
critera that are entered onto 2 seperate worksheets. One worksheet is an
order entry worksheet where an order # and value are entered, the second
worksheet is an invoice worksheet where the invoice # and invoice value
are
entered, the order # is also entered here for cross referencing, there is
also a delivery code on each invoice line, the delivery code may apply to
several invoices. What I need is a formula to sum up the total order value
on
sheet #1 for corresponding order #'s on sheet #2 that all have matching
delivery codes.

The current formula I am tryin is:

=SUMPRODUCT(--(Invoices!F2:F2001=A2)--('Wholesale
Orders'!F2:F2001))--(Invoices!B:B1)

The result is the total order value for all orders on the order sheet.




  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,651
Default Sumproduct

So those are the conditions which you should include in your SUMPRODUCT,
along with your 'Wholesale Orders'!F2:F2001 value (which doesn't need the
double unary minus if you are not trying to convert from Boolean to a
number).

But as we said earlier, your arrays need to be of the same length. You
can't go from 2 to 2001 in some parts and 2 to 2000 in other parts of the
same formula.
--
David Biddulph

"ocuhcs" wrote in message
...
The column 'Wholesale Orders'!F2:F2001 contains the order value that I
want
summed up. I think the trick here that I am missing is that this value is
only summed up when (Invoices!B2:B2000) is equal to 'Wholesale
Orders'!B2:B2000
and Invoices!F2:F20011

"David Biddulph" wrote:

I think you may have missed a few commas from your formula.

=SUMPRODUCT(--(Invoices!F2:F2001=A2)--('Wholesale
Orders'!F2:F2001))--(Invoices!B:B1) is equivalent to
=SUMPRODUCT((Invoices!F2:F2001=A2)+('Wholesale
Orders'!F2:F2001))+(Invoices!B:B1)

You may have intended
=SUMPRODUCT(--(Invoices!F2:F2001=A2),--('Wholesale
Orders'!F2:F2001),--(Invoices!B:B1))
but in that case you would have tried to ask for a whole column for
column B
whereas you've asked for rows 2 to 2001 for column F on the 2 sheets.
You
need the same dimensions for all the arrays in your SUMPRODUCT.

Perhaps you may have wanted
=SUMPRODUCT(--(Invoices!F2:F2001=A2),--('Wholesale
Orders'!F2:F2001),--(Invoices!B2:B20011)) ?

But what are you looking for in your --('Wholesale Orders'!F2:F2001))
test?
Is it just looking for a non-zero value?
--
David Biddulph

"ocuhcs" wrote in message
...
I have a cost worksheet where I need to calculate a sum based on 2
different
critera that are entered onto 2 seperate worksheets. One worksheet is
an
order entry worksheet where an order # and value are entered, the
second
worksheet is an invoice worksheet where the invoice # and invoice value
are
entered, the order # is also entered here for cross referencing, there
is
also a delivery code on each invoice line, the delivery code may apply
to
several invoices. What I need is a formula to sum up the total order
value
on
sheet #1 for corresponding order #'s on sheet #2 that all have matching
delivery codes.

The current formula I am tryin is:

=SUMPRODUCT(--(Invoices!F2:F2001=A2)--('Wholesale
Orders'!F2:F2001))--(Invoices!B:B1)

The result is the total order value for all orders on the order sheet.








  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 16
Default Sumproduct

I tried the following formula that contians all the correct conditions, but
comes up with an incorrect sum as the result.
=SUMPRODUCT(--(Invoices!B2:B2000='Wholesale
Orders'!B2:B2000))--(Invoices!F2:F2000=A2)--('Wholesale Orders'!F2:F2000)

"David Biddulph" wrote:

So those are the conditions which you should include in your SUMPRODUCT,
along with your 'Wholesale Orders'!F2:F2001 value (which doesn't need the
double unary minus if you are not trying to convert from Boolean to a
number).

But as we said earlier, your arrays need to be of the same length. You
can't go from 2 to 2001 in some parts and 2 to 2000 in other parts of the
same formula.


  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,856
Default Sumproduct

You do not have the correct syntax - you've missed a few commas (or
your regional settings might use semi-colons), as well as a bracket at
the end, and you have an extra one in the middle. Try it like this:

=SUMPRODUCT(--(Invoices!B2:B2000='Wholesale Orders'!B2:B2000),--
(Invoices!F2:F2000=A2),--('Wholesale Orders'!F2:F2000))

Hope this helps.

Pete

On Jul 30, 2:27*pm, ocuhcs wrote:
I tried the following formula that contians all the correct conditions, but
comes up with an incorrect sum as the result.
=SUMPRODUCT(--(Invoices!B2:B2000='Wholesale
Orders'!B2:B2000))--(Invoices!F2:F2000=A2)--('Wholesale Orders'!F2:F2000)



"David Biddulph" wrote:
So those are the conditions which you should include in your SUMPRODUCT,
along with your 'Wholesale Orders'!F2:F2001 value (which doesn't need the
double unary minus if you are not trying to convert from Boolean to a
number).


But as we said earlier, your arrays need to be of the same length. *You
can't go from 2 to 2001 in some parts and 2 to 2000 in other parts of the
same formula.- Hide quoted text -


- Show quoted text -


  #8   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,651
Default Sumproduct

You mustn't have read the part of my earlier message
] (the content of which you've
snipped) where I said you seemed to have missed a few commas and got the
syntax wrong (and where I suggested what you might have been trying to do).
And you've also presumably not read the bit below where I said that the
'Wholesale Orders'F... bit doesn't need the double unary minus if you are
not trying to convert from Boolean to a number.
--
David Biddulph

"ocuhcs" wrote in message
...
I tried the following formula that contians all the correct conditions, but
comes up with an incorrect sum as the result.
=SUMPRODUCT(--(Invoices!B2:B2000='Wholesale
Orders'!B2:B2000))--(Invoices!F2:F2000=A2)--('Wholesale Orders'!F2:F2000)

"David Biddulph" wrote:

So those are the conditions which you should include in your SUMPRODUCT,
along with your 'Wholesale Orders'!F2:F2001 value (which doesn't need the
double unary minus if you are not trying to convert from Boolean to a
number).

But as we said earlier, your arrays need to be of the same length. You
can't go from 2 to 2001 in some parts and 2 to 2000 in other parts of the
same formula.




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
sumproduct? sumif(sumproduct)? David Excel Worksheet Functions 3 July 13th 07 07:06 PM
SUMPRODUCT Farhad Excel Discussion (Misc queries) 1 June 20th 07 10:20 PM
sumproduct bj Excel Discussion (Misc queries) 0 June 20th 07 10:18 PM
Sumproduct PA Excel Worksheet Functions 2 December 31st 05 02:27 PM
Can I use SUMPRODUCT for this? cottage6 Excel Worksheet Functions 5 November 15th 05 10:09 PM


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