DEV Community

Discussion on: A-Z: MongoDB Cheat Sheet🌱

Collapse
 
billernet profile image
Bill💡

Good stuff. We replaced our legacy XML based document format with MongoDB and saw massive speed improvements in loading and querying data. I'm a big proponent of dealing with documents with large volume/size/complexity this way. One thing I would take issue with though is this:

  • Why use MongoDB?

MongoDB is a document database, which means it stores data in JSON-like documents. We believe this is the most natural way to think about data, and is much more expressive and powerful than the traditional row/column model.

While yes, it probably does let you store data in exactly the format that represents the original document, I think it is worth stating that it shouldn't be seen as a wholesale replacement for relational databases. A good rule of thumb is if to use MongoDB or any other document database, and you're finding that the document is starting to contain items which are outside the natural scope of the document to get it to work, it is not a good fit.

Define boundaries for what is stored in the document and be aware of the limitations of relationships between documents.

Collapse
 
burakboduroglu profile image
Burak Boduroğlu

Thanks for sharing this nice comment.😊