Thomas Zahn

About Thomas Zahn

Having grown up with a living room that was essentially the office of his mother’s software start-up in the 80s, Thomas is a dyed-in-the-wool software engineer. In the past, he has worked for large outfits such as Microsoft Research and Nokia as well as for specialised engineering shops and start-ups. He lives in Berlin with his wife and two kids, and loves tennis and hiking (though, bizarrely, he constantly seems to find no time to do much of either those two). Thomas holds a Ph.D. in Computer Science from the Freie Universität Berlin.

How to Grant MongoDB Roles to Multiple Users

In MongoDB, users are defined for specific databases. Each user is then assigned a list of roles that in turn define the user’s privileges. Not surprisingly, MongoDB’s API therefore makes it easy to assign a user a list of roles via the grantRolesToUser method: db.grantRolesToUser( "<username>", [ <roles> ], { <writeConcern> } ) However, MongoDB’s [...]

How to Prevent a MongoDB Connection Timeout

If you've connected to a hosted MongoDB instance, chances are you've experienced the odd connection timeout or drop. After a relatively short period of inactivity, you might try to run a query from within Studio 3T but are presented with a server error message box. If you try again, the query will work properly again. The [...]

How to Limit the Initial Number of Documents Loaded in a MongoDB Collection

By default, Studio 3T loads the first 50 documents of a collection (i.e. dbCursor.find({}).limit(50)) when first opening a collection view. As MongoDB documents can be up to 16MB in size, this can amount to serious traffic, so we've introduced a convenient way of limiting this initial number of documents either for all or specific collections. Limit [...]

Updating and Querying MongoDB Arrays

Introduction The $type Query Operator and Arrays $type Array Inconsistencies Detecting MongoDB Array Fields Common Operations Impacted by Arrays Conclusion Update: If you work with MongoDB data with lots of arrays and embedded fields, make sure to check out our improved Table View. It lets you step into array-valued columns, show nested fields next to parent [...]

How to List MongoDB Users by Role

In this tutorial, we will see how to easily find and list all users that have been granted a specific role in MongoDB using our GUI, Studio 3T. In MongoDB, users are defined for specific databases. Each user is then assigned a number of roles that in turn define the user’s privileges. While MongoDB’s API [...]

How to Update a MongoDB Field In-Place

Updating the value of a particular field in a document is incredibly simple with Studio 3T (formerly MongoChef). Thanks to our In-Place Editing feature, you can edit fields directly in-place in the Tree and Table views. Download it now, in case you haven't yet: Try Studio 3T Get Download Link for Later First, [...]

How to Add and Modify a MongoDB Index

In this post, we'll take a look at how to add a MongoDB index and modify existing ones using Studio 3T. Download our MongoDB GUI now and let's get started. Add a New Index Display Available Index Fields Text Index Options Geo Index Options Partial Index Options Overwrite JSON Code Use Custom Collation Modify a MongoDB [...]

Setting Up MongoDB User Authentication

It goes without saying that you need to secure your MongoDB instances. Leaving aside complementary network-level security such as VPNs or SSH, MongoDB 3.0 itself provides robust built-in user authentication that governs and restricts what users can and cannot see and do inside your MongoDB instances. At the very least, you should run your MongoDB [...]

Load More Posts