title: moveToRow() and rowCount() in FMDB?
body: <p>My app has 3,000 exam questions in .sqlite file. And these questions are dynamically selected and sorted by user's demand (for example, 'sort by count of wrong answer', 'select non-accessed questions only').</p>
  
  <p>Whenever user makes a selection, app makes corresponding SQL statement and by using sqlite3, all the result sets are sent into NSMutableArray(Question class). But as you will note, this is time-consuming process (about 2~3 secs and UI stops responding while doing so).</p>
  
  <p>So I want to make a 'cursor' class which has rowCount() and moveToRow(int index) methods. </p>
  
  <p>With this, my idea is </p>
  
  <pre><code>Cursor c = [[Cursor alloc] init] query(
      "SELECT id,qtext,answer,a1,a2,... FROM TABLE WHERE id &gt; 100"
  )]; 
      // at this time, just a cursor is given, no need to iterate all the retrieved rows
  
  for (i=0; i &gt; c.rowCount(); i++) {
      c.moveToRow(i);
      ShowQuestionDetail(c);
  }
  </code></pre>
  
  <p>Like this. </p>
  
  <p>I know that CoreData fits this purpose, but I need to share .sqlite file with android version of this app. CoreData requires all the table names and field names start with Z_ prefix, but I can't modify schemes of the .sqlite file. Also I need to use sqlcipher, and CoreData doesnt work with sqlcipher.</p>
  
  <p>FMDB doesn't support methods that gives count of retrieved rows and move to specific row. </p>
  
  <p>Is there any other SQLite wrapper libraries which supports this functionality? </p>
  
  <p>Someone suggests making an 'catalog' array which only contains id of the retrieved rows, and fetch row each time when moveToRow() called. I agree that's an good alternative, but I want to find another way.</p>