but i want to kow whether i need to specify indexing name while query.
Hi Jithin,
Generally with the correct indexes in place, you should not need to specify an index to use while querying.
I would recommend to read MongoDB Explain Results, the cursor.explain() method returns information on query plans and execution statistics of the query plans. It’s a great way to analyse your queries performance.
You may also find MongoDB Indexes a useful resource.
Depending on your MongoDB Atlas instances, instance size M10 and above also comes with MongoDB Performance Advisor. It monitors queries that MongoDB considers slow and suggests new indexes to improve query performance.
See also Blog: Improving MongoDB Performance with Automatically Generated Index Suggestions
Regards,
Wan.