Docs Menu
Docs Home
/
MongoDB Cloud Manager
/ /

Manage Documents in Data Explorer

On this page

  • Go to the Deployment page for your project.
  • Go to the Data tab
  • Required Roles
  • View Documents
  • Insert Documents
  • Edit One Document
  • Delete One Document

You can use the Data Explorer to manage documents inside your cluster collections.

To interact with data in the Cloud Manager UI:

1
  1. If it is not already displayed, select the organization that contains your desired project from the Organizations menu in the navigation bar.

  2. If it is not already displayed, select your desired project from the Projects menu in the navigation bar.

  3. If the Deployment page is not already displayed, click Deployment in the sidebar.

2
  1. Select the desired MongoDB deployment.

  2. Select the Data tab.

To insert, edit, or delete documents, you must have been granted access through one of the following roles:

From the Collections tab, you can view documents in a collection. To view documents for a collection:

1

The main panel and Namespaces on the left side list the collections in the database.

Screenshot highlighting databases in Data Explorer.
click to enlarge
2

The main panel displays the Find view and the Indexes view.

3

The panel displays the documents in the collection. Each page displays up to 20 documents.

4

You can use the query bar to search for specific documents in your collection. You can specify one or more of the following in the query bar:

  • A filter condition

  • A project document to include and exclude specific fields in the results

  • A sort order for the documents in the results

  • A collation document for language specific rules.

Note

As you type, the Apply button is disabled and the field name in the User Interface turns red until a valid query is entered.

5

Cloud Manager limits the total byte size of documents shown per page in the Data Explorer. As a result, you may see varying numbers of documents per page, especially if your documents vary significantly in size.

To add one or more documents to a collection through the Data Explorer, you can specify the document(s) to insert from scratch or you can clone an existing document and modify its fields and values as needed.

1

Select the collection and go to the Find tab.

2

The document editor appears with the _id field with an ObjectId value that reflects the time of its generation and not the insertion time of the document. As such, the ObjectId does not represent a strict insertion order.

3
  • To add a new field after an existing field, hover over the field and click on the plus sign that appears over the field's line number.

  • To delete a field, hover over the field and click on the x sign that appears to the left of the field's line number. You cannot delete the _id field.

  • To edit a field name, value, or type, click on the field name, value, or type.

4
1

Select the collection and go to the Find tab.

2

Data Explorer opens the Insert to Collection dialog.

3
4

Example

The following array of documents inserts three documents into the collection:

[
{
"name": "Alice",
"age": 26,
"email": "alice@abc.com"
},
{
"name": "Bob",
"age": 43,
"email": "bob@def.com"
},
{
"name": "Carol",
"age": 19,
"email": "carol@xyz.com"
}
]
5
1

Select the collection and go to the Find tab.

Up to 20 documents displays in the tab.

2

To specify filter condition, type in a query filter document in the filter bar. For example, to specify equality condition, use a filter document of the form:

{ <field1>: <value1>, ... }

To use query operators to specify a filter condition, use a filter document of the form:

{ <field1>: { <queryoperator>: <value1> }, ... }
3

To clone a document displayed in the query results, hover over the document and click on its clone document icon.

Clone document icon

The document editor appears with the _id field with an ObjectId value that reflects the time of its generation and not the insertion time of the document. As such, the ObjectId does not represent a strict insertion order.

4
  • To add a new field after an existing field, hover over the field and click on the plus sign that appears over the field's line number.

  • To delete a field, hover over the field and click on the x sign that appears to the left of the field's line number. You cannot delete the _id field.

  • To edit a field name, value, or type, click on the field name, value, or type.

5

To edit a document from a collection through the Data Explorer:

1

Select the collection and go to the Find tab.

Up to 20 documents displays in the tab.

2

To specify filter condition, type in a query filter document in the filter bar. For example, to specify equality condition, use a filter document of the form:

{ <field1>: <value1>, ... }

To use query operators to specify a filter condition, use a filter document of the form:

{ <field1>: { <queryoperator>: <value1> }, ... }
3

To edit a document displayed in the query results, hover over the document to edit and click on the pencil icon.

The document appears in the document editor:

  • To add a new field, hover over the field and click on the plus sign that appears over the field's line number.

  • To delete a field, hover over the field and click on the x sign that appears to the left of the field's line number. You cannot delete the _id field.

  • To edit a field name, value, or type, click on the field name, value, or type.

  • To revert a specific change, hover over the edited field and click the revert icon that appears to the left of the field's line number.

4

To confirm and save changes, click the Update button.

To cancel all modifications to the document, click the Cancel button.

To delete a document from a collection through the Data Explorer:

1

Select the collection and go to the Find tab.

Up to 20 documents displays in the tab.

2

To specify filter condition, type in a query filter document in the filter bar. For example, to specify equality condition, use a filter document of the form:

{ <field1>: <value1>, ... }

To use query operators to specify a filter condition, use a filter document of the form:

{ <field1>: { <queryoperator>: <value1> }, ... }
3

To delete a document displayed in the query results, hover over the document to delete and click on the trash can icon.

The document is flagged for deletion.

4
← Manage Databases and Collections in Data Explorer