title: Efficient paging in SQLite with millions of records
body: <p>I need to show the SQLite results in a list view. Of course, I need to page the results.</p>
  
  <p>The first option is to use the LIMIT clause. For example:</p>
  
  <pre><code>SELECT * FROM Table LIMIT 100, 5000
  </code></pre>
  
  <p>It returns records 5001 to 5100. The problem is that internally SQLite "reads" the first 5000 records and it is not too efficient.</p>
  
  <p>What is the best approach for paging when there are a lot of records?</p>