MongoDB - NoSQL Database types
There are many types of NoSQL
databases. Not all NoSQL databases operate under the same principles, but
many of them fall under one of many broad categories.
Document stores:
In document store type documents
are usually stored in a structured format such as XML or JSON or some other
standardized format that can be queried. Documents are usually organized
into collections or databases.
This allows you to group
similar documents all together. Individual documents can have unique
structures. You don't have to have the same fields in each document. Each
document usually has a specific key. This allows you to retrieve the document
quickly, and normally it's possible to query a document by the specific fields
contained inside.
Key-value stores:
Key-value stores have a key you
can query by, and then there's a specific value at that key. However,
you usually can't query by anything other than the key. Some key-value
stores let you define more than one key though, which can help you
get around the drawback. Key-value stores are sometimes used
alongside relational databases for caching.
BigTable/tabular databases:
BigTable/tabular databases are
named after Google's proprietary BigTable implementation.
Each row in a tabular database
can have a different set of columns. Tabular databases are designed for
large numbers of columns in each row, and rows are typically versioned. They’re
also graph databases. Graph databases are designed for data that's best
represented as interconnected nodes. So for example, if you have a series
of rowed intersections that you want to keep in a database, a graph
database is a good way of doing that.
Object databases:
Object databases are tightly
integrated with object-oriented programming languages. Object databases act as
a persistence layer. You store the objects from your programming language
directly into the object database. You can also link objects together through
pointers. While document databases do not necessarily enforce a
specific data structure, they typically give the capability of querying
and indexing against fields within each document.