title: Get birthday for each contact in Android application
body: <p>In my android application, I read out all the contacts with the following code:</p>
  
  <pre><code>ContentResolver cr = getContentResolver();
  Cursor cur = cr.query(ContactsContract.Contacts.CONTENT_URI, null, null, null, null);
  if (cur.getCount() &gt; 0) {
      while (cur.moveToNext()) {
          String id = cur.getString(cur.getColumnIndex(ContactsContract.Contacts._ID));
          String name = cur.getString(cur.getColumnIndex(ContactsContract.Contacts.DISPLAY_NAME));
          ContentResolver bd = getContentResolver();
          String where = Data.RAW_CONTACT_ID+" = "+id+" and "+Data.MIMETYPE+" = "+CommonDataKinds.Event.CONTENT_ITEM_TYPE;
          Cursor bdc = bd.query(ContactsContract.Data.CONTENT_URI, null, where, null, null);
          if (bdc.getCount() &gt; 0) {
              while (bdc.moveToNext()) {
                  String birthday = bdc.getString(0);
                  Toast.makeText(getApplicationContext(), id+name+birthday, Toast.LENGTH_SHORT);
              }
          }
      }
  }
  cur.close();
  </code></pre>
  
  <p>This is how I tried to read out the birthday event for every single contact. But obviously it doesn't work yet. So how can I read out the contact's date of birth correctly?</p>