title: How to apply a logical OR to an array in Excel
body: <p>I'm trying to have Excel make me an array by ORing two arrays. As an example, let two arrays <code>A1:A3</code> be <code>7</code>, <code>8</code>, <code>-3</code> and <code>B1:B3</code> be <code>4</code>, <code>-8</code>, <code>-8</code>.</p>
  
  <p>This should be fairly simple but it appears that</p>
  
  <pre><code>OR ( A1:A3 &gt; 0 ; B1:B3 &gt; 0 )
  </code></pre>
  
  <p>returns <code>TRUE</code> instead of the array I'm expecting <code>(TRUE, TRUE, FALSE)</code>.</p>
  
  <p>Of course I could use a dirty trick like</p>
  
  <pre><code>(((A1:A3 &gt; 0)*1 + (B1:B3 &gt; 0)*1) &gt;= 1) *1
  </code></pre>
  
  <p>but who would want to maintain that?</p>
  
  <p>Also, there is probably something to search around "CSE (<kbd>Ctrl</kbd>+<kbd>Shift</kbd>+<kbd>Enter</kbd>) Formulas" (<a href="http://www.mrexcel.com/articles/CSE-array-formulas-excel.php" rel="noreferrer">http://www.mrexcel.com/articles/CSE-array-formulas-excel.php</a>) but it really looks like black magic.</p>
  
  <p>Did I miss something easy?</p>
  
  <p>For those curious about it, the actual formula I'm trying to build is a little more complex of course. It's trying to count (via <code>SUMPRODUCT</code>) all rows where <code>(status == A OR status == B) AND Date = some cell</code>. The OR I'm looking for is just one array of my <code>SUMPRODUCT</code> and is not defined in cells (that would be too easy).</p>