Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Hi,
with the help of some excellent feedback from the User Group I have created the following formula but I am not getting the expected results The formula works finre until I put the 2nd search for a particular word.. eg This works fine =SUMPRODUCT((('Grid data'!B2:B4557=A2)*(ISERROR(SEARCH("shine*",'Grid data'!D2:D4557)*((('Grid data'!F2:F4557="NS")+('Grid data'! F2:F4557="C")+(TRIM('Grid data'! F2:F4557)=""))))))) And counts correctly, ignoring anything with SHINE in column D and only including, blanks, C and NS values. The following formula I am not getting the right results. It appears to be ignoring the search for "NON" in column E. =SUMPRODUCT((('Grid data'!B2:B4557=A2)*(ISERROR(SEARCH("shine*",'Grid data'!D2:D4557)+(SEARCH( "non*",'Grid data'!E2:E4557))*((('Grid data'! F2:F4557="NS")+('Grid data'!F2:F4557="C")+(TRIM('Grid data'! F2:F4557)=""))))))) Paul |
#2
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Try it like this:
((ISERROR(SEARCH("shine",rng)))+(ISERROR(SEARCH("n on",rng)))0) The wildcards weren't really doing anything. -- Biff Microsoft Excel MVP wrote in message ... Hi, with the help of some excellent feedback from the User Group I have created the following formula but I am not getting the expected results The formula works finre until I put the 2nd search for a particular word.. eg This works fine =SUMPRODUCT((('Grid data'!B2:B4557=A2)*(ISERROR(SEARCH("shine*",'Grid data'!D2:D4557)*((('Grid data'!F2:F4557="NS")+('Grid data'! F2:F4557="C")+(TRIM('Grid data'! F2:F4557)=""))))))) And counts correctly, ignoring anything with SHINE in column D and only including, blanks, C and NS values. The following formula I am not getting the right results. It appears to be ignoring the search for "NON" in column E. =SUMPRODUCT((('Grid data'!B2:B4557=A2)*(ISERROR(SEARCH("shine*",'Grid data'!D2:D4557)+(SEARCH( "non*",'Grid data'!E2:E4557))*((('Grid data'! F2:F4557="NS")+('Grid data'!F2:F4557="C")+(TRIM('Grid data'! F2:F4557)=""))))))) Paul |
#3
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Paul,
Guess this earlier reply (in.misc) didn't quite take care of it ? -------------- Maybe try changing this part of it in your expression to: ... *(ISERROR(SEARCH("shine*",'grid data'!D2:D4557))*(ISERROR(SEARCH("non*",'grid data'!E2:E4557))* ... ------------- -- Max Singapore http://savefile.com/projects/236895 xdemechanik --- |
#4
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Not *exactly* sure of what you're trying for,
but...maybe this: This formula tests if: ((Col_B=A2 and Col_D does NOT contain "shine") OR Col_E contains "non") AND Col_F is any of "NS","C", or "" (in sections for readability): =SUMPRODUCT(--( ((('Grid data'!B2:B4557=A2)*ISERROR(SEARCH("SHINE",'Grid data'!D2:D4557))+ ISNUMBER(SEARCH("NON",'Grid data'!E2:E4557)))0)* (TRIM('Grid data'!F2:F4557)={"NS","C",""})0)) Does that help? -------------------------- Regards, Ron Microsoft MVP (Excel) (XL2003, Win XP) wrote in message ... Hi, with the help of some excellent feedback from the User Group I have created the following formula but I am not getting the expected results The formula works finre until I put the 2nd search for a particular word.. eg This works fine =SUMPRODUCT((('Grid data'!B2:B4557=A2)*(ISERROR(SEARCH("shine*",'Grid data'!D2:D4557)*((('Grid data'!F2:F4557="NS")+('Grid data'! F2:F4557="C")+(TRIM('Grid data'! F2:F4557)=""))))))) And counts correctly, ignoring anything with SHINE in column D and only including, blanks, C and NS values. The following formula I am not getting the right results. It appears to be ignoring the search for "NON" in column E. =SUMPRODUCT((('Grid data'!B2:B4557=A2)*(ISERROR(SEARCH("shine*",'Grid data'!D2:D4557)+(SEARCH( "non*",'Grid data'!E2:E4557))*((('Grid data'! F2:F4557="NS")+('Grid data'!F2:F4557="C")+(TRIM('Grid data'! F2:F4557)=""))))))) Paul |
#5
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
On Mar 14, 10:17 pm, "Ron Coderre"
wrote: Not *exactly* sure of what you're trying for, but...maybe this: This formula tests if: ((Col_B=A2 and Col_D does NOT contain "shine") OR Col_E contains "non") AND Col_F is any of "NS","C", or "" (in sections for readability): =SUMPRODUCT(--( ((('Grid data'!B2:B4557=A2)*ISERROR(SEARCH("SHINE",'Grid data'!D2:D4557))+ ISNUMBER(SEARCH("NON",'Grid data'!E2:E4557)))0)* (TRIM('Grid data'!F2:F4557)={"NS","C",""})0)) Does that help? -------------------------- Regards, Ron Microsoft MVP (Excel) (XL2003, Win XP) wrote in message ... Hi, with the help of some excellent feedback from the User Group I have created the following formula but I am not getting the expected results The formula works finre until I put the 2nd search for a particular word.. eg This works fine =SUMPRODUCT((('Grid data'!B2:B4557=A2)*(ISERROR(SEARCH("shine*",'Grid data'!D2:D4557)*((('Grid data'!F2:F4557="NS")+('Grid data'! F2:F4557="C")+(TRIM('Grid data'! F2:F4557)=""))))))) And counts correctly, ignoring anything with SHINE in column D and only including, blanks, C and NS values. The following formula I am not getting the right results. It appears to be ignoring the search for "NON" in column E. =SUMPRODUCT((('Grid data'!B2:B4557=A2)*(ISERROR(SEARCH("shine*",'Grid data'!D2:D4557)+(SEARCH( "non*",'Grid data'!E2:E4557))*((('Grid data'! F2:F4557="NS")+('Grid data'!F2:F4557="C")+(TRIM('Grid data'! F2:F4557)=""))))))) Paul Thanks Gents, all good now Paul |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
My eyes Are Tiered, Forehead Bruised, My Desk Dented.!! Help??? | Excel Discussion (Misc queries) | |||
count and return pair numbers | Excel Worksheet Functions | |||
Fonts Too Small or Eyes Too Big? | New Users to Excel | |||
How do pair different data series. | Charts and Charting in Excel | |||
in excel, how do I find which value doesn't have a pair? | Excel Discussion (Misc queries) |