0% found this document useful (0 votes)
2 views4 pages

NoSQL DATABASE-B

NoSQL databases are non-relational data management systems that allow for flexible data storage without a fixed schema, making them suitable for handling large volumes of distributed data. They come in various types, including key-value, graph, document-oriented, and column-family databases, each with unique attributes and use cases. While NoSQL offers benefits like high performance and scalability, it also has drawbacks such as being purpose-specific and lacking a universal query language.

Uploaded by

AGAPECYBERS
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views4 pages

NoSQL DATABASE-B

NoSQL databases are non-relational data management systems that allow for flexible data storage without a fixed schema, making them suitable for handling large volumes of distributed data. They come in various types, including key-value, graph, document-oriented, and column-family databases, each with unique attributes and use cases. While NoSQL offers benefits like high performance and scalability, it also has drawbacks such as being purpose-specific and lacking a universal query language.

Uploaded by

AGAPECYBERS
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

NoSQL DATABASES

NoSQL database stands for "Not Only SQL" or "Not SQL.

NoSQL Database is a non-relational Data Management System that does not require a fixed
schema. It avoids joins, and is easy to scale. The major purpose of using a NoSQL database is for
distributed data stores with humongous data storage needs. NoSQL is used for Big data and real-
time web apps. For example, companies like Twitter, Facebook and Google collect terabytes of
user data every single day.

While traditional RDBMS uses SQL syntax to store and retrieve structured data, NoSQL
database system encompasses a wide range of database technologies that can store structured,
semi-structured, unstructured and polymorphic data.

The concept of NoSQL databases became popular with Internet giants like Google, Facebook,
Amazon, etc. who deal with huge volumes of data. The system response time becomes slow
when RDBMS is used for massive volumes of data.

Characteristics of NoSQL databases

a. Non-relational- NoSQL databases never follow the relational model. It therefore means
that there are no tables with flat fixed columns & records, does not require object-
relational mapping and data normalization, no complex features like query languages,
query planners, referential integrity joins, ACID properties among others.
b. Schema- free- unlike relational databases, NoSQL databases either are schema-free or
have relaxed schemas. They don’t require any sort of definition of the schema of the data
and offer heterogeneous structures of data in the same domain
c. Simple API- NoSQL databases offers easy to use interfaces for storage and querying
data. The APIs allow low-level data manipulation & selection methods with text-based
protocols mostly used with HTTP REST with JSON. The APIs are Web-enabled to allow
the databases run as internet-facing services.
d. Distributed- Multiple NoSQL databases can be executed in a distributed fashion with the
provision for auto-scaling and fail-over capabilities. The relational ACID properties are
often sacrificed for scalability and throughput. There is no synchronous replication
between distributed nodes but rather asynchronous Multi-Master Replication, peer-to-
peer, HDFS Replication. The most important aspect is eventual consistency. The shared
Nothing Architecture enables less coordination and higher distribution.

Types of NoSQL databases


NoSQL Databases are mainly categorized into four types. Every category has its unique
attributes and limitations. None of them is better to solve all the problems. However users should
select the database based on their product needs.
a. Key Value
Examples Redis, Riak
They work best for shopping cart contents.

b. Graph Databases
Examples Neo4j, GraphDB
Graph base database mostly used for social networks, logistics, spatial data among others.

c. Document oriented
Examples MongoDB, CouchDB
The document type is mostly used for CMS systems, blogging platforms, real-time
analytics & e-commerce applications. It should not be used for complex transactions
which require multiple operations or queries against varying aggregate structures.

d. Colum family
Examples Cassandra, HBase
Column-based NoSQL databases are widely used to manage data warehouses, business
intelligence, CRM, Library card catalogs among others.

Benefits of NoSQL databases

1. Horizontal scalable and cheap


