pretty ( ) METHOD

THE pretty ( ) METHOD WILL SELECT ALL DOCUMENTS IN STRUCTURED FORMAT

SYNTAX

db.<COLLECTION_NAME>.find().pretty()
db.dac.find().pretty()
 {
 "_id" : ObjectId("5a28048ad5c3a168fb652e32"),
 "id" : 1,
 "name" : "sachin"
 }
 {
 "_id" : ObjectId("5a28049ed5c3a168fb652e34"),
 "id" : 3,
 "name" : "ankita"
 }
 {
 "_id" : ObjectId("5a2804a8d5c3a168fb652e35"),
 "id" : 4,
 "name" : "mahesh"
 }