title: Yii2 : How to write distinct SQL query?
body: <p>I want to implement following SQL queries in Yii 2 but with no success.</p>
  
  <p>This should give total number of unique company names:</p>
  
  <pre class="lang-sql prettyprint-override"><code>SELECT count(DISTINCT(company_name)) FROM clients
  </code></pre>
  
  <p>And this should display <code>company_name</code> with <code>client code</code> and <code>id(PK)</code>:</p>
  
  <pre class="lang-sql prettyprint-override"><code>SELECT (DISTINCT(company_name,client_code)) FROM clients
  </code></pre>
  
  <p>How to achieve this?</p>