Efficiency comparison between MongoDB and MySQL two databases
1. The first is the memory mapping mechanism. The data is not persisted to the storage device, but is temporarily stored in the memory, which improves the efficiency of IO and the performance loss between the operating system and the storage medium. (After all, memory reading is the fastest) Second, NoSQL does not use sql, just does not use relations. There is no relationship, which means that each data is like having a separate storage space, and then pointed to by a clustered index. Search performance will definitely improve. Third, language. Operations using Javascript syntax are more efficient and straightforward. These are the reasons why MongoDB is more efficient for relational databases. But you can’t just focus on efficiency, there are also some disadvantages brought about by the design of this database. For example, the maintenance of data relationships will bring a lot of redundant data, the client code needs a lot of IO operations on the database, data mining is difficult to implement, and so on. Therefore, it is a priority to select an appropriate data storage medium for the application system.