Tsallaka zuwa abun ciki
Justice Tech School

Performance Tips

Index filters and sorts, project only needed fields, avoid huge documents.

Example
db.users.createIndex({ email: 1 })
db.users.find({ email: "a@b.c" }, { name: 1 })

Exercise

Limit fields.

find({}, { name:  })

Quiz Test

What is the document size limit?

These free lessons are for learning. Join a full course for projects, mentor feedback and a verified certificate.