Good morning!
I did a bit of searching to solve this on my own but alas, I have been unable to.
I am using a formula to determine how many of these characters exist in a cell:
=SUMPRODUCT(--ISNUMBER(SEARCH(Sheet2!$A$1:$B$28,Sheet1!H2)))
The formula is by default evaluating to 3 and I don't know why ('?' '~' and '*' are evaluating to true when they are not present).
When I add any character in the range to the cell, it evaluates to 4 so it is identifying some correctly.
=SEARCH(Sheet2!$A$1:$B$28,Sheet1!H2)which is evaluating to #VALUE! by itself.
The range containing characters I am searching for is formatted as text as is the cell I am searching within. The cell I am searching for the presence of characters within must be maintained as text because I have many instances of leading zeros.
I have recreated the table below and I changed the references to be relative to the table (B2, B3 and B4 are evaluating to 3 in excel).
How do I get this to evaluate correctly?
[TABLE="width: 500, align: left"]
<tbody>[TR]
[TD]UPC[/TD]
[TD]Count[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][TABLE="width: 114"]
<tbody>[TR]
[TD="width: 114"]885938815014[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD]=sumproduct(--isnumber(search($C$2:$D$30,A2)))[/TD]
[TD]a
[/TD]
[TD]~[/TD]
[/TR]
[TR]
[TD][TABLE="width: 114"]
<tbody>[TR]
[TD="class: xl65, width: 114"]885938815021[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD]=sumproduct(--isnumber(search($C$2:$D$30,A3)))[/TD]
[TD]b[/TD]
[TD]`[/TD]
[/TR]
[TR]
[TD][TABLE="width: 114"]
<tbody>[TR]
[TD="class: xl65, width: 114"]885938815038[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD]=sumproduct(--isnumber(search($C$2:$D$30,A4)))[/TD]
[TD]c[/TD]
[TD]![/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD]d[/TD]
[TD]@[/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD]e[/TD]
[TD]#[/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD]f[/TD]
[TD]$[/TD]
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]
[TD][/TD]
[TD][/TD]
[TD]<[/TD]
[TD]>[/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD],[/TD]
[TD].[/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD]?[/TD]
[TD]/[/TD]
[/TR]
</tbody>[/TABLE]
I did a bit of searching to solve this on my own but alas, I have been unable to.
I am using a formula to determine how many of these characters exist in a cell:
=SUMPRODUCT(--ISNUMBER(SEARCH(Sheet2!$A$1:$B$28,Sheet1!H2)))
The formula is by default evaluating to 3 and I don't know why ('?' '~' and '*' are evaluating to true when they are not present).
When I add any character in the range to the cell, it evaluates to 4 so it is identifying some correctly.
=SEARCH(Sheet2!$A$1:$B$28,Sheet1!H2)which is evaluating to #VALUE! by itself.
The range containing characters I am searching for is formatted as text as is the cell I am searching within. The cell I am searching for the presence of characters within must be maintained as text because I have many instances of leading zeros.
I have recreated the table below and I changed the references to be relative to the table (B2, B3 and B4 are evaluating to 3 in excel).
How do I get this to evaluate correctly?
[TABLE="width: 500, align: left"]
<tbody>[TR]
[TD]UPC[/TD]
[TD]Count[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][TABLE="width: 114"]
<tbody>[TR]
[TD="width: 114"]885938815014[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD]=sumproduct(--isnumber(search($C$2:$D$30,A2)))[/TD]
[TD]a
[/TD]
[TD]~[/TD]
[/TR]
[TR]
[TD][TABLE="width: 114"]
<tbody>[TR]
[TD="class: xl65, width: 114"]885938815021[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD]=sumproduct(--isnumber(search($C$2:$D$30,A3)))[/TD]
[TD]b[/TD]
[TD]`[/TD]
[/TR]
[TR]
[TD][TABLE="width: 114"]
<tbody>[TR]
[TD="class: xl65, width: 114"]885938815038[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD]=sumproduct(--isnumber(search($C$2:$D$30,A4)))[/TD]
[TD]c[/TD]
[TD]![/TD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