Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Random r = new Random();
db.query(true, DB_TABLE, new String[] { "_id" }, "_id = ?", new String[] { String.valueOf(r.nextInt(getRowCount())) }, null, null, null, null);
private int getRowCount()
{
Cursor c = db.query(DB_TABLE, new String[] { "_id" }, null, null, null, null, null);
int count = c.getCount();
c.close();
return count;
}
You asked for this method in your question, and this gives you a random row.

