String[] ids = new String[]{"1","2","3","4"};
Cursor emailCur = getContentResolver().query(
ContactsContract.CommonDataKinds.Email.CONTENT_URI,
null,
ContactsContract.CommonDataKinds.Email.CONTACT_ID + " = ?",
ids, null);
I think it should be problem of the included parameter.
I tried to put there
String[] ids = new String[]{"(1,2,3,4)"};
// or
String[] ids = new String[]{"('1','2','3','4')"};
and tried that with changing + " = ?", to + " IN ?",, didn’t worked at all…
I’d like to select all rows with ID in ARRAY, How am I supposed to do that?
I suspect that what you are trying to do isn’t easily achievable.
Having said that I would tackle the problem by using your original code but changing the where clause to be:
You will have to add a
?mark for each id value you wish to specify in theINclause using a for-loop