title: Use limit range in yii2?
body: <p>I want to get data from db using <strong>limit 12,20</strong> . </p>
  
  <p>Here is my code:</p>
  
  <pre><code>  $Query = new Query;
     $Query-&gt;select(['um.id as USERid', 'um.first_name', 'um.last_name',   'um.email', 'COUNT(g.id) as guestCount'])
   -&gt;from('user_master um')
   -&gt;join('LEFT JOIN', 'guest g', 'g.user_id = um.id')
   -&gt;limit(12,20)
   -&gt;groupBy('um.id')
   -&gt;orderBy(['um.id' =&gt; SORT_DESC]);
  
    $command = $Query-&gt;createCommand();
    $evevtsUserDetail = $command-&gt;queryAll(); 
  </code></pre>
  
  <p>It is not working. It is giving me all rows. I also tried  <strong>->limit([12,20])</strong>, not working.   </p>
  
  <p>But when I am using  <strong>limit(12)</strong> then I am getting 12 rows. </p>
  
  <p>I want to get rows in <strong>limit 12,20</strong> . What should I have to do for that in my this code?</p>