Hy everbody.
I need help in my query. I receive a warning but I don't know what is wrong.
android.database.sqlite.SQLiteException: no such column: title: , while compiling: SELECT _id, display_name FROM view_data_restricted data WHERE (1) AND (account_name='ricardofilipe19@gmail.com' AND title!=GrupoSocios AND mimetype='vnd.android.cursor.item/group_membership' AND display_name like '%rui%') ORDER BY DISPLAY_NAME
here is my code
return getContentResolver().query(Data.CONTENT_URI,
new String[]{ContactsContract.Contacts._ID, ContactsContract.Contacts.DISPLAY_NAME},ContactsContract.Groups.ACCOUNT_NAME + "='" + accountName + "' AND " + ContactsContract.Groups.TITLE + "!=" + nomeGrupo + " AND " + Data.MIMETYPE + "='" + GroupMembership.CONTENT_ITEM_TYPE + "' AND " + ContactsContract.Contacts.DISPLAY_NAME + " like '%" + filter + "%'" ,
null,
"DISPLAY_NAME");
Thanks for your help.