While SQL data is stored as rows grouped inside tables, NoSQL data is stored as individual, self-
contained units inside various structures like documents, dictionaries, columns, and graphs. This
allows NoSQL data to reside on multiple machines. As data quantities increase, NoSQL
databases can grow by adding more smaller devices (horizontal scaling), unlike their SQL
counterparts, which require expensive hardware upgrades (vertical scaling). This makes the
NoSQL database well suited for big-data scenarios like storing continuous data from IoT sensors.

2. High performance i.e millions of Transactions per second


NoSQL databases aren’t saddled with the responsibility of ensuring data integrity, which means
they don’t have to validate the data's integrity when it enters the system. This is especially useful
in scenarios like logging, where write speed is a key metric, and data integrity checks are not
required.

3. Flexibility of data types


NoSQL databases can ingest unstructured and semi-structured data at scale, unlike their SQL
counterparts, which define data types for every column before data can enter the system using
constraints. Not having these checks in NoSQL means developers can save a lot of time not
having to define data types and relationships for every single column. It also means that if the
structure of incoming data changes, it can go into the same database without developers getting
involved.
4. Availability and Redundance: Zero down time
NoSQL databases replicate data in a near-real-time manner across their nodes. Each node can
potentially have multiple replicas, which can take over if the primary node fails and start fielding
read requests from client applications. Furthermore, nodes and replicas can be spread across
diverse geographic locations, ensuring 100 percent uptime in the event of a server crash, power
loss to one or more nodes, natural disaster among many others

5. Ease of use via APIs


NoSQL provides access to stored data objects via object-based APIs, as opposed to SQL, which
is a mathematical, set-based language. Many enterprise developers lack the experience to
develop complex logic in SQL — they prefer to call an API and let it figure out how to fetch the
data. This makes it easier and faster to scale.

Drawbacks of NoSQL Databases

1. Purpose specific
SQL databases can do much more than just storing data. They can ensure data integrity and can
be used to calculate analytics, pull data using complex joins, and quickly and efficiently retrieve
large quantities of data. They are more portable and come with well-defined and understood
standards. NoSQL databases are not general in this way. They are purpose-built to do one thing
well, meaning you will have to dedicate your NoSQL database for one use case only and would
have to create a second database for a different purpose. If you are planning to use your database
for various use cases, NoSQL is less likely to be the right candidate.

2. Small community
SQL databases have been around for about half a century, which means that there is a decent
talent pool: People with deep SQL experience are relatively easy to find. That is not the case
with NoSQL databases, which have only been around for about a decade. Furthermore, NoSQL
databases generally have specific APIs, and fewer people have deep experience with any specific
API. Finding people that can run your NoSQL setup can be a challenge.

3. Relatively large
In terms of storage utilization, NoSQL databases are fast but relatively inefficient compared to
SQL-based systems. NoSQL databases are redundant by design because they can create multiple
copies of data internally. Schema metadata gets stored in every document which also increases
space usage.

4. Newer and Less Mature


SQL databases have had more than half a century of adoption and improvement, and the
technology is quite mature. NoSQL databases have only been around for a fraction of the time of
SQL-based systems, which means NoSQL database offerings aren’t mature enough yet and
stability is sometimes an issue.
5. No universal Query Language and No Joins
Relational database systems rely on SQL which has been around for a half a century. The
language is mature and well understood by a large cadre of software professionals. Joins give us
the ability to pull information from multiple related tables. SQL allows joins which means
queries are flexible and can fetch data in various ways to extract detailed meaning from raw data.

NoSQL APIs are generally not flexible and do not allow the flexibility joins can offer. They are
not as prevalent and the talent pool of professionals comfortable enough to work with these APIs
is not deep. While NoSQL databases provide a fast way to store and retrieve data, a lot of the
work of number crunching is left mostly to developer tools. Developers can make API calls like
below to fetch the data into memory first, then use tools like Python to do the number crunching
in memory and calculate results. Relating information inside the NoSQL database is hard and
generally discouraged which is a big disadvantage.

You might also like