title: java android error Writing exception to parcel
body: <p>Please help i want to update phone persons phone number but gets error </p>
  
  <p>06-25 17:43:57.559: ERROR/DatabaseUtils(97): Writing exception to parcel
  06-25 17:43:57.559: ERROR/DatabaseUtils(97): java.lang.UnsupportedOperationException: Unknown uri: content://com.android.contacts/contacts/1/phones</p>
  
  <pre><code>
  import android.app.Activity;
  import android.content.ContentResolver;
  import android.content.ContentUris;
  import android.content.ContentValues;
  import android.content.Intent;
  import android.database.Cursor;
  import android.net.Uri;
  import android.os.Bundle;
  import android.provider.Contacts.People;
  import android.provider.ContactsContract;
  
  @SuppressWarnings("deprecation")
  public class ChangeContacts extends Activity {
  
      @Override
      public void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.main);
          ContentResolver cr = getContentResolver();
          Cursor cur = cr.query(ContactsContract.Contacts.CONTENT_URI,
                  null, null, null, null);
          if (cur.getCount() > 0) {
          while (cur.moveToNext()) {
              String id = cur.getString(
                          cur.getColumnIndex(ContactsContract.Contacts._ID));
          String name = cur.getString(
                          cur.getColumnIndex(ContactsContract.Contacts.DISPLAY_NAME));
          System.out.println(name);
  
          if (Integer.parseInt(cur.getString(cur.getColumnIndex(ContactsContract.Contacts.HAS_PHONE_NUMBER))) > 0) {
  
  
  
  
  
              Cursor pCur = cr.query(
                      ContactsContract.CommonDataKinds.Phone.CONTENT_URI, 
                      null, 
                      ContactsContract.CommonDataKinds.Phone.CONTACT_ID +" = ?", 
                      new String[]{id}, null);
              Uri PersonUri=null;
              Uri PhoneUri = null;
              ContentValues values = new ContentValues();
                      while (pCur.moveToNext()) {
                          String phhoneNumber=pCur.getString(pCur.getColumnIndex(ContactsContract.CommonDataKinds.Phone.NUMBER));
                          String contactId=pCur.getString(pCur.getColumnIndex(ContactsContract.Contacts._ID));
                          System.out.println(contactId);
  
  
  
   PersonUri=ContentUris.withAppendedId(ContactsContract.Contacts.CONTENT_URI,Long.valueOf(contactId));
  PhoneUri = Uri.withAppendedPath(PersonUri, People.Phones.CONTENT_DIRECTORY);
  
  
  values.clear();
  
  values.put(People.Phones.TYPE,People.Phones.TYPE_MOBILE);
  values.put(People.Phones.NUMBER,"123456789");
  
  
   int upv=getContentResolver().update(PhoneUri,values, null, null); 
                          System.out.println(upv);
                      System.out.println(phhoneNumber);
                      } 
                      pCur.close();
  
  
  
  
  
              }
              }
      }
  
  
  
  
      }
  
  
  }</code></pre>