Closed vik228 closed 4 years ago
This driver does not currently have a dedicated function for this. However, you can use the explain
command.
Mongo.command(pid, %{
explain: %{
count: "products",
query: %{ quantity: %{ "$gt": 50 } } },
verbosity: "queryPlanner"
}
)
If you would like to contribute a dedicated function for this, I would gladly merge it.
I am going to close this. If you have any other questions related to this, please feel free to re-open.
Hey, How can i use explain to analyse my queries before executing?