title: Excel: Need to sum based on date range in two columns (between dates) over one column
body: <p>My raw data is this:</p>
  
  <p><a href="https://i.stack.imgur.com/MfdX0.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/MfdX0.png" alt="enter image description here"></a></p>
  
  <p>My desired result is this:</p>
  
  <p><a href="https://i.stack.imgur.com/y3uiI.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/y3uiI.png" alt="enter image description here"></a></p>
  
  <p>Explanation of desired result: </p>
  
  <p>So, for example if 01/07/2018 falls between the date from and date to and it's under package A, we will get the number and finally total them together. So as you can see in my raw data, 01/07/2018 belongs to Mr.X and Ms.Z, so the total sum under package A for 01/07/2018 is 2. The next date, 02/07/2018 and under package A, we have Mr.X only so the total sum is 1.</p>
  
  <p>I've tried the following formula:</p>
  
  <pre><code>=SUMIFS(D3:D9, B3:B9, "&gt;=" &amp;J3, C3:C9, "&lt;=" &amp;J3)
  </code></pre>
  
  <p>But it just resulted in 0. How can I get the correct result as shown in my desired result?</p>
  
  <p>J3 is just a dummy column with a date. For e.g 01/07/2018. D3:D9 is column package A, B3:B9 is column date from, C3:C9 is column date to</p>