Skip to content
Monghoul

Edit a document in production without an accident

The settings to turn on before you point this at something that matters, and what each one actually stops.

Checked against v1.11.0 Updated
The delete-collection confirmation on a write-protected target, opening with the sentence that names the connection and the collection the protection covers, and a red Confirm button
Write protection · The confirmation names what is protected before it asks

Do this once per production connection, before the first time you need it.

1. Write protection, scoped

Turn it on for the connection, and narrow it to the databases and collections that matter if the connection also holds things you edit freely.

It covers inserts, updates, deletes, bulk writes, drops, renames, index changes and the aggregation stages that write. Every entry point asks, including the keyboard and the builder’s own stage preview.

The block is enforced at the driver, not by reading your query, so a destructive call built at runtime out of a variable is still refused. Write protection explains why that distinction is the whole point.

2. A colour

Connection colours propagate to the tab strip and the sidebar. The tab tells you which cluster you are about to write to, before you press Ctrl+Enter. This is the cheapest safety feature here.

3. A result cap

Each connection has a result cap, 1,000 documents by default. An explicit .limit() wins over it even when larger, so the cap protects you from the query you did not think about rather than from the one you did.

4. A MongoDB user that cannot do the damage

Everything above protects you from yourself inside this app. None of it changes what your credentials can do. If the user you connect with can drop a collection, it can still drop one from mongosh.

For a real boundary, connect to production with a read-only user and keep a separate profile for the rare write. Users and roles manages those from inside the app.

When you do edit

  • Double-click a cell to edit in place, with a type selector so a number does not silently become a string.
  • Use the preview drawer, Ctrl+I, to read the whole document before changing one field of it.
  • Compare two documents side by side before overwriting one with the other (Pro).
  • The operation log records what ran, with its duration and outcome, which is what you read afterwards when someone asks what happened.

Next