Answers for "between in mongodb"

0

between in mongodb

items.save({
    name: "example",
    created_at: ISODate("2010-04-30T00:00:00.000Z")
})
items.find({
    created_at: {
        $gte: ISODate("2010-04-29T00:00:00.000Z"),
        $lt: ISODate("2010-05-01T00:00:00.000Z")
    }
})
=> { "_id" : ObjectId("4c0791e2b9ec877893f3363b"), "name" : "example", "created_at" : "Sun May 30 2010 00:00:00 GMT+0300 (EEST)" }
Posted by: Guest on November-02-2020
0

get range of values in mongodb

db.student.find({ u1 : { $gt :  30, $lt : 60}});
Posted by: Guest on October-04-2020

Code answers related to "Javascript"

Browse Popular Code Answers by Language