Types and Examples of NoSQL Database
There have been various approaches to classify NoSQL databases, each with different categories and subcategories.
1. Key Value Store
2. Document Store
3. Column Store
4. Graph
Key Value Store
The Key-value (KV) store system uses the concept of associative array, a their fundamental data model. In this model, data is represented as a collection of key-value pairs. Every single item in the database is stored as an attribute nanie (or 'key'), together with its value
In NoSQL database: a table exists with two
columns : one is the Key and the other is Value.
- The Key value stores allow the developer of application to store schema-less data.
Key-value databases are the simplest form of the NoSQL databases. Other advanced models are mostly extensions to this key-value model.
- Examples include Memcached, Riak, ArangoDB, InfinityDB, Oracle NoSQL Database, Redis and dbm.
All key-value databases are not similar; there are major differences between these databases. For example: Data in MemcacheDB is not persistent
important to not only choose a key-value database based on your requircmems, it is also importam to choose which key-va!ue database.
Examples of key value NoSQL database applications :
o Dynamo
o Redis
o FairCom
o MemcacheDB
0 Riak
Four main core operations perform on key-value
store:
1. Get(key) : It return the single value of given key.
2. Put(key,value) : It assigns value to key.
3. Multi-get(keyl,key2,key3,.•,keyn): It returns multiple values of given multiple keys.
4. Delete(key) : It deletes both key and value present in it.
Advantages of Key Value Store
Key value store is the simplest type of NoSQL. Supports simple queries very efficiently.
Extended fonn of key-value stores is able to sort the keys.
It is specially designed for storing data as a schema free data.
Very simple data-modeling pattern should be understandable by anyone.
With little or no maintained indexes, the key-value stores are designed to be more scalable and extremely fast
Suitable for system where data is not highly related.
Disadvantages of Key Value Store
The indexing and scanning capabilities are absent. It does not help if we want to perform more operation as per user reg_uirement than the basic CRUD (Create, Read, Update, Delete) operations.
Only one row simple queries can be executed efficiently.
Difficult to perforin SQL operations like JOINS, GROUP BY etc.
- Selecting appropriate data type for value is difficult
Difficult to use constraints like FOREIGN KEY or NOT NULL.
- More application code is required to reassemble collections of key-value.pairs into objects.
Document Store
- These databases store records as "documents" whei"e a document can generally be thought of as a grouping of key-value pairs.
- The documents are identified by the unique keys which represents them. One defining characteristics of a document-oriented database is that in addition to the key lookup performed by a key-value store, the database offers an API or query language that retrieves documents based on their con nts.
- Document datab<tses are extension to key value ''
store. Addition to query capabilities of key-value
databases, they provide indexing and the ability to I
filter documents based on attributes in the 'I
document.
- Example.<: of Document Store NoSQL database applications :
o MongoDB
o Couchbase
Advantages of Document Store
The performance is ·good and the distribution across various servers becomes a lot easier.
- There is no need of translation between object in SQL and application. The object can directly be converted into document.
- They have strong indexing features and eail rapidly execute different queries.
6.2.3 Column Store
Column store is column oriented NoSQL database. Data is stored in cells _grouped in columns of data rather than as rows of data. The logical grouping of columns is created in column families. There is no limitation on ntimber of columns in a column family.
- These columns can be created at runtime. The operations like read write are perfonned using columns rather than rows.
The column store structure gives the advantage of fast search / access and data aggregation over the row format data storage of relational database
- Relational databases store ·a single row as a continuous disk entry. Different rows are stored in different places on disk while column store database store all the cells related to a column as a continuous disk entry which makes the
search/access faster.
For example : Displaying tides from a bunch of a million articles will be a tedious and time wasting task while using relational databases as it will go over each location to get item titles. While in column store, title of all the items can be obtained with just one disk access.
Examples of column store NoSQL database
applications :
o HBase
o BgTable
o HyperTable
Advantages of Column Store
Efficient storage and data compression. Fast data loads.
Simple configuration.
Disadvantages of Column Store
Queries with table ;oms can reduce high
performance.
Transactions are to be avoided or just not
supported.
6.2.4 Graph Store
- The Graph Store NoSQL database technology is designed to handle very large sets of data which may be structured, semi-_sfructured or unstructured. /
In a Graph Base NoSQL Dataf>ase, rigid format of SQL or the tables and c iumns representation does not exists. Rather a flexible graphical representation is used which is perfect to address scalability concerns. The graph- structure contains edges, nodes and properties.
The graph store is helpful in transferring the data
from one model to other very easily.
Graph store stores the entities and relationships between these entities. Entities are also known as nodes, which have properties. Nodes represent entities such as people, businesses, accounts, or
any other item to be tracked.
They are roughly th.e equivalent of the record, relation, or row in a relationai database. or the document in a document database.
Relations are known as edges that can have properties.
Edges are denoting directions. Nodes are generally organized with the help of relationships. The data i..s stored once by the organization of graph. This data can be interpreted in different ways depending upon the relationships between nodes.
Key points related to graph store.
Edges and nodes are used by these databases to represent and store data.
- The nodes are organised with the help of some relationships in between them, which is represented by edges between the nodes.
Both the nodes and the relationships have some definite properties.
- Examples of Graph store NoSQL database applications :
o Neo4j
o Polyglot
Advantage of Graph Store
- Performance Flexibility
- Agility(ability to move quickly or easily)
Comments
Post a Comment