Editing an Entity in the Console

This page describes how to edit an entity using the Google Cloud Platform Console.

To learn how to modify an entity programmatically, see Updating an entity.

Before you begin

This page assumes you have already created an entity that is stored in Google Cloud Datastore. You can create an entity through the Cloud Datastore API as described in Getting Started with the Google Cloud Datastore API, or through the entity editor in the Cloud Platform Console as described in Quickstart.

Selecting an entity to edit

  1. Go to the Datastore Entities page in the Cloud Platform Console.
    Go to the Datastore Entities page
  2. Find the entity you want to edit by specifying the namespace, kind, and/or filters for property values. To learn how, see Run a query.
  3. Click an entity to edit. Your screen should look similar to the following:

    Entity editor

Editing a property

  1. Under Properties, click the property to edit.
  2. In the Edit property pane, modify the property's Name, Type, and/or Value. You can also modify whether the property is indexed. (To learn about the impact of including or excluding a property from indexes, see Excluded properties.)

    Editing a property

  3. Click Done to close the Edit property pane.

  4. Click Save to save the entity.

    Changes made to a property are not stored in Cloud Datastore until you click Save.

Adding a property

  1. Click the Add property button.
  2. In the New property pane, specify a name for the property.
  3. Select a type for the property's data type.
  4. Optionally, specify a value for the property.
  5. Specify whether the property is indexed. To learn about the impact of including or excluding a property from indexes, see Excluded properties.

    Adding a property

  6. Click Done to close the New Property pane.

  7. Click Save to save the entity.

    Changes made to a property are not stored in Cloud Datastore until you click Save.

Deleting a property

When you save an entity, any properties listed as pending deletion will be permanently deleted.

  1. Under Properties, mouse over the property to delete. The delete icon will appear.

    Deleting an property

  2. Click the delete icon.

Alternatively, instead of mousing over a property to see the delete icon, you can click a property to open the Edit property pane and then click the delete icon.

You cannot undo a property deletion once you save your entity. However, if you have not yet saved your entity, you can still cancel a pending deletion:

  • Under Properties, click Undo for the property that is pending deletion.

    Undoing a property delete

When you are done deleting a property or canceling a pending deletion, click Save to save the entity.

Saving an entity

  • Click Save.

    Saving an entity

Complex properties

The entity editor supports properties with complex types such as Array and Embedded entity.

Array properties

When you add or modify the value of an Array property, provide a value in JSON format.

Array property

If you enter invalid JSON for the Value field you will receive an error message. You will not be able to save an entity if it has invalid JSON for an array property.

Embedded entity properties

When you add or modify the value of an Embedded entity property, provide a value in JSON format.

Embedded entity property

If you enter invalid JSON for the Value field you will receive an error message. You will not be able to save an entity if it has invalid JSON for an embedded entity property.

What's next

Send feedback about...

Cloud Datastore Documentation