Blog
How to create MongoDB indexes  ?
22 May, 14

How to create MongoDB indexes ?

In simple words “indexes are used to speed up query performance”. Let’s say you have a query which takes around 120ms to execute without indexes i can assure you that with proper indexes you can reduce that time by at least 10 times. Let me show you...
How to delete MongoDB document ?
22 May, 14

How to delete MongoDB document ?

In this blog post i am going to explain how to delete MongoDB document. The are few ways which are illustrated below : If we execute remove on collection without any params then it will delete all records [php] db.users.remove({}) // it will delete all documents along...
Updating multiple documents in MongoDB
22 May, 14

Updating multiple documents in MongoDB

In this blog post we are going to learn the process of updating multiple documents in MongoDB. MongoDB provides us with update() function to achieve the same. Here are few use cases : db.users.find(); { "_id" : ObjectId("537da62d770359c2fb4668e2"),...
MongoDB : Difference between save and insert
22 May, 14

MongoDB : Difference between save and insert

MongoDB uses save and insert option for adding new records in the database. Let me explain the difference between two : Insert : insert is used to add a document in a mongodb collection Save : save is used to add as well as update a document in a mongodb collection....