title: Retrieving group of particular contact
body: <p>I want to retrieve the contact details along with the group which it belongs to. I got the code to list all the contact groups in the phone.</p>
  
  <pre><code>Cursor groupC = getContentResolver().query(
      ContactsContract.Groups.CONTENT_URI, null, null, null, null); 
  
  while (groupC.moveToNext()) { 
      String groupid =
          groupC.getString(groupC.getColumnIndex(ContactsContract.Groups._ID));
      Log.e("myTag", groupid); 
      String grouptitle =
          groupC .getString(groupC.getColumnIndex(ContactsContract.Groups.TITLE));
      Log.e("myTag", grouptitle);
  }
  groupC.close();
  </code></pre>
  
  <p>Then I tried to query for a particular contact by using its id but it always shows <code>There is no such column...</code>.</p>
  
  <pre><code>Cursor groupC = getContentResolver().query(
      ContactsContract.Groups.CONTENT_URI,
      null,
      ContactsContract.Contacts._ID+"= ?",
      new String[]{id},
      null);
  </code></pre>
  
  <p>where id is</p>
  
  <pre><code>Cursor cur = cr.query(
      ContactsContract.Contacts.CONTENT_URI,
      null,
      null,
      null,
      null);
  id = cur.getString(cur.getColumnIndex(ContactsContract.Contacts._ID));
  </code></pre>
  
  <p>How to query the group using a particular contact id?</p>