Tag: Date writing C # IDF DFS aggregation replace network Apr
- MongoDB is a document-oriented database that is simple and easy to operate.
- You can set the index of any property in the MongoDB record (for example: Firstname= "Sameer", address= "8 Gandhi Road") for faster sorting.
- You can create data mirroring either locally or on the network, which makes MongoDB more extensible.
- If the load increases (requiring more storage space and greater processing power), it can be distributed across other nodes in the computer network which is called a shard.
- The MONGO supports rich query expressions. Query directives use a JSON-style tag to easily query objects and arrays embedded in the document.
- MongoDb uses the update () command to implement a replacement of the completed document (data) or some specified data fields.
- The map/reduce in MongoDB is primarily used for batch processing and aggregation of data.
- Map and reduce. The map function calls emit (Key,value) to traverse all records in the collection, passing key and value to the reduce function for processing.
- The map function and the reduce function are written in JavaScript and can be executed with the Db.runcommand or MapReduce command.
- Gridfs is a built-in feature in MongoDB that can be used to store a large number of small files.
- MongoDB allows you to execute scripts on the server, write a function in JavaScript, execute directly on the server, or store the definition of the function on the server, next time you call it directly.
- MongoDB supports a variety of programming languages: ruby,python,java,c++,php,c# and many more languages.
2. MongoDB Installation
3. MongoDB Basic operation
(2) Query operation
The read operation retrieves a document from the collection
Db.collection.find ()
(5) Inserting data
(8) Sort
When sorting, call the sort () method directly and pass in the Ordered field and the ascending order flag
Pymongo. Ascending is ascending, Pymongo. Descending to Descending
Results=collection.find (). Sort (' name ', Pymongo. Ascending)
(9) Offset
If you want to go to only a few elements, you can use the Skip () method to offset the position to ignore the preceding element
Results=collection.find (). Sort (' name ', Pymongo. Ascending). Skip (2) #只取第三个及后面的元素
You can also use the limit () method to specify the number of results to be taken
Results=collection.find (). Sort (' name ', Pymongo. Ascending). Skip (2). Limit (2) #只取两个结果
(12) Other operations
Pymongo also provides some combination methods:
Find_one_and_delete () Delete after lookup
Find_one_and_replace () Replace after lookup
Find_one_and_update () Update after lookup
Create_index () creating an index on the collection
Create_indexes () Create one or more indexes on the collection
Drop_index () Delete an index on this collection
Incoming group: 125240963 to get dozens of sets of PDFs Oh!
is MongoDB written in C + +? So why do you wind up in the Python field?