title: How does group by statement in SQL affect the results ?
body: <p>Does including an extra column in group by change the number of rows in the results ?</p>
  
  <p>I was doing a select query on a table A(col1,col2....col9) and I first included </p>
  
  <pre><code>select col1,col2,col3 
  from A where col1 = (condition) 
  group by col1, col2, col3
  </code></pre>
  
  <p>which yielded me certain number of results.</p>
  
  <p>now I changed the query to this</p>
  
  <pre><code>`select col1,col2,col3, col8,col9 
  from A where col1=(condition) 
  group by col1,col2,col3, col8,col9' 
  </code></pre>
  
  <p>and I got a different number of rows in the results. What could be the possible explanation ?</p>