SQLite rawquery selectionArgs not working
i got the following rawquery
private static final String DB_QUERY_GETPOS = "select f._id, F.FName, F.FArt, P.VName, O.Gebaeude, O.Raum from Faecher as F "
+ "inner join profs as P on F.Prof_ID = P._id "
+ "inner join ort as o on F.ort_id = o._id "
+ "inner join position as PO on PO.pos=? and id is not null where f._id = PO.id and PO.pos=? order by f._id;";
Why do I get ArrayOutofBounds
exceptions when accessing a Cursor or ArrayL开发者_如何学Cist Object filled with the result of this query?
Why don't the ?
params pick up the args I pass to the rawquery?
When you work with cursors in Android, remember to use the moveToFirst function before reading the data. Otherwise it will result in ArrayOutOfBounds exceptions.
精彩评论