title: how can i retrieve 2 columns data from database using one cursor
body: <p>how can i retrieve 2 columns data from database using one cursor....now i am using 2 cursors at a time  like</p>
  
  <pre><code>ArrayList&lt;String&gt; sender_array = new ArrayList&lt;String&gt;();
  ArrayList&lt;String&gt; body_array = new ArrayList&lt;String&gt;();
  
  
  messagedb=ListView.this.openOrCreateDatabase("message",0, null);
      messagedb.execSQL("CREATE TABLE IF NOT EXISTS tab2(sender INT(13),body varchar)");
  
  Cursor  cur1=mydb.rawQuery("select * from tab2", null);
  
      while(cur.moveToNext())
      {
          String sender1=cur.getString(cur.getColumnIndex("sender"));
                      sender_array.add(sender1);
      }
      cur1.close();
  Cursor  cur2=mydb.rawQuery("select * from tab2", null);
  
      while(cur.moveToNext())
      {
          String body1=cur.getString(cur.getColumnIndex("body"));
                      body_array.add(body1);
      }
      cur2.close();
  
      messagedb.close();
  </code></pre>
  
  <p>how can i use one cursor for poping out a list view?</p>