title: Special case for Group By counting
body: <p>Im asked to report the number of charges a provider has for the current month. The current criteria is one code means one charge. The problem I have right now is they added an exception for one of the providers; wherein if the codes that start with F or end with G and there are 4 or 5 of them for one patient on the same day of service, they only count as 3 charges.</p>
  
  <pre><code>For example (Pv2 is the one with the special case)
  Prov       Patient       ServiceDate       Code
  Pv1          Pt1           1/1/2019        99001
  Pv1          Pt2           1/4/2019        99004
  Pv1          Pt2           1/2/2019        F0001
  Pv2          Pt1           1/1/2019        F0001
  PV2          Pt1           1/1/2019        1000G
  PV2          Pt1           1/1/2019        F0012
  PV2          Pt1           1/1/2019        1003G
  PV2          Pt1           1/1/2019        F1100
  PV2          Pt2           1/4/2019        99001
  </code></pre>
  
  <p>The report should look like this</p>
  
  <pre><code>Prov         ChargeCount
  Pv1            3
  Pv2            4
  </code></pre>
  
  <p>This is my current code:</p>
  
  <pre><code>Select Prov, Count(Code)
  From Table
  Group by Prov
  </code></pre>
  
  <p>So mine outputs </p>
  
  <pre><code>Prov         ChargeCount
  Pv1            3
  Pv2            6
  </code></pre>