Basics
Commands
Advanced
MongoDB is a document-based database. people call it SQL because it is not a SQL-based database,, or we do not have to write sql queries. Instead, to search or fetch, we can write a regex query. MongoDB stores data in a JSON-like format called BSON. It supports Indexing, Load Balancing, and Sharding. In MongoDB, there are collections to store similar or different data. Because of its storage of JSON-like format after fetching data by server-side language from MongoDB, it need not be required to convert it again into JSON format.
There are multiple reasons why we should learn MongoDB
MongoDB mostly used in Web applications to store data. It is Mostly and highly used by express JS, NodJS, and AngularJS because Node JS is Javascript, and we know Javascript is more comfortable with JSON, and we know MongoDB is Already JSON.
Let me explain one short example of fetching data from MongoDB collection. Suppose our collection name issues. In the below example, we are fetching data from a collection called issues, and we used the pretty() function to display data in a better format.
db.issues.find({}).pretty()
Output :
{
"_id" : ObjectId("5da83b2f8cd630aadaa38806"),
"status" : "Open",
"owner" : "Ravan",
"created" : ISODate("2016-08-15T00:00:00Z"),
"effort" : 5,
"completionDate" : undefined,
"title" : "Error in console when clicking Add"
}
{
"_id" : ObjectId("5da83b2f8cd630aadaa38807"),
"status" : "Assigned",
"owner" : "Eddie",
"created" : ISODate("2016-08-16T00:00:00Z"),
"effort" : 14,
"completionDate" : ISODate("2016-08-30T00:00:00Z"),
"title" : "Missing bottom border on panel"
}
{
"_id" : ObjectId("5da83dde93c7770c2beb6d57"),
"owner" : "Ravan",
"title" : "buy some cookies",
"status" : "Open",
"created" : ISODate("2019-10-17T10:09:34.294Z"),
"completionDate" : ISODate("2019-12-08T18:30:00Z"),
"effort" : 1
}
Output:
So to learn MongoDB, you do not need to know the SQL query, you need to have a basic understanding of data and regex operations.
There would be two targets Audience given below:
Database Admin: A database Admin can deal with creating new users, granting some access to those users, checking performance, and scaling MongoDB.
Web Developer: A web Developer can store data which it is getting from various sources and also displaying stored data to various end-users and for scripting.
By signing up, you agree to our Terms of Use and Privacy Policy.
By signing up, you agree to our Terms of Use and Privacy Policy.
Valuation, Hadoop, Excel, Web Development & many more.
This website or its third-party tools use cookies, which are necessary to its functioning and required to achieve the purposes illustrated in the cookie policy. By closing this banner, scrolling this page, clicking a link or continuing to browse otherwise, you agree to our Privacy Policy