SQLite cursor遍历

Cursor cursor = db.rawQuery(sql, args);
while (cursor.moveToNext()) {
	int id = cursor.getInt(cursor.getColumnIndex("id"));
	String name = cursor.getString(cursor.getColumnIndex("name"));
}

你可能感兴趣的:(sqlite,Cursor)