Repository navigation
Updating single field of a model #1588
Copy link
Copy link
Closed
Labels
api: datastoreIssues related to the Datastore API.Issues related to the Datastore API.type: questionRequest for information or clarification. Not an issue.Request for information or clarification. Not an issue.
Description
Activity
- addedtype: questionRequest for information or clarification. Not an issue.Request for information or clarification. Not an issue.api: datastoreIssues related to the Datastore API.Issues related to the Datastore API.
on Sep 12, 2016 You have to do a manual "get and update", which would look like:
var key = ds.key(['Team', team_id]); ds.get(key, function(err, entity) { if (err) { // Error handling omitted. } entity.data.field_c = newCount; ds.save({ key: key, data: entity.data }, function(err) { if (!err) { // Record saved successfully. } }); });
Thanks, that solved the overwriting issues, but it doesn't work with ComputedProperty. Any ideas how to make that work too?
@MeLight Did you try to fetch the data after doing a save? Per the upstream docs it looks like the stored value is ignored and they re-compute the property when you next read from Datastore.
- added a commit that references this issue
on Feb 3, 2026 - added 2 commits that reference this issue
on Feb 24, 2026 - added a commit that references this issue
on Mar 17, 2026 - added a commit that references this issue
on Mar 18, 2026 - added a commit that references this issue
on Mar 27, 2026
Metadata
Metadata
Assignees
Labels
api: datastoreIssues related to the Datastore API.Issues related to the Datastore API.type: questionRequest for information or clarification. Not an issue.Request for information or clarification. Not an issue.

I have model with multiple fields. The model in the Python App Engine app looks like this:
When running this code from the Node.js part of the app:
I get fields
field_aandfield_bdeleted from the model. How can I update only one field of the object without deleting the other fields?Thanks