Write a 5-page paper to compare MySQL and Mongo with regards to how queries are prepared and executed, and the reasons why. Include a section to compare and contrast the two technologies with regards to how they foster data integrity, performance and security.
In the ever-changing world of technology, there have been many clear advancements in the space of databases. Two very common databases are MySQL and MongoDB. They are similar in many ways and also very different in how they deal with data. We will look at how they execute read queries and see what those similarities and differences are.
Part 1: How a MySQL query is prepared and executed.
For us to understand how a SQL database differs in running queries we …show more content…
Data that belongs to a parent-child relationship in two RDBMS tables would commonly be collapsed (embedded) into a single document in MongoDB. The complete document can be assessed with a single call to the database, rather than having to JOIN multiple tables to respond to a query. The Querying the MongoDB is a 2 steps process. Step one is the planning phase, which decides the best way to execute the query. Step two is the execution phase, which will look through indexes to find results. The steps will be explained further …show more content…
While it’s true that MongoDB is not susceptible to SQL language abuses, its JSON documents can still be altered to achieve the same malicious results. Furthermore, MongoDB has had its own share of vulnerabilities—for example, a recently discovered widespread vulnerability gives hackers the ability to remotely crash the database application. Additionally, perusing the Common Vulnerabilities and Exposures (CVE) database reveals a host of security exposures and vulnerabilities for MongoDB. Like other NoSQL databases, MongoDB has suffered security shortcomings for years. When MySQL and other relational databases tend to use some form of authorization, MongoDB databases are exposed to the Internet and do not require credentials immediately by default. In the face of these waves of attacks aimed at hijacking MongoDB instances, Andreas Nilsson, Director of Product Security at MongoDB has published a post in which he explains to administrators how to avoid this type of attack. "These attacks can be avoided thanks to the numerous security protections built into MongoDB. You have to use these features properly and our security documentation will help you do that", he says. For example, he recalls that the latest version of MongoDB 3.4 allows you to configure authentication on an unprotected system without incurring downtime. The MongoDB Atlas hosted database service provides several levels of security for