Before we begin with the MongoDB installation, let's understand why we have chosen the MongoDB database and what it is needed for.
Let's take a look at the advantages of MongoDB over RDBMS:
- Flexible schema: MongoDB is a document database in which one collection holds multiple documents. We don't need to define the schema of the documents prior to inserting the data, which means MongoDB defines the document's schema based on the data inserted into the documents; whereas, in an RDBMS, we need to define the schema of the tables before inserting data into it.
- Less complexity: There are no complex joins in MongoDB, as we have in the case of RDBMS (for example: MySQL) databases.
- Easier scalability: It is very easy to scale out MongoDB as compared to an RDBMS.
- Fast accessibility: There is faster retrieval...