title: Power BI - Using of filters in calculate function
body: <p>Please refer below to the sample data i used:</p>
  
  <pre><code>ID  Name     Status         Dept.
  1   Austin   Pending        MES
  2   Roy      Devilered      DHA
  3   Steven   Terminated     DHA
  4   Peter    Pending        MES
  5   Sanjay   Pending        MES
  6   Domnic   Terminated     LA
  7   Leon     Devilered      MES
  8   Sanal    Devilered      LA
  9   Kevin    Terminated     LA
  10  Binoy    Pending        DHA
  </code></pre>
  
  <p>The Table name is Employee. </p>
  
  <p>I added two measures:</p>
  
  <pre><code>Count_1 =    
      CALCULATE(COUNT('Employee'[ID]),
      'Employee'[Dept.]="LA",
      'Employee'[Status]="Terminated")
  
  Count_2 = 
      CALCULATE(COUNT('Employee'[ID]),
      FILTER('Employee','Employee'[Dept.]="LA"),
      FILTER('Employee','Employee'[Status]="Terminated"))
  </code></pre>
  
  <p>Without any report layer filters, both measures return the value of 2. But when I add a report layer filter for Status in (Delivered,Pending), the count changes to</p>
  
  <p><code>Count_1</code>  gives <code>2</code></p>
  
  <p><code>Count_2</code>  gives <code>blank</code></p>
  
  <ul>
  <li>It would be really helpful if someone could explain how the filters affects the results in detail  </li>
  <li>Difference between <code>filter</code>, <code>filter(all)</code>, <code>filter(allexcept)</code> ,<code>filter(allselected)</code>  </li>
  </ul>