title: Data not getting fetched from sqlite to list view - android
body: <p>I wrote a code to fetch the data from <code>sqlite</code> to <code>ListView</code>.</p>
  <pre><code>ArrayList&lt;feedWord&gt; words = new ArrayList&lt;feedWord&gt;();
          ForumDbHelper helper = new ForumDbHelper(this);
          SQLiteDatabase db = helper.getReadableDatabase();
          String projection[] = {
                  ForumContract.ForumEntry.COLUMN_TITLE,
                  ForumContract.ForumEntry.COLUMN_USER,
                  ForumContract.ForumEntry.COLUMN_DATE,
                  ForumContract.ForumEntry.COLUMN_STATUS
          };
          String selection = ForumContract.ForumEntry.COLUMN_STATUS + &quot;=?&quot;;
          String[] selectionArgs = {&quot;1&quot;};
          Cursor cursor = db.query(ForumContract.ForumEntry.TABLE_NAME, projection,selection,selectionArgs,null,null,null);
          try {
              int userColumnIndex = cursor.getColumnIndex(ForumContract.ForumEntry.COLUMN_USER);
              int dateColumnIndex = cursor.getColumnIndex(ForumContract.ForumEntry.COLUMN_DATE);
              int titleColumnIndex = cursor.getColumnIndex(ForumContract.ForumEntry.COLUMN_TITLE);
              while(cursor.moveToNext())
              {
                  String userID = cursor.getString(userColumnIndex);
                  String date = cursor.getString(dateColumnIndex);
                  String title = cursor.getString(titleColumnIndex);
                  words.add(new feedWord(title,userID,date));
              }
          } finally {
              cursor.close();
          }
          feedAdapter itemsAdapter = new feedAdapter(this,words);
          final ListView listView = (ListView) findViewById(R.id.list);
          listView.setAdapter(itemsAdapter);  
  </code></pre>
  <p><strong>feedWord</strong></p>
  <pre><code>public class feedWord {
      private String question;
      private String username;
      private String date;
  
      public feedWord(String fquestion, String fusername, String fdate)
      {
          question = fquestion;
          username = fusername;
          date = fdate;
      }
  
      public String getQuestion()
      {
          return question;
      }
  
      public String getUsername()
      {
          return username;
      }
  
      public String getDate()
      {
          return date;
      }
  }
  </code></pre>
  <p>However this code doesn't fetch the data from sqlite. What am I missing?</p>