As the title suggests I'm trying to show which rows in my spreadsheet contain a certain criteria, in this case those which are D(eliver), have a Quantity of more than 0 and have a haulage level of 0.
My sumproduct formula shows a 1 if these criteria are fulfilled and I'm able to use the Small array formula to list which rows contain 1 however I'd like a cleaner way of doing it.
Ideally I'd like the sumproduct formula (or equivalent) to be within the Small formula but when I try this it just fails.
Any help is appreciated.
Thanks!
Excel 2007<table rules="all" style=";background-color: #FFFFFF;border: 1px solid;border-collapse: collapse; border-color: #A6AAB6" cellpadding="2.5px"><colgroup><col style="background-color: #E0E0F0" width="25px"><col><col><col><col><col></colgroup><thead><tr style=" background-color: #E0E0F0;text-align: center;color: #161120"><th>
</th><th>A</th><th>B</th><th>C</th><th>D</th><th>E</th></tr></thead><tbody><tr><td style="color: #161120;text-align: center;">1</td><td style="text-align: right;;">123</td><td style=";">Collect / Deliver</td><td style=";">Quantity</td><td style=";">Haulage</td><td style=";">Error?</td></tr><tr><td style="color: #161120;text-align: center;">2</td><td style=";">Product 1</td><td style=";">D</td><td style="text-align: right;;">41</td><td style="text-align: right;;">15</td><td style="text-align: right;;">0</td></tr><tr><td style="color: #161120;text-align: center;">3</td><td style=";">Product 2</td><td style=";">D</td><td style="text-align: right;;">11</td><td style="text-align: right;;">0</td><td style="text-align: right;;">1</td></tr><tr><td style="color: #161120;text-align: center;">4</td><td style=";">Product 3</td><td style=";">C</td><td style="text-align: right;;">2</td><td style="text-align: right;;">0</td><td style="text-align: right;;">0</td></tr><tr><td style="color: #161120;text-align: center;">5</td><td style=";">Product 4</td><td style=";">D</td><td style="text-align: right;;">0</td><td style="text-align: right;;">0</td><td style="text-align: right;;">0</td></tr><tr><td style="color: #161120;text-align: center;">6</td><td style=";">Product 5</td><td style=";">D</td><td style="text-align: right;;">33</td><td style="text-align: right;;">0</td><td style="text-align: right;;">1</td></tr><tr><td style="color: #161120;text-align: center;">7</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td></tr><tr><td style="color: #161120;text-align: center;">8</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td></tr><tr><td style="color: #161120;text-align: center;">9</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;color: #FF0000;;">
</td><td style="text-align: right;;">3</td></tr><tr><td style="color: #161120;text-align: center;">10</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;color: #FF0000;;">
</td><td style="text-align: right;;">6</td></tr></tbody></table>
<table rules="all" style=";border: 2px solid black;border-collapse:collapse;padding: 0.4em;background-color: #FFFFFF" cellpadding="2.5px" width="85%"><tbody><tr><td style="padding:6px">Worksheet Formulas<table rules="all" style="border: 1px solid;text-align:center;background-color: #FFFFFF;border-collapse: collapse; border-color: #A6AAB6" cellpadding="2.5px" width="100%"><thead><tr style=" background-color: #E0E0F0;color: #161120"><th width="10px">Cell</th><th style="text-align:left;padding-left:5px;">Formula</th></tr></thead><tbody><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E2</th><td style="text-align:left">=SUMPRODUCT((B2="D")*(C2>0)*(D2=0))</td></tr><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E3</th><td style="text-align:left">=SUMPRODUCT((B3="D")*(C3>0)*(D3=0))</td></tr><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E4</th><td style="text-align:left">=SUMPRODUCT((B4="D")*(C4>0)*(D4=0))</td></tr><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E5</th><td style="text-align:left">=SUMPRODUCT((B5="D")*(C5>0)*(D5=0))</td></tr><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E6</th><td style="text-align:left">=SUMPRODUCT((B6="D")*(C6>0)*(D6=0))</td></tr></tbody></table></td></tr></tbody></table>
<table rules="all" style=";border: 2px solid black;border-collapse:collapse;padding: 0.4em;background-color: #FFFFFF" cellpadding="2.5px" width="85%"><tbody><tr><td style="padding:6px">Array Formulas<table rules="all" style="border: 1px solid;text-align:center;background-color: #FFFFFF;border-collapse: collapse; border-color: #A6AAB6" cellpadding="2.5px" width="100%"><thead><tr style=" background-color: #E0E0F0;color: #161120"><th width="10px">Cell</th><th style="text-align:left;padding-left:5px;">Formula</th></tr></thead><tbody><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E9</th><td style="text-align:left">{=SMALL(IF($E$1:$E$7=1,ROW($A$1:$A$7)),ROW(1:1))}</td></tr><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E10</th><td style="text-align:left">{=SMALL(IF($E$1:$E$7=1,ROW($A$1:$A$7)),ROW(2:2))}</td></tr></tbody></table>Entered with Ctrl+Shift+Enter. If entered correctly, Excel will surround with curly braces {}.
Note: Do not try and enter the {} manually yourself</td></tr></tbody></table>
My sumproduct formula shows a 1 if these criteria are fulfilled and I'm able to use the Small array formula to list which rows contain 1 however I'd like a cleaner way of doing it.
Ideally I'd like the sumproduct formula (or equivalent) to be within the Small formula but when I try this it just fails.
Any help is appreciated.
Thanks!
Excel 2007<table rules="all" style=";background-color: #FFFFFF;border: 1px solid;border-collapse: collapse; border-color: #A6AAB6" cellpadding="2.5px"><colgroup><col style="background-color: #E0E0F0" width="25px"><col><col><col><col><col></colgroup><thead><tr style=" background-color: #E0E0F0;text-align: center;color: #161120"><th>
</th><th>A</th><th>B</th><th>C</th><th>D</th><th>E</th></tr></thead><tbody><tr><td style="color: #161120;text-align: center;">1</td><td style="text-align: right;;">123</td><td style=";">Collect / Deliver</td><td style=";">Quantity</td><td style=";">Haulage</td><td style=";">Error?</td></tr><tr><td style="color: #161120;text-align: center;">2</td><td style=";">Product 1</td><td style=";">D</td><td style="text-align: right;;">41</td><td style="text-align: right;;">15</td><td style="text-align: right;;">0</td></tr><tr><td style="color: #161120;text-align: center;">3</td><td style=";">Product 2</td><td style=";">D</td><td style="text-align: right;;">11</td><td style="text-align: right;;">0</td><td style="text-align: right;;">1</td></tr><tr><td style="color: #161120;text-align: center;">4</td><td style=";">Product 3</td><td style=";">C</td><td style="text-align: right;;">2</td><td style="text-align: right;;">0</td><td style="text-align: right;;">0</td></tr><tr><td style="color: #161120;text-align: center;">5</td><td style=";">Product 4</td><td style=";">D</td><td style="text-align: right;;">0</td><td style="text-align: right;;">0</td><td style="text-align: right;;">0</td></tr><tr><td style="color: #161120;text-align: center;">6</td><td style=";">Product 5</td><td style=";">D</td><td style="text-align: right;;">33</td><td style="text-align: right;;">0</td><td style="text-align: right;;">1</td></tr><tr><td style="color: #161120;text-align: center;">7</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td></tr><tr><td style="color: #161120;text-align: center;">8</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td></tr><tr><td style="color: #161120;text-align: center;">9</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;color: #FF0000;;">
</td><td style="text-align: right;;">3</td></tr><tr><td style="color: #161120;text-align: center;">10</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;;">
</td><td style="text-align: right;color: #FF0000;;">
</td><td style="text-align: right;;">6</td></tr></tbody></table>
Sheet1
<table rules="all" style=";border: 2px solid black;border-collapse:collapse;padding: 0.4em;background-color: #FFFFFF" cellpadding="2.5px" width="85%"><tbody><tr><td style="padding:6px">Worksheet Formulas<table rules="all" style="border: 1px solid;text-align:center;background-color: #FFFFFF;border-collapse: collapse; border-color: #A6AAB6" cellpadding="2.5px" width="100%"><thead><tr style=" background-color: #E0E0F0;color: #161120"><th width="10px">Cell</th><th style="text-align:left;padding-left:5px;">Formula</th></tr></thead><tbody><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E2</th><td style="text-align:left">=SUMPRODUCT((B2="D")*(C2>0)*(D2=0))</td></tr><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E3</th><td style="text-align:left">=SUMPRODUCT((B3="D")*(C3>0)*(D3=0))</td></tr><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E4</th><td style="text-align:left">=SUMPRODUCT((B4="D")*(C4>0)*(D4=0))</td></tr><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E5</th><td style="text-align:left">=SUMPRODUCT((B5="D")*(C5>0)*(D5=0))</td></tr><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E6</th><td style="text-align:left">=SUMPRODUCT((B6="D")*(C6>0)*(D6=0))</td></tr></tbody></table></td></tr></tbody></table>
<table rules="all" style=";border: 2px solid black;border-collapse:collapse;padding: 0.4em;background-color: #FFFFFF" cellpadding="2.5px" width="85%"><tbody><tr><td style="padding:6px">Array Formulas<table rules="all" style="border: 1px solid;text-align:center;background-color: #FFFFFF;border-collapse: collapse; border-color: #A6AAB6" cellpadding="2.5px" width="100%"><thead><tr style=" background-color: #E0E0F0;color: #161120"><th width="10px">Cell</th><th style="text-align:left;padding-left:5px;">Formula</th></tr></thead><tbody><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E9</th><td style="text-align:left">{=SMALL(IF($E$1:$E$7=1,ROW($A$1:$A$7)),ROW(1:1))}</td></tr><tr><th style=" background-color: #E0E0F0;color: #161120" width="10px">E10</th><td style="text-align:left">{=SMALL(IF($E$1:$E$7=1,ROW($A$1:$A$7)),ROW(2:2))}</td></tr></tbody></table>Entered with Ctrl+Shift+Enter. If entered correctly, Excel will surround with curly braces {}.
Note: Do not try and enter the {} manually yourself</td></tr></tbody></table>