Mongo db Basics

Database

  • A database is a structured way to store and access data.

Mongo db Database

  • It is a NoSQL document database, meaning that the data is not stored in traditional notion of rows and columns, rather they are stored in documents.

  • Documents are in turn stored in collections of documents.

Document

  • A way to organize and store data as a set of field-value pairs.

  • SYNTAX

{ "field1":<value1>, "field2":<value2> }

  • Example

    {
        "name":"Joe",
        "age":26
    }

Collection

  • An organized store of documents in MongoDB, usually with common fields between documents.s

Last updated