M
M
Max Payne2018-12-17 12:41:24
NoSQL
Max Payne, 2018-12-17 12:41:24

Is it logical to build a complex structure in MongoDB?

Let's say I have a structure that can be implemented in one users collection containing information about the user + nested array clusters, which, in turn, contains information about the cluster and another nested array bots, which contains information about the bots of the cluster, and so on.
1. Should it be implemented as a single collection with a ten-level array, getting only the desired output using $filter, or is it not the MongoDB-way and still makes sense to do several collections with different data types containing the ObjectID of related documents?
2. Maybe there is another NoSQL database that is more suitable for such structures?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
P
pcdesign, 2018-12-17
@YardalGedal

It is logical and you can build complex structures in Mongo.
But IMHO, it's worth taking some kind of framework for this.
For example, python has
the mongoengine.org framework

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question