0

Hi I am adding some data into database. This is how I am adding it.

String placeID = place.getId();
String placeName = place.getName();
LatLng mLocation = place.getLatLng();
double latitude = mLocation.latitude;
double longitude = mLocation.longitude;

// Insert a new place into DB
ContentValues contentValues = new ContentValues();
contentValues.put(PlaceContract.PlaceEntry.COLUMN_PLACE_ID, placeID);
contentValues.put(PlaceContract.PlaceEntry.COLUMN_PLACE_NAME, placeName);
contentValues.put(PlaceContract.PlaceEntry.COLUMN_PLACE_LATITUDE, latitude);
contentValues.put(PlaceContract.PlaceEntry.COLUMN_PLACE_LONGITUDE, longitude);
contentValues.put(PlaceContract.PlaceEntry.COLUMN_PLACE_IS_SELECTED, 1);
getContentResolver().insert(PlaceContract.PlaceEntry.CONTENT_URI, contentValues);

// Get live data information
refreshPlacesData();

What I Want:

Now I want to delete some data base on PlaceID but I do not know how to do it? Please help me and guide me how to delete data

Mark Rotteveel
  • 90,369
  • 161
  • 124
  • 175

0 Answers0