title: Update raw contact in Android when you have only the contact id
body: <p>In Android, when the user selects one contact using the contact picker, you get only the CONTACT_ID field. But for updating some contact info, you need to edit the raw contact data. To do so, you have to know the RAW_CONTACT_ID. Is this correct so far?</p>
  
  <p>So how do you get the RAW_CONTACT_ID that you need for updating data when you have only the CONTACT_ID? Like this ... ?</p>
  
  <pre><code>String[] projection = new String[] { ContactsContract.RawContacts._ID };
  String where = ContactsContract.RawContacts.CONTACT_ID + " = ?";
  String[] selection = new String[] { String.valueOf(contactId) };
  Cursor c = getContentResolver().query(ContactsContract.RawContacts.CONTENT_URI, projection, where, selection, null);
  </code></pre>
  
  <p>But this way you will get <em>all</em> the RAW_CONTACT_IDs belonging to the picked user, right? Which one is then the raw contact that I should update?</p>
  
  <p>If you want to say "It's up to you": It's all the same to me. I just want to put my data <em>anywhere</em>, in any raw contact that can hold the data.</p>