Cursor cursor = db.rawQuery("SELECT id,lastname,status FROM people WHERE " + "id = "+ IncomingiD +" FROM people WHERE status =100 ); ",null);
I want to access to "status=100 and id=incomingid" of my people table. I wrote above snipped code but I am getting an error below.... What is wrong with that query ? Could you please help me ?
E/Error(996): Error while openining peopleandroid.database.sqlite.SQLiteException: near "FROM": syntax error: , while compiling: SELECT id,lastname,status FROM people WHERE id = 1 FROM places WHERE status =100 );