Sumproduct 2 columns and Strings

Kemidan2014

Board Regular
Joined
Apr 4, 2022
Messages
226
Office Version
  1. 365
Platform
  1. Windows
The data is pretty simple and i have not updated by Xl2bb yet. but i have 2 columns of data
first column is just a string value of either "OK" or "NG". the 2nd column is a text string of 3 characters to which I have a list of all the possible combinations
for example "K13, "KK3", "KM3" first letter represents a month, 2nd is a day, 3rd is line number

I am trying to build a pareto with out hand counting

here is my sumproduct formula so far but all i get are "0" as a result
=SUMPRODUCT((D$4:E$271="NG"),(D$4:E$271=N22&"*"))

I have also tried =SUMPRODUCT((D$4:E$271="NG")*(D$4:E$271=N22&"*")) which got same result

the N22 in this case is a cell in my list of combinations in this case is "KK"
essentially in this example what am trying to ask is "How many times with in range of D4:E271 does NG and KK* occur next to each other in the same row"
 

Excel Facts

Select a hidden cell
Somehide hide payroll data in column G? Press F5. Type G1. Enter. Look in formula bar while you arrow down through G.
Try:

varios 30oct2023.xlsm
DEFMNO
3OK/NG
4OKK13
5OKKK3
6OKKM3
7NGK13
8NGKK3
9NGKM3
10OKKK3
11NGKK3
12
13
14
15
16
17
18
19
20
21
22KK2
Hoja3
Cell Formulas
RangeFormula
O22O22=SUMPRODUCT((D4:D300="NG")*(LEFT(E4:E300,2)=N22))
 
Upvote 0

Forum statistics

Threads
1,215,097
Messages
6,123,077
Members
449,094
Latest member
mystic19

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top