Hands on Big Data Analysis with MongoDB - Cloud Expo Bootcamp NYCLaura Ventura
One of the most popular NoSQL databases, MongoDB is one of the building blocks for big data analysis. MongoDB can store unstructured data and makes it easy to analyze files by commonly available tools. This session will go over how big data analytics can improve sales outcomes in identifying users with a propensity to buy by processing information from social networks. All attendees will have a MongoDB instance on a public cloud, plus sample code to run Big Data Analytics.
The document describes a lab manual for a course on MongoDB at SRK Institute of Technology. The course aims to teach students how to install and configure MongoDB, perform database operations using it, and develop applications integrating MongoDB with Java and PHP. The lab manual contains 12 experiments covering MongoDB installation, creating and dropping databases and collections, inserting, querying, updating, and deleting documents, indexing, and connecting MongoDB to Java and PHP applications.
MONGODB VS MYSQL: A COMPARATIVE STUDY OF PERFORMANCE IN SUPER MARKET MANAGEME...ijcsity
A database is information collection that is organized in tables so that it can easily be accessed, managed, and updated. It is the collection of tables, schemas, queries, reports, views and other objects. The data are typically organized to model in a way that supports processes requiring information, such as modelling to find a hotel with availability of rooms, thus the people can easily locate the hotels with vacancies. There are many databases commonly, relational and non relational databases. Relational databases usually work with structured data and non relational databases are work with semi structured data. In this paper, the performance evaluation of MySQL and MongoDB is performed where MySQL is an example of relational database and MongoDB is an example of non relational databases. A relational database is a data structure that allows you to connect information from different 'tables', or different types of data buckets. Non-relational database stores data without explicit and structured mechanisms to link data from different buckets to one another. This paper discuss about the performance of MongoDB and MySQL in the field of Super Market Management System. A supermarket is a large form of the traditional grocery store also a self-service shop offering a wide variety of food and household products, organized in systematic manner. It is larger and has a open selection than a traditional grocery store.
MONGODB VS MYSQL: A COMPARATIVE STUDY OF PERFORMANCE IN SUPER MARKET MANAGEME...ijcsity
A database is information collection that is organized in tables so that it can easily be accessed, managed,
and updated. It is the collection of tables, schemas, queries, reports, views and other objects. The data are
typically organized to model in a way that supports processes requiring information, such as modelling to
find a hotel with availability of rooms, thus the people can easily locate the hotels with vacancies. There
are many databases commonly, relational and non relational databases. Relational databases usually work
with structured data and non relational databases are work with semi structured data. In this paper, the
performance evaluation of MySQL and MongoDB is performed where MySQL is an example of relational
database and MongoDB is an example of non relational databases. A relational database is a data
structure that allows you to connect information from different 'tables', or different types of data buckets.
Non-relational database stores data without explicit and structured mechanisms to link data from different
buckets to one another. This paper discuss about the performance of MongoDB and MySQL in the field of
Super Market Management System. A supermarket is a large form of the traditional grocery store also a
self-service shop offering a wide variety of food and household products, organized in systematic manner.
It is larger and has a open selection than a traditional grocery store.
MONGODB VS MYSQL: A COMPARATIVE STUDY OF PERFORMANCE IN SUPER MARKET MANAGEME...ijcsity
A database is information collection that is organized in tables so that it can easily be accessed, managed,
and updated. It is the collection of tables, schemas, queries, reports, views and other objects. The data are
typically organized to model in a way that supports processes requiring information, such as modelling to
find a hotel with availability of rooms, thus the people can easily locate the hotels with vacancies. There
are many databases commonly, relational and non relational databases. Relational databases usually work
with structured data and non relational databases are work with semi structured data. In this paper, the
performance evaluation of MySQL and MongoDB is performed where MySQL is an example of relational
database and MongoDB is an example of non relational databases. A relational database is a data
structure that allows you to connect information from different 'tables', or different types of data buckets.
Non-relational database stores data without explicit and structured mechanisms to link data from different
buckets to one another. This paper discuss about the performance of MongoDB and MySQL in the field of
Super Market Management System. A supermarket is a large form of the traditional grocery store also a
self-service shop offering a wide variety of food and household products, organized in systematic manner.
It is larger and has a open selection than a traditional grocery store.
Everything You Need to Know About MongoDB Development.pptx75waytechnologies
Today, organizations from different verticals want to harness the power of data to grab new business opportunities and touch new heights of success. Such an urge leads them to follow unique ways to use and handle data effectively. After all, the right use of data boosts the ability to make business decisions faster. But at the same time, working with data is not as easy as a walk in the garden. It sometimes turns out to be a long-standing problem for businesses that also affects their overall functioning.
Companies expect fast phase development and better data management in every scenario. Modern web-based applications development demands a quality working system that can be deployed faster, and the application is able to scale in the future as per the constantly changing environment.
Earlier, relational databases were used as a primary data store for web application development. But today, developers show a high interest in adopting alternative data stores for modern applications such as NoSQL (Not Only Structured Query Language) because of its incredible benefits. And if you ask us, one of the technologies that can do wonders in modern web-based application development is MongoDB.
MongoDB is the first name strike in our heads when developing scalable applications with evolving data schemas. Because MongoDB is a document database, it makes it easier for developers to store both structured and unstructured data. Stores and handles large amounts of data quickly, MongoDB is undoubtedly the smart move toward building scalable and data-driven applications. If you’re wondering what MongoDB is and how it can help your digital success, this blog is surely for you.
how_can_businesses_address_storage_issues_using_mongodb.pdfsarah david
MongoDB is an open-source database that can help businesses address storage issues. It provides scalability, availability, and handles large amounts of data well. MongoDB uses a flexible document data model and has features like replication, sharding, and indexing that improve performance. While it has advantages like flexibility, simplicity, and speed, it also has drawbacks like limited transactions and joins compared to relational databases. Understanding both the benefits and limitations of MongoDB is important for businesses evaluating it for their data storage needs.
how_can_businesses_address_storage_issues_using_mongodb.pptxsarah david
MongoDB enables seamless data storage and performance. Explore our blog to learn how MongoDB handles storage issues for startups and large-scale enterprises. Discover how to optimize MongoDB performance using open-source database storage.
MongoDB is a document-oriented NoSQL database that uses JSON-like documents with optional schemas. It provides high performance, high availability, and easy scalability. MongoDB is also called "humongous" because it is designed to store and handle large volumes of data. Some key advantages of MongoDB include its ability to handle large, unstructured data sets and provide agile development with quick code iterations.
MongoDB is a popular open-source document-oriented NoSQL database that uses a document-based data model. It stores data in flexible, JSON-like documents, allowing for easy storage and retrieval of data without rigid schemas. MongoDB is horizontally scalable, supports replication and high availability, and is often used for applications that require more flexibility than relational databases or have very large amounts of data.
This document provides information about MongoDB, including:
- MongoDB is a cross-platform document-oriented database that provides high performance, high availability, and easy scalability.
- Data is stored in MongoDB in the form of JSON-like documents with dynamic schemas, instead of using fixed table schemas as in SQL-based databases.
- Relationships between documents can be modeled either by embedding one document inside another or by storing references between separate documents.
SQL vs NoSQL, an experiment with MongoDBMarco Segato
A simple experiment with MongoDB compared to Oracle classic RDBMS database: what are NoSQL databases, when to use them, why to choose MongoDB and how we can play with it.
This document provides an introduction to NoSQL databases. It discusses that NoSQL databases are non-relational, do not require a fixed table schema, and do not require SQL for data manipulation. It also covers characteristics of NoSQL such as not using SQL for queries, partitioning data across machines so JOINs cannot be used, and following the CAP theorem. Common classifications of NoSQL databases are also summarized such as key-value stores, document stores, and graph databases. Popular NoSQL products including Dynamo, BigTable, MongoDB, and Cassandra are also briefly mentioned.
1) The document discusses the differences between SQL and NoSQL databases in terms of scalability, data modeling, and indexing. SQL databases are less scalable but ensure consistency and transactions, while NoSQL databases are more scalable through replication and sharding.
2) Complex applications may require a hybrid approach using both SQL and NoSQL databases. For example, storing product data in a NoSQL database and customer relationship management data in a SQL database.
3) There is no single best approach - the optimal solution depends on the specific business needs and data usage patterns. Both SQL and NoSQL databases each have their own advantages, and either can be suitable depending on the context.
MongoDB and SQL are two popular database management systems. MongoDB is a document-oriented and schemaless database that stores data in flexible JSON-like documents, while SQL is a relational database that stores data in rigidly defined tables. MongoDB uses a powerful query language based on JavaScript and scales horizontally very well. In contrast, SQL uses the standardized SQL language and typically scales vertically. MongoDB generally performs better for large, unstructured datasets like those from IoT and big data applications, while SQL is better suited for structured data needing complex transactions, analytics or regulatory compliance.
1) The document discusses the features and advantages of the non-relational MongoDB database compared to relational databases like MySQL. It focuses on MongoDB's flexibility, scalability, auto-sharding, and replication capabilities that make it more suitable than MySQL for big data applications.
2) MongoDB stores data as JSON-like documents with dynamic schemas rather than tables with rigid schemas. It allows embedding of related data and does not require joins. This improves performance over relational databases.
3) The key advantages of MongoDB are its flexible data model, horizontal scalability, high performance, and rich query capabilities. It is commonly used for big data, mobile and social applications, and as a data hub.
This paper trying to focus on main features, advantages and applications of non-relational database namely Mongo DB and thus justifying why MongoDB is more suitable than relational databases in big data applications. The database used here for comparison with MongoDB is MySQL. The main features of MongoDB are flexibility, scalability, auto sharding and replication. MongoDB is used in big data and real time web applications since it is a leading database technology.
This document provides an overview of MongoDB and its suitability for handling IoT data. MongoDB is a document-oriented NoSQL database that uses a flexible document data model and scales horizontally. It can handle the high volume and varied structures of sensor data generated by IoT devices in real-time without expensive ETL processes. MongoDB addresses the challenges of IoT data by allowing rapid iteration of data schemas, scaling to billions of documents, and performing analytics directly on the database.
Pros and Cons of MongoDB in Web DevelopmentNirvana Canada
Databases are available in plenty, and choosing the right one for your organization is a challenging task. In this blog, we will specifically focus on MongoDB and its pros and cons for web development.
This document provides an introduction to MongoDB, a non-relational NoSQL database. It discusses what NoSQL databases are and their benefits compared to SQL databases, such as being more scalable and able to handle large, changing datasets. It then describes key features of MongoDB like high performance, rich querying, and horizontal scalability. The document outlines concepts like document structure, collections, and CRUD operations in MongoDB. It also covers topics such as replication, sharding, and installing MongoDB.
- Modern data workloads like big data, agile development, and cloud computing are driving new requirements for database management systems that relational databases can't meet.
- NoSQL databases like MongoDB were created to address these new requirements by providing horizontal scalability, flexible schemas, and compatibility with cloud environments.
- MongoDB scales across multiple servers, allows dynamic schema changes, and runs well on commodity hardware and virtual infrastructures, making it well-suited for modern applications.
Big data, agile development, and cloud computing
are driving new requirements for database
management systems. These requirements are in turn
driving the next phase of growth in the database
industry, mirroring the evolution of the OLAP
industry. This document describes this evolution, the
new application workload, and how MongoDB is
uniquely suited to address these challenges.
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...Aqusag Technologies
In late April 2025, a significant portion of Europe, particularly Spain, Portugal, and parts of southern France, experienced widespread, rolling power outages that continue to affect millions of residents, businesses, and infrastructure systems.
Ad
More Related Content
Similar to MongoDB eBook a complete guide to beginners (20)
MongoDB is a document-oriented NoSQL database that uses JSON-like documents with optional schemas. It provides high performance, high availability, and easy scalability. MongoDB is also called "humongous" because it is designed to store and handle large volumes of data. Some key advantages of MongoDB include its ability to handle large, unstructured data sets and provide agile development with quick code iterations.
MongoDB is a popular open-source document-oriented NoSQL database that uses a document-based data model. It stores data in flexible, JSON-like documents, allowing for easy storage and retrieval of data without rigid schemas. MongoDB is horizontally scalable, supports replication and high availability, and is often used for applications that require more flexibility than relational databases or have very large amounts of data.
This document provides information about MongoDB, including:
- MongoDB is a cross-platform document-oriented database that provides high performance, high availability, and easy scalability.
- Data is stored in MongoDB in the form of JSON-like documents with dynamic schemas, instead of using fixed table schemas as in SQL-based databases.
- Relationships between documents can be modeled either by embedding one document inside another or by storing references between separate documents.
SQL vs NoSQL, an experiment with MongoDBMarco Segato
A simple experiment with MongoDB compared to Oracle classic RDBMS database: what are NoSQL databases, when to use them, why to choose MongoDB and how we can play with it.
This document provides an introduction to NoSQL databases. It discusses that NoSQL databases are non-relational, do not require a fixed table schema, and do not require SQL for data manipulation. It also covers characteristics of NoSQL such as not using SQL for queries, partitioning data across machines so JOINs cannot be used, and following the CAP theorem. Common classifications of NoSQL databases are also summarized such as key-value stores, document stores, and graph databases. Popular NoSQL products including Dynamo, BigTable, MongoDB, and Cassandra are also briefly mentioned.
1) The document discusses the differences between SQL and NoSQL databases in terms of scalability, data modeling, and indexing. SQL databases are less scalable but ensure consistency and transactions, while NoSQL databases are more scalable through replication and sharding.
2) Complex applications may require a hybrid approach using both SQL and NoSQL databases. For example, storing product data in a NoSQL database and customer relationship management data in a SQL database.
3) There is no single best approach - the optimal solution depends on the specific business needs and data usage patterns. Both SQL and NoSQL databases each have their own advantages, and either can be suitable depending on the context.
MongoDB and SQL are two popular database management systems. MongoDB is a document-oriented and schemaless database that stores data in flexible JSON-like documents, while SQL is a relational database that stores data in rigidly defined tables. MongoDB uses a powerful query language based on JavaScript and scales horizontally very well. In contrast, SQL uses the standardized SQL language and typically scales vertically. MongoDB generally performs better for large, unstructured datasets like those from IoT and big data applications, while SQL is better suited for structured data needing complex transactions, analytics or regulatory compliance.
1) The document discusses the features and advantages of the non-relational MongoDB database compared to relational databases like MySQL. It focuses on MongoDB's flexibility, scalability, auto-sharding, and replication capabilities that make it more suitable than MySQL for big data applications.
2) MongoDB stores data as JSON-like documents with dynamic schemas rather than tables with rigid schemas. It allows embedding of related data and does not require joins. This improves performance over relational databases.
3) The key advantages of MongoDB are its flexible data model, horizontal scalability, high performance, and rich query capabilities. It is commonly used for big data, mobile and social applications, and as a data hub.
This paper trying to focus on main features, advantages and applications of non-relational database namely Mongo DB and thus justifying why MongoDB is more suitable than relational databases in big data applications. The database used here for comparison with MongoDB is MySQL. The main features of MongoDB are flexibility, scalability, auto sharding and replication. MongoDB is used in big data and real time web applications since it is a leading database technology.
This document provides an overview of MongoDB and its suitability for handling IoT data. MongoDB is a document-oriented NoSQL database that uses a flexible document data model and scales horizontally. It can handle the high volume and varied structures of sensor data generated by IoT devices in real-time without expensive ETL processes. MongoDB addresses the challenges of IoT data by allowing rapid iteration of data schemas, scaling to billions of documents, and performing analytics directly on the database.
Pros and Cons of MongoDB in Web DevelopmentNirvana Canada
Databases are available in plenty, and choosing the right one for your organization is a challenging task. In this blog, we will specifically focus on MongoDB and its pros and cons for web development.
This document provides an introduction to MongoDB, a non-relational NoSQL database. It discusses what NoSQL databases are and their benefits compared to SQL databases, such as being more scalable and able to handle large, changing datasets. It then describes key features of MongoDB like high performance, rich querying, and horizontal scalability. The document outlines concepts like document structure, collections, and CRUD operations in MongoDB. It also covers topics such as replication, sharding, and installing MongoDB.
- Modern data workloads like big data, agile development, and cloud computing are driving new requirements for database management systems that relational databases can't meet.
- NoSQL databases like MongoDB were created to address these new requirements by providing horizontal scalability, flexible schemas, and compatibility with cloud environments.
- MongoDB scales across multiple servers, allows dynamic schema changes, and runs well on commodity hardware and virtual infrastructures, making it well-suited for modern applications.
Big data, agile development, and cloud computing
are driving new requirements for database
management systems. These requirements are in turn
driving the next phase of growth in the database
industry, mirroring the evolution of the OLAP
industry. This document describes this evolution, the
new application workload, and how MongoDB is
uniquely suited to address these challenges.
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...Aqusag Technologies
In late April 2025, a significant portion of Europe, particularly Spain, Portugal, and parts of southern France, experienced widespread, rolling power outages that continue to affect millions of residents, businesses, and infrastructure systems.
Book industry standards are evolving rapidly. In the first part of this session, we’ll share an overview of key developments from 2024 and the early months of 2025. Then, BookNet’s resident standards expert, Tom Richardson, and CEO, Lauren Stewart, have a forward-looking conversation about what’s next.
Link to recording, presentation slides, and accompanying resource: https://bnctechforum.ca/sessions/standardsgoals-for-2025-standards-certification-roundup/
Presented by BookNet Canada on May 6, 2025 with support from the Department of Canadian Heritage.
Andrew Marnell: Transforming Business Strategy Through Data-Driven InsightsAndrew Marnell
With expertise in data architecture, performance tracking, and revenue forecasting, Andrew Marnell plays a vital role in aligning business strategies with data insights. Andrew Marnell’s ability to lead cross-functional teams ensures businesses achieve sustainable growth and operational excellence.
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025BookNet Canada
Book industry standards are evolving rapidly. In the first part of this session, we’ll share an overview of key developments from 2024 and the early months of 2025. Then, BookNet’s resident standards expert, Tom Richardson, and CEO, Lauren Stewart, have a forward-looking conversation about what’s next.
Link to recording, transcript, and accompanying resource: https://bnctechforum.ca/sessions/standardsgoals-for-2025-standards-certification-roundup/
Presented by BookNet Canada on May 6, 2025 with support from the Department of Canadian Heritage.
Technology Trends in 2025: AI and Big Data AnalyticsInData Labs
At InData Labs, we have been keeping an ear to the ground, looking out for AI-enabled digital transformation trends coming our way in 2025. Our report will provide a look into the technology landscape of the future, including:
-Artificial Intelligence Market Overview
-Strategies for AI Adoption in 2025
-Anticipated drivers of AI adoption and transformative technologies
-Benefits of AI and Big data for your business
-Tips on how to prepare your business for innovation
-AI and data privacy: Strategies for securing data privacy in AI models, etc.
Download your free copy nowand implement the key findings to improve your business.
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptxJustin Reock
Building 10x Organizations with Modern Productivity Metrics
10x developers may be a myth, but 10x organizations are very real, as proven by the influential study performed in the 1980s, ‘The Coding War Games.’
Right now, here in early 2025, we seem to be experiencing YAPP (Yet Another Productivity Philosophy), and that philosophy is converging on developer experience. It seems that with every new method we invent for the delivery of products, whether physical or virtual, we reinvent productivity philosophies to go alongside them.
But which of these approaches actually work? DORA? SPACE? DevEx? What should we invest in and create urgency behind today, so that we don’t find ourselves having the same discussion again in a decade?
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdfAbi john
Analyze the growth of meme coins from mere online jokes to potential assets in the digital economy. Explore the community, culture, and utility as they elevate themselves to a new era in cryptocurrency.
Mobile App Development Company in Saudi ArabiaSteve Jonas
EmizenTech is a globally recognized software development company, proudly serving businesses since 2013. With over 11+ years of industry experience and a team of 200+ skilled professionals, we have successfully delivered 1200+ projects across various sectors. As a leading Mobile App Development Company In Saudi Arabia we offer end-to-end solutions for iOS, Android, and cross-platform applications. Our apps are known for their user-friendly interfaces, scalability, high performance, and strong security features. We tailor each mobile application to meet the unique needs of different industries, ensuring a seamless user experience. EmizenTech is committed to turning your vision into a powerful digital product that drives growth, innovation, and long-term success in the competitive mobile landscape of Saudi Arabia.
UiPath Community Berlin: Orchestrator API, Swagger, and Test Manager APIUiPathCommunity
Join this UiPath Community Berlin meetup to explore the Orchestrator API, Swagger interface, and the Test Manager API. Learn how to leverage these tools to streamline automation, enhance testing, and integrate more efficiently with UiPath. Perfect for developers, testers, and automation enthusiasts!
📕 Agenda
Welcome & Introductions
Orchestrator API Overview
Exploring the Swagger Interface
Test Manager API Highlights
Streamlining Automation & Testing with APIs (Demo)
Q&A and Open Discussion
Perfect for developers, testers, and automation enthusiasts!
👉 Join our UiPath Community Berlin chapter: https://community.uipath.com/berlin/
This session streamed live on April 29, 2025, 18:00 CET.
Check out all our upcoming UiPath Community sessions at https://community.uipath.com/events/.
AI and Data Privacy in 2025: Global TrendsInData Labs
In this infographic, we explore how businesses can implement effective governance frameworks to address AI data privacy. Understanding it is crucial for developing effective strategies that ensure compliance, safeguard customer trust, and leverage AI responsibly. Equip yourself with insights that can drive informed decision-making and position your organization for success in the future of data privacy.
This infographic contains:
-AI and data privacy: Key findings
-Statistics on AI data privacy in the today’s world
-Tips on how to overcome data privacy challenges
-Benefits of AI data security investments.
Keep up-to-date on how AI is reshaping privacy standards and what this entails for both individuals and organizations.
2. Table of
Contents
03 Introduction
04 What’s MongoDB?
05 Old Data vs Big Data
07 MongoDB Benefits
10 MongoDB Use Cases
11 Alternative NoSQL databases
13 Working in MongoDB
14 Installing MongoDB
15 Terminology
16 Memory usage
17 Features and Functions
23 Author bio
3. This e-book is a general overview of MongoDB. It’s intended to give you
a basic understanding of the database. The first half of the book focuses
on advantages and drawbacks, sample use cases, and alternate solutions
for big data. The second half of the book focuses on the technical side of
MongoDB.
In many sections, we link to published articles on BMC Blogs and our
MongoDB Guide to provide you with more in-depth information, tutorials,
and code.
Introduction
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
03
PREVIOUS NEXT
4. MongoDB is a JSON, NoSQL, big data database. MongoDB is available to
run in the cloud or on premises, with both free and pay-to-use versions.
First released in 2009, MongoDB solved a problem that most companies
face: how to store data that varies in each record. This differs from the
row-and-column format of traditional relational database management
systems (RDBMS), where all records are assumed to be the same.
We illustrate these concepts with hands-on example in
MongoDB Overview: Getting Started with MongoDB
For example, here is a MongoDB document.
You list documents using the find() function:
What’s MongoDB?
In an RDBMS, that would look like this, using SQL (Structured Query Language):
select * from products;
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
id
2212121
product
456
count
100
price
12.5
04
PREVIOUS NEXT
5. Old Data vs Big Data
To understand big data and MongoDB, let's explain what we can call old data.
Old data, or
structured data, are
stored in RDMBS, SQL
databases.
SQL databases and old data
Traditional SQL database vendors might use the
label big data on their products to ride the big
data wave, but what they’re selling often isn’t big
data—it’s old data. At its simplest, old data refers
to RDBMS, SQL databases. These run on physical
servers or mainframes. By far, the two most
common SQL databases are Oracle and IBM’s Db2®
.
SAP is also a major player thanks to their in-memory
SQL database, SAP Hana.
Traditional SQL databases have schema, meaning
there are fixed rules on how the data is structured.
SQL data is organized in rows and columns and
across tables or sheets. As you collect more data,
your spreadsheet grows, but not every row or
column applies to every item.
To simplify this problem, you may create different
sheets for different data—but you’re still stuck with
too many items. This adds complexity, resulting
in less flexibility to add features and inefficient
computingwhenpullingdatafromavarietyoflocations.
SQL databases today
Today database sales like Oracle are declining,
in part because open-source options such as
PostgreSQL and MySQL are free. Despite these
changes, many large companies continue to run SQL
databases because they are excellent for handling
heavy transactional data—like ERP systems for
scheduling systems, inventory, sales, and order
entry. SQL is easy to understand, and the volume of
data in even the largest ERP systems is still relatively
small.
For larger, more complex applications, like social
media, survey systems, IoT, search engines, and
geolocation, SQL is not a good fit: such highly
variable data, unstructured data, does not fit into
a rigid schema easily.
Unstructured data
accounts for nearly of
90%
data created today.
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
05
PREVIOUS NEXT
6. NoSQL databases and big data
That’s where NoSQL databases come in. Big data, also known as unstructured
data, is generally defined by a lack of schema—there’s no rigid structure. Unlike
old data, big data can scale almost without limit. (This second feature is because
organizations like Yahoo, Google, and Stanford University have developed and
given away software that lets systems run across two or more servers.)
That freedom from rigid rules makes sense in an application where not all the
records require the same data. For example, in a sales system every customer has
an address and taxpayer ID. But in a NoSQL database, you can still have an address
and taxpayer ID—and you can add any other data.
With structured data, as in SQL databases, if you want to add a new column to
a database table, you must rebuild the table and run a conversion. That's a lot of
trouble.
With MongoDB you can add new fields at will and as much data to a single
document as you need.
MongoDB uses JSON in place of a schema. Short for JavaScript Object Notation,
JSON is completely free form, with no rigid rules as to structure. We say that
it is self-describing. This means the field name and data value are both in the
document, side-by-side. So, you can read what any field means just by looking at
the name beside it.
Learn more about data types and
databases in:
Structured vs Unstructured Data
Big Data vs Analytics vs Data Science:
What’s The Difference?
SQL vs NoSQL Databases: What’s The
Difference?
With no schema in MongoDB, you can
write:
{
anyThingYouWant":
"anyValueYouWAnt"
}
create table blah:
( fieldname varchar(50)):
In a SQL database, the data
anyThingYouWant would not fit
because it's not in the schema. Only
fieldXXX is there, so you would write
something like:
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
06
PREVIOUS NEXT
7. MongoDB Benefits
Though SQL databases power countless companies, there are many benefits to
using MongoDB.
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
Immensely scalable
SQL databases such as Oracle and Db2 are scalable, but this is expensive. To
scale a mainframe, you must add costly memory or buy a bigger mainframe.
The NoSQL approach, however, is to use low-cost, PC hardware. To increase
capacity, you simply add another server. Servers in giant data centers use the
same PC architecture invented in the 1990s, and there’s barely any difference
between vendors. That’s why it’s called commodity hardware.
Recent changes in computing mean separate systems can function together as
a single logical unit, replacing the need to buy one large machine when you can
just have two cheap ones.
Open-source software, such as Apache Hadoop and Apache Spark, lets you
scale data without expensive servers or mainframes. Hadoop is a file system
and Spark is a database, but neither are limited to a single server—they can be
tied into one logical unit across multiple servers. Using this approach, there’s
practically no limit to your application. Google, after all, uses hundreds of
thousands of servers to support search, storage, and more.
07
PREVIOUS NEXT
8. Additional tools, like Apache Mesos and Kerberos, make it possible to
spread memory across multiple machines. Think about that: memory is no
longer limited to the size of one machine, overcoming a significant obstacle
found with older systems.
MongoDB fits this model, too. You can increase MongoDB capacity by
adding more servers to a cluster. Then fine tune the distribution by
specifying what parts of the data to store in what servers using sharding.
(See more in Clusters and Sharding.)
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
08
PREVIOUS NEXT
9. Increased speed
Old data databases are structured around the concept that data should
exist in one place only. This concept, called normalization, means that
data should not repeat in a database. This prevents the risk that one
version of data is outdated, but it significantly slows the database speed.
Another reason for requiring normalization was cost. But cheap
hardware means you no longer need to design for normalization—data
can be located wherever you need it.
No more empty data
SQL stores empty data—metadata exists even if actual data does not.
This wastes space and slows computing.
The obvious solution? Don’t require all records to be the same length.
MongoDB records are variable in length because there’s no need to store
empty columns, which also contributes to improved speed.
No expensive SQL operations
SQL databases use view and join operations. In a SQL database, you
join two tables on some common element to achieve some goal. For
example, if you want to show sales and prices together, you would join
the sales and price tables by product number. Joining sets of data is an
expensive operation: using significant cache, memory, and disk space.
To reduce computing time and resources, MongoDB does away with
view and join operations altogether. Instead, you put related items
together in a single document.
Easy development
The straightforward structure of MongoDB makes it easy
for developers to learn and use. The mongo shell is an
interactive JavaScript interface, which most programmers will
appreciate, that allows for querying and updating data and
performing administrative activities.
Despite this simple structure, its features and functions are
robust enough to handle complex requirements, no matter
the scale.
End-to-end security
MongoDB offers end-to-end security. Verify users via LDAP
or AWS IAM, use the Hashicorp Vault to manage secrets,
bring encryption keys with key management integrations,
and establish network peering to cloud providers or use AWS
PrivateLink.
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
09
PREVIOUS NEXT
10. MongoDB Use Cases
MongoDB is primarily used by companies seeking cost reduction and
data optimization. Like any product, of course, MongoDB isn’t perfect
for every situation—it depends on your needs and expectations.
Here are use cases when MongoDB may be just what you need:
IoT. The Internet of Things gathers metrics from devices, sensors, etc. This data must
be free form as each device will capture different metrics. For example, in a preventive
maintenance application a sensor can gather vibration. But an air quality application would
gather particulate matter density. While these are widely different concepts, MongoDB lets
you query them in a common way since the query language, like the database, is flexible.
Product catalogs. Products have different attributes. For example, a car has an
engine size. A shirt can be made of silk, cotton, or polyester. MongoDB, as with any JSON
database, lets you store objects whose attributes vary widely.
Geolocation operations. MongoDB supports the GeoJSON format, with points,
polygons, and as built-in query methods to locate an item based on its proximity to a point
on a map. (Learn how to query and work with geolocation data in MongoDB Geolocation
Query Examples and Track Tweets by Geographic Location).
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
10
PREVIOUS NEXT
11. Alternative NoSQL
Databases
MongoDB isn’t the only NoSQL database on the market. Let’s compare
two other popular options, Elasticsearch and Cassandra.
Elasticsearch
Elasticsearch is very similar to MongoDB. Both are distributed JSON
databases, but Elasticsearch is used primarily for performance monitoring.
This is because Elastic has built parsers for hundreds of data sources to
put disparate logs into JSON format. That enables searching differing data
with a common query. Elasticsearch also has a graphical charting front end
called Kibana.
Many companies use Elasticsearch the same way they would use MongoDB.
It's the same kind of database with one notable difference: there is no
interactive shell. Instead, you use JSON and HTTP to interact with it.
Elasticsearch is a good alternative
for applications that don’t use
JavaScript. Learn more in our
Elasticsearch Guide.
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
11
PREVIOUS NEXT
12. Cassandra
Unlike MongoDB, Apache Cassandra is the modern, highly scalable version
of the relational database, albeit where data is grouped by column instead
of rows, for fast retrieval. That does not, of course, fit all use cases. For
many cases, keeping data together in rows works better.
Structure. Cassandra is a column-
oriented database, whereas
MongoDB stores records in JSON
format. Still, Cassandra can support
JSON in data fields.
Clustering. Cassandra has no
configuration server to control the
operation of other servers. Instead, a
ring of servers each serve equal
functions, but store different parts
(i.e., shards) of the data.
Sharding. MongoDB and Cassandra
both provide a fine level of control
over sharding, but they do so
differently.
Replicating. Both MongoDB and
Cassandra can replicate data,
particularly useful for data
consistency.
In MongoDB vs Cassandra:
NoSQL Databases Compared
we show the same operations
in both databases to further
illustrate how MongoDB works.
Learn more about Cassandra in
our Cassandra Guide.
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
12
PREVIOUS NEXT
13. Working in MongoDB
The second half of this e-book focuses on the technical
side of MongoDB.
To complement this e-book, we have many tutorials
and technical deep dives in our MongoDB Guide.
We recommend you consult these for detailed code
samples and hands-on demonstrations.
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
13
PREVIOUS NEXT
14. Installing MongoDB
If you’re brand new to MongoDB, choosing and installing the software is your first step.
MongoDB currently offers these options:
MongoDB Atlas is the cloud version,
available as an on-demand, fully managed
service that can run on AWS, Microsoft
Azure, and Google Cloud Platform.
• The Sandbox version is free forever
and a great place for training and
ideating.
• The Shared version offers 5GB
storage and shared RAM.
• The Dedicated version offers
consistent performance, more
advanced security, and unlimited
scaling in dedicated clusters.
MongoDB runs on your server and
requires a subscription.
• The Community version is feature
rich and developer ready.
• The Enterprise version has more
advanced features and increased
performance.
In this guide, we use MongoDB Atlas, sandbox version.
Learn how in to install standalone MongoDB configurations and add and search data in
How To Install MongoDB on Ubuntu and Mac.
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
14
PREVIOUS NEXT
15. MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
• MongoDB records are called documents. A document is the equivalent
of a row in a SQL database. The document model maps to objects in
your code, making it easier to work with your data.
• Each MongoDB database includes collections. A collection is a group of
documents, like a table in an RDBMS database.
• Each collection and document have an ObjectID.
Terminology
15
PREVIOUS NEXT
16. Memory Usage
MongoDB can quickly exhaust the memory on a server, so you’ll need to
know how to handle that. MongoDB is not an in-memory database, though
you can configure it to run that way. But MongoDB makes liberal use of
cache, meaning data records kept memory for fast retrieval.
Too much data in your MongoDB database will run your server out of
memory. As the mongod daemon fills up its cache, the process will
consume more and more memory. This can happen quickly—so quickly
that you won’t be able to shut down the mongod process because the bash
shell will no longer respond. The solution is to add another node to your
cluster.
In MongoDB Memory Usage, Management & Requirements, we illustrate:
• What a server looks like when it runs out of memory
• How to run queries and look at logs to prevent insufficient memory
• How to install free monitoring tools to help prevent this situation
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
16
PREVIOUS NEXT
17. So, what can MongoDB do? Here are the main features, which
we explain more fully in the following pages:
• Ad-hoc queries (Basic search functions)
• Indexing
• Real-time aggregation
• Clusters and Sharding
• Transactions
MongoDB also supports replication, load balancing, file storage,
server-side JavaScript execution, and capped collections.
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
Features and
Functions
17
PREVIOUS NEXT
18. MongoDB allows for a variety of search methods. Some ways of searching,
or querying, in MongoDB are:
• By attribute
• Greater or less than
• Not equal to
• Projection, which returns or excludes only designated fields
• Regular expressions
• Elements in array
Get the code for all these and more in MongoDB Cheat Sheet.
Ad-hoc queries
(Basic searches)
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
18
PREVIOUS NEXT
19. Indexing
• A single field index lists data in ascending
or descending order.
• A sparse index does not create an index
when the document does not contain that
field. This is to avoid needless index
documents that have blank values.
• A compound index sorts fields inside
other fields. For instance, indexing first on
one attribute, then on a second.
• A partial index pulls documents that meet
only a certain filter.
See more and get the code in
Introduction To MongoDB Indexes.
An index is a data structure that stores the
location of a record on disk (or in memory
or cached data). It tells the system from
which address to find the data.
Creating appropriate indexes helps
MongoDB maintain efficient computing.
(Without indexes, MongoDB must scan
every document, which slows the query
significantly.)
For example, if you have a field
product=456, and product is an indexed
field, you can search for it quickly, because
the computer knows that record is at, say,
disk location FFFFFFX.
Here are some ways MongoDB fields can be
indexed:
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
19
PREVIOUS NEXT
20. Real-time aggregation
Aggregation operations group values from multiple documents together for
processing and computing. You can also use aggregate functions to perform a
variety of operations on the grouped data in order to return a single result.
In MongoDB you can perform aggregation in three ways:
• The aggregation pipeline
• The MapReduce function
• Single purpose aggregation
In MongoDB Aggregate Functions Explained, we use the WordCount program to
illustrate aggregate functions.
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
20
PREVIOUS NEXT
21. App Server
Router
(mongos)
App Server
Router
(mongos)
ROUTER
Shard
(replica set)
Shard
(replica set)
Clusters and Sharding
A cluster is how you build a distributed system, adding
nodes when necessary as volume increases. Sharding means
distributing data across a cluster. This is done by applying an
algorithm across part or all of a document or index.
A cluster has three parts:
• Config server (which holds configuration information)
• Query router (aka mongos)
• Shard server (i.e., database)
This diagram shows how the mongos process runs as a router,
meaning it tells clients where to look for data. Data is spread
across the cluster based on sharding, the assignment of
records to servers based on the hashed value of some index.
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
21
PREVIOUS NEXT
22. Transactions
A database transaction is any operation performed within a database, such as creating a new record
or updating data within one. Changes made within a database need to be performed with care to
ensure the data within doesn’t become corrupted. The ACID concept—Atomicity, Consistency,
Isolation, Durabillity—provides guidance on how to do this. (Learn more in ACID: Atomic,
Consistent, Isolated & Durable)
Imagine if you have a sales order and inventory control system. Any sale you make should reduce on-
hand inventory. So, what happens if the sales transaction works, but the inventory update fails? Then
the database would no longer be consistent: the inventory would not match the sales.
The way to avoid that is to group the two transactions into one larger transaction. Learn how to
install a transaction on a clustered MongoDB installation here
Introduction to MongoDB Transactions.
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
22
PREVIOUS NEXT
23. Author’s bio
Walker Rowe is an American freelance tech writer and programmer
living in Cyprus. He is also the founder of Hypatia Academy, an online
school that teaches children computer programming. You can find him
on his website and LinkedIn.
MONGODB
BENEFITS
WHAT’S
MONGODB
ALTERNATIVE
NOSQL DATABASES
INSTALLING
MONGODB
OLD DATA
VS BIG DATA
MONGODB
USE CASES
MEMORY
USAGE
TERMINOLOGY FEATURES AND
FUNCTIONS
WORKING IN
MONGODB
Editor’s bio
Chrissy Kidd is a writer and editor in the technology sector, with
more than 10 years of professional experience. She explains technical
concepts, follows trends, and makes technology make sense to all of us.
You can find her on LinkedIn.
23
PREVIOUS NEXT