title: Can I return this sql query on one line?
body: <p>I'm trying to query some info and have it display on one line. What I have is Tax info for my clients. I am looking to return the company name and the number of state filings and the number of county filings we do for them. I get an error asking me to include 'description' and 'tcode' in my group by but when I do that I only get 1 as a count. Also i'm getting several rows of info and it ends up showing like this </p>
  
  <pre><code>co  StateFilingCount    LocalFilingCount
  Co  NULL    NULL
  Co  NULL    1
  Co  1   NULL
  
  
  SELECT DISTINCT CT.co, 
  CASE WHEN description LIKE '%SITW' THEN COUNT(tcode) END AS StateFilingCount, 
  CASE WHEN tcode LIKE '__-%' THEN COUNT(tcode) END AS LocalFilingCount FROM CTax CT
  WHERE tcode NOT LIKE 'ss-%' AND CT.endDate &gt; GETDATE()
  GROUP BY CT.co
  ORDER BY CT.co ASC
  </code></pre>