This commit is contained in:
imcmjha 2020-09-28 10:11:34 +05:30
commit 75506ab96a
1 changed files with 2 additions and 0 deletions

View File

@ -28,6 +28,8 @@
` db.<collection_name>.findOne({<key-value pair condition>}) ` show the first object in collection; condition is optional
` db.<collection_name>.distinct('<property_name>) ` list all the distinct values present for given property
` db.<collection_name>.update() ` update the object.
- `.update({<mathcing_condition>}, {<updated_value>}, {upsert: true/false}) ` If the upsert value is true then the new object is created if there is no object with given matching condition otherwise ignores
- ` <update_value> ` If the object is given directly, then it will override the content of previous object