可以在一个查询中执行此操作吗?
据我所知,SIM联系人的内容是content://icc/adn
答案 0 :(得分:20)
这很容易! :)
Cursor cursor = mContentResolver.query(
RawContacts.CONTENT_URI,
new String[]{RawContacts._ID,RawContacts.ACCOUNT_TYPE},
RawContacts.ACCOUNT_TYPE + " <> 'com.anddroid.contacts.sim' "
+ " AND " + RawContacts.ACCOUNT_TYPE + " <> 'com.google' " //if you don't want to google contacts also
,
null,
null);