Answer the question
In order to leave comments, you need to log in
Is there any real point in using MongoDB instead of MySQL (question transcript in text)?
I will immediately explain the meaning of the question: I am currently studying a large topic related to Node.js and a significant part of the tutorials are written using MongoDB + Mongoose.
This bombards me unrealistically, because I am not familiar with MongoDB, and spending time studying a database in which it is impossible to select from two tables at the same time frankly breaks (that is, by my standards, MongoDB is not a BD, but don’t understand at all what).
But then I thought - maybe I'm really missing something in my reasoning? If so many people use it - maybe it makes some practical sense?
The notorious "selection speed" in this case does not play a role for me, because why do I need a high sampling rate, if the selection itself can actually be made from only one table and nothing more.
Is there anything else that gives it an advantage over MySQL?
Answer the question
In order to leave comments, you need to log in
It all depends on the data and how you will work with it. It is possible and even good to live without Monga. If you have relational data, then you need a relational database. If your data can be represented as a document and you work with the data as a document, then Monga will suit you.
The advantage of Mongi in the absence of a schema is that if the schema changes often and you have dohrelation records in a relational database, this can be a pain, although everyone has JSON support for a long time.
Also, you don't need any joins - just get the whole document at once. Sharding is easier to do. If you need to select from several collections, then you can do this in the application through separate queries.
Most people use it because it's easy, fast to develop, especially in js - throw an object and that's it. You don't have to think about patterns. Figak-figak. Someone uses it as an object cache.
I used on a project with a document data structure - one entity-aggregate, and everything else is just its parts and exists only for it. And when the composition of the fields changes frequently. And the volumes are large. One main collection and several reference collections that are cached.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question