I have the below sumproduct formula which looks at another sheet holding sales orders.
=SUMPRODUCT(--('Sales by line'!$J:$J=$E7),--('Sales by line'!$G:$G>=M$4),--('Sales by line'!$G:$G<Q$4),'Sales by line'!$H:$H,'Sales by line'!$K:$K)
Col J matches to a product
Col G is a date
Col H is quantity
Col K is £
So this gives sum of prices paid for a certain product between two dates, so far so simple.
What i need to do next is add one more condition which looks at Col B, which holds order codes.
I need to be able to add a criteria that only shows order codes that start with certain letters.
In SumIf I could have used the wildcard feature &"*", but that doesnt work in sumproduct
I could easily have used the LEFT function except i need to check for different numbers of characters like "WS", "W" or just ""
In a SUMIF formula I would have used the below as range and criteria
,'Sales by line'!$B:$B,$F$1&"*",
I have tried everything I can to get this working, but it is beyond me.
Any help would be amazing
Twl
=SUMPRODUCT(--('Sales by line'!$J:$J=$E7),--('Sales by line'!$G:$G>=M$4),--('Sales by line'!$G:$G<Q$4),'Sales by line'!$H:$H,'Sales by line'!$K:$K)
Col J matches to a product
Col G is a date
Col H is quantity
Col K is £
So this gives sum of prices paid for a certain product between two dates, so far so simple.
What i need to do next is add one more condition which looks at Col B, which holds order codes.
I need to be able to add a criteria that only shows order codes that start with certain letters.
In SumIf I could have used the wildcard feature &"*", but that doesnt work in sumproduct
I could easily have used the LEFT function except i need to check for different numbers of characters like "WS", "W" or just ""
In a SUMIF formula I would have used the below as range and criteria
,'Sales by line'!$B:$B,$F$1&"*",
I have tried everything I can to get this working, but it is beyond me.
Any help would be amazing
Twl