JSON View

JSON View displays documents within a collection in JSON.

Basics

To select JSON View, use the drop-down list on the top-right of the Result tab:

Expand and collapse documents in JSON View.

Format JSON Data

Click the settings icon to the right of the drop-down list where you selected JSON View and choose your desired formatting option: MongoDB Shell Format, Legacy Mongo Shell Format, Simple Format, Mongoexport Format, and Pure, without MongoDB types.

Edit JSON data

To edit a document (for example, field name or value) while in JSON View:

  • Button – Click on the Edit button in the toolbar.
  • Right-click anywhere in the Result Tab and choose Document > Edit Document (JSON).
  • Shortcut – Press Ctrl + J (⌘+ J) to edit the document.

This will open the Document JSON Editor dialog.

Edit and update a MongoDB document in JSON View.

Make the desired changes and click Update.

Validate JSON data

JSON View has a built-in validation mechanism which ensures edits are correct.

To validate edits, click Validate. The JSON Validation dialog will flag any errors in the query.