DEV Community

Cover image for Everyone knows that you can have relations in MongoDB, right?
Dmitriy A.
Dmitriy A.

Posted on

1

Everyone knows that you can have relations in MongoDB, right?

Relations are just _id of other objects from the same or another collection. In MongoDB, collections of objects are just like tables of rows in RDB.

Collections are just like tables with different columns on each row and the option to have nested tables.

Fun fact: In production, 99% of collections have the structure of a table. Unique "denormalization" in MongoDB is used only where it implements the unique task.

Top comments (0)

Sentry image

See why 4M developers consider Sentry, “not bad.”

Fixing code doesn’t have to be the worst part of your day. Learn how Sentry can help.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay