notes/db/nosql/mongo/features/search.txt
Ihar Hancharenka 5224f2a9d9 m
2023-08-12 22:49:22 +03:00

18 строки
491 B
Plaintext

coll
.find({"field1": "v1", ...}, {f1: 1, f2: 0}) // 2-nd - projection
.pretty()
.sort({keyfield: 1/-1, ...})
https://www.studytonight.com/mongodb/sorting-in-mongodb
skip(N).limit(M)
https://www.tutorialsteacher.com/mongodb/cursor
!!! cursor
operators
{$gt: 75}
{ $gte: new ISODate( "2020-01-30" ), $lt: new ISODate( "2022-01-30" ) }
field: {"$exists": false}
???
cur = db.world.find();x=cur.next();print(x["speech"]);