Question 5
Which of following statements is/are true?
Answer:
Answer:
- Compound indexes can service queries that filter on any subset of the index keys - No, not all subsets of a index's keys can service a query. The prefix of an index's keys can service a query.
- Compound indexes can service queries that filter on a prefix of the index keys - Yes.
- If no indexes can be used then a collection scan will be necessary - Yes.
- Query plans are evicted from the plan cache on index creation, destruction, or server restart - Yes.
- By default, the explain() command will execute your query - No, by default explain() will not execute your query. This is useful to test queries that need to run on a server under heavy load. Passing "executionStats" or "allPlansExecution" will execute the query and collect execution statistics.
Comments
Post a Comment