MongoDB is a database based on distributed file storage. Written by the C + + language. Designed to provide scalable, high-performance data storage solutions for WEB applications.
MongoDB is a product between a relational database and a non-relational database, and is the most versatile and most like relational database in a non-relational database. The data exists on the hard disk, Redis is in memory, and Redis wants to be persisted to the hard drive.
First use PIP install Pymongo and then use import Pymongo
Here is an example of the operation
ImportPymongom=pymongo. Mongoclient (host="', port=1111) DB=m["ssss"]collection=db['SSS']collection.insert ("')#Inserting DataCollection.find ()#Find DataCollection.delete_many ()#Delete Multiple stripsCollection.delete_one ("')#Delete a barCollection.update ()#Update DataCollection.update_many ()#update more than one dataCollection.update_one ()#update One piece of data
Python Operation MongoDB