Solved

Excel sumproduct calculation with LEFT and variable length of characters

Posted on 2010-09-02
2
417 Views
Last Modified: 2012-05-10
I want to add sales figures for products using sumproduct and LEFT. But the search terms I use have variable length of characters. It is difficult to explain but please view the code. In A9 I will enter the first several letters of the product I want to total such as "Sony *". The way the formula works I would have to use the same number of characters for each product I am totaling, in this case 3 letters
(LEFT('2009'!$D$2:$D$65500,3)=A9)
I need it to allow for a varying number of characters in A9

SUMPRODUCT(('2009'!$G$2:$G$65500>=DATEVALUE($A42&" "&$A41&" "&$A40))*('2009'!$G$2:$G$65500<=DATEVALUE($B42&""&$B41&""&$B40))*(LEFT('2009'!$D$2:$D$65500,3)=A9)*('2009'!$H$2:$H$65500))

Open in new window

0
Comment
Question by:RTsal
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 3

Accepted Solution

by:
Peter_Werner earned 500 total points
ID: 33591363
LEFT(...,LEN(A9))=A9

You use " " and "" at DATEVALUE().  Don't you need "-" or "/"?
0
 

Author Closing Comment

by:RTsal
ID: 33596362
Datevalue works fine - thanks
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Read about achieving the basic levels of HRIS security in the workplace.
When table data gets too large to manage or queries take too long to execute the solution is often to buy bigger hardware or assign more CPUs and memory resources to the machine to solve the problem. However, the best, cheapest and most effective so…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
This is a high-level webinar that covers the history of enterprise open source database use. It addresses both the advantages companies see in using open source database technologies, as well as the fears and reservations they might have. In this…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question