MongoDB is a NoSQL database. NoSQL can be expanded as "not only SQL," meaning it's not SQL. This is because the queries executed are not the ones you're used to in MySQL or MS SQL systems.
Advantages of NoSQL Systems
They can be more efficient in terms of reading and writing compared to others.
They are horizontally scalable. That means they can be run by forming clusters of thousands of servers, allowing easier processing on larger data.
Due to their various features, they provide conveniences in programming.
They are more cost-effective compared to other database systems.
Disadvantages of NoSQL Systems
It can be initially challenging to migrate an application using an SQL database to a NoSQL system. Especially, modifications will be needed for queries using joins.
NoSQL database systems do not have an advanced data security structure like SQL databases.
In MongoDB, as mentioned above, security can be insufficient in the initial setup. By default, there are no username and password. Direct connection to the database can be established by simply entering the server address. Therefore, it is necessary to close the database access to the outside and configure MongoDB configurations to enable user authentication. I will explain installation and configurations in the next post.
MongoDB
It is a database system started by the 10gen company in 2007 and converted into an open-source project with AGPL license in 2009. It is introduced as a document-oriented database. MongoDB treats every record created on it as a document. These documents are stored in JSON format.
The match between MongoDB and conventional SQL databases' concepts is explained in the table below:
SQL MongoDB
database | database |
table | collection |
row | document or BSON document |
column | field |
index | index |
table joins | embedded documents and linking |
primary key Specify any unique column or column combination as primary key. |
primary key In MongoDB, the primary key is automatically set to the _id field. |
aggregation (e.g. group by) | aggregation framework See the SQL to Aggregation Framework Mapping Chart. |
Additionally, you can find exercises and different documents about MongoDB from the following link:
Türkçe: https://niyazi.net/tr/mongodb-ve-nosql-kavrami-nedir
Muhammed Niyazi ALPAY - Cryptograph
Senior Software Developer & Senior Linux System Administrator
Meraklı
PHP MySQL MongoDB Python Linux Cyber Security
There are none comment