Evaluating a criteria based on grouping in another column

joseulloa22

New Member
Joined
Dec 28, 2013
Messages
30
am trying to get a formula that searches within a sales order (column A) and tells me if that sales order contains SECT or not (column C).


[TABLE="class: cms_table, width: 339"]
<tbody>[TR]
[TD]SALES ORDER[/TD]
[TD]CUSTOMER[/TD]
[TD]PLANNER[/TD]
[/TR]
[TR]
[TD="align: right"]332456[/TD]
[TD]HOME DEPOT[/TD]
[TD]SECT[/TD]
[/TR]
[TR]
[TD="align: right"]332456[/TD]
[TD]HOME DEPOT[/TD]
[TD]GATE[/TD]
[/TR]
[TR]
[TD="align: right"]332550[/TD]
[TD]THE FENCE MAKER[/TD]
[TD]POST[/TD]
[/TR]
[TR]
[TD="align: right"]332550[/TD]
[TD]THE FENCE MAKER[/TD]
[TD]GATE[/TD]
[/TR]
[TR]
[TD="align: right"]332550[/TD]
[TD]THE FENCE MAKER[/TD]
[TD]HARDWARE[/TD]
[/TR]
[TR]
[TD="align: right"]333980[/TD]
[TD]GIMMICK[/TD]
[TD]HARDWARE[/TD]
[/TR]
[TR]
[TD="align: right"]335790[/TD]
[TD]PARK FENCE[/TD]
[TD]SECT[/TD]
[/TR]
[TR]
[TD="align: right"]335790[/TD]
[TD]PARK FENCE[/TD]
[TD]POST[/TD]
[/TR]
[TR]
[TD="align: right"]336000[/TD]
[TD]HOME DEPOT[/TD]
[TD]HARDWARE[/TD]
[/TR]
</tbody>[/TABLE]



Any help is greatly appreciated

Thanks
Jose Ulloa
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
Try using COUNTIFS, e.g. for a specific sales order in E2 use this formula in F2

=IF(COUNTIFS(A:A,E2,C:C,"SECT"),"Yes","No")
 
Upvote 0
Try using COUNTIFS, e.g. for a specific sales order in E2 use this formula in F2

=IF(COUNTIFS(A:A,E2,C:C,"SECT"),"Yes","No")

Thank you much for the help.

The formula given evaluates by line item and tells me whether that line item contains SECT or not.
Would it be possible to evaluate by sales order? That is, a formula that look at the whole content of the sales order number and return whether the SO contains SECT or not.
For instance, the formula would look at SO 335790 which has two line items. Since it contains SECT it would return a "Yes" for the entire SO

Thanks
Jose Ulloa
 
Last edited:
Upvote 0
If i am not wrong it should work if you just change the formula to this:
=IF(COUNTIFS(A:A,A2,C:C,"SECT"),"Yes","No"

Then all lines with that SO get a Yes if one of the lines contains SECT
 
Upvote 0

Forum statistics

Threads
1,223,903
Messages
6,175,279
Members
452,630
Latest member
OdubiYouth

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