title: Give offset result modulo 200 in sql
body: <p>I have the table <code>tbl</code> which consisted of 800 rows. And I need to write a query which is going to 200 rows as follows:</p>
  
  <p>1</p>
  
  <pre><code>SELECT id FROM tbl ORDER BY id OFFSET 100 LIMIT 200;
  </code></pre>
  
  <p>returns </p>
  
  <pre><code> id
  ----
  101
   .
   .
   .
  300
  </code></pre>
  
  <p>and it's ok, but</p>
  
  <pre><code>SELECT id FROM tbl ORDER BY id OFFSET 700 LIMIT 200;
  </code></pre>
  
  <p>returns</p>
  
  <pre><code> id
  ----
  701
   .
   .
   .
  800
  </code></pre>
  
  <p>But I need to return</p>
  
  <pre><code> id
  ----
  701
   .
   .
   .
  800
   1
   2
   .
   .
   .
  100
  </code></pre>
  
  <p>How to modify the query in order to start returning from the begining of the table when we reach the end of it? Is it possible to do without using of <code>UNION</code>?</p>