I have no problem in create a new ParseObject with the following code, but if I want to update the existing record, it seems like not working. Any idea?
Insert New Record
ParseObject gameScore = new ParseObject("GameScore");
gameScore.put("score", 1337);
gameScore.put("playerName", "Sean Plott");
gameScore.put("cheatMode", false);
gameScore.save();
Update Existing Record
ParseQuery query = ParseQuery.getQuery("GameScore");
query.getInBackground("objectIdHere", new GetCallback() {
public void done(final ParseObject object, ParseException e) {
if (e == null) {
object.put("playerName", "New Name");
object.save();
}
}
});
I have no problem in create a new ParseObject with the following code, but if I want to update the existing record, it seems like not working. Any idea?