What is MongoDB?

1 0
Read Time:1 Minute, 28 Second

MongoDB Introduction

MongoDB is an open-source, cross-platform, and distributed document-based database designed for ease of application development and scaling. It is a NoSQL database developed by MongoDB Inc.

MongoDB is not a Relational Database Management System (RDBMS). It’s called a “NoSQL” database. It is opposite to SQL based databases where it does not normalize data under schemas and tables where every table has a fixed structure. Instead, it stores data in the collections as JSON based documents and does not enforce schemas. It does not have tables, rows, and columns as other SQL (RDBMS) databases.

The following table lists the relation between MongoDB and RDBMS terminologies.

MongoDB (NoSQL Database)RDBMS (MySQL, SQL Server, Oracle, etc.)
DatabaseDatabase
CollectionTable
DocumentRow (Record)
FieldColumn

In the RDBMS database, a table can have multiple rows and columns. Similarly in MongoDB, a collection can have multiple documents which are equivalent to the rows. Each document has multiple “fields” which are equivalent to the columns. Documents in a single collection can have different fields.

The following is an example of JSON based document.

MongoDB Document

Advantages of MongoDB

  1. MongoDB stores data as JSON based document that does not enforce the schema. It allows us to store hierarchical data in a document. This makes it easy to store and retrieve data in an efficient manner.
  2. It is easy to scale up or down as per the requirement since it is a document based database. MongoDB also allows us to split data across multiple servers.
  3. MongoDB provides rich features like indexing, aggregation, file store, etc.
  4. MongoDB performs fast with huge data.
  5. MongoDB provides drivers to store and fetch data from different applications developed in different technologies such as C#, Java, Python, Node.js, etc.
  6. MongoDB provides tools to manage MongoDB databases.
Happy
Happy
100 %
Sad
Sad
0 %
Excited
Excited
0 %
Sleepy
Sleepy
0 %
Angry
Angry
0 %
Surprise
Surprise
0 %

Average Rating

5 Star
0%
4 Star
0%
3 Star
0%
2 Star
0%
1 Star
0%

Leave a Comment