Published on

October 5, 2013

Understanding Key-Value Pair and Document Databases in SQL Server

In yesterday’s blog post, we learned about the importance of relational and NoSQL databases in the Big Data story. In this article, we will delve into the role of Key-Value Pair Databases and Document Databases in supporting Big Data.

Key-Value Pair Databases

Key-Value Pair Databases, also known as KVP databases, are a type of NoSQL database. In these databases, a key is a field name and attribute that serves as an identifier, while the value represents the data being stored. Unlike relational databases, KVP databases do not have a fixed schema, making them highly flexible and scalable.

However, one disadvantage of KVP databases is that they do not adhere to the ACID (Atomicity, Consistency, Isolation, Durability) properties. Additionally, data architects need to carefully plan for data placement, replication, and high availability in KVP databases. The data in KVP databases is stored as strings.

Here is a simple example of how a Key-Value Database might look:

KeyValue
NamePinal Dave
ColorBlue
Twitter@pinaldave
NameNupur Dave
MovieThe Hero

As the number of users grows in Key-Value Pair databases, managing the entire database becomes increasingly challenging. Without a specific schema or rules associated with the database, there is a risk of exponential database growth. It is crucial to select the right Key-Value Pair Database that offers additional tools for data management and provides finer control over various business aspects.

Riak is one of the most popular Key-Value Databases known for its scalability and performance in high volume and velocity databases. It also implements a mechanism for collecting keys and values, which further aids in building a manageable system.

Key-Value Databases are a good choice for social media platforms, communities, and caching layers for connecting other databases. They offer flexibility in data storage while keeping scalability in mind.

Document Databases

Document Databases come in two different types: full document content (such as web pages and word documents) and storing document components for storage. In this article, we will focus on the latter type, which uses JavaScript Object Notation (JSON) and Binary JSON for structuring the documents.

JSON is a simple and easy-to-understand language, making it convenient for application development. There are two major structures of JSON used in Document Databases: Name-Value Pairs and Ordered Lists.

MongoDB and CouchDB are two of the most popular open-source non-relational Document Databases. MongoDB databases are called collections, each composed of documents that consist of fields. MongoDB collections can be indexed for optimal performance and offer a highly available ecosystem with support for query services and MapReduce. It is often used in high-volume content management systems.

CouchDB databases are composed of documents that consist of fields and attachments. CouchDB supports ACID properties and can continue to operate even with sketchy network connectivity. Due to this nature, CouchDB prefers local data storage.

Document Databases are a good choice when users need to generate dynamic reports from elements that are changing frequently. They are commonly used in real-time analytics in social networking or content management systems.

Stay tuned for tomorrow’s blog post, where we will discuss various other operational databases supporting Big Data.

Click to rate this post!
[Total: 0 Average: 0]

Let's work together

Send us a message or book free introductory meeting with us using button below.