You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm not sure if this is a bug or the expected behavior but I currently have some trouble using secondary indexes.
If the query's parameter is not exactly the same as the index, the index is never used.
The issue is that I can't always control the query fields order as it's an object.
Sometime I could even have some other fields before the indexed once.
Do you think it's possible to make indexes work in any order? If it's too complicated or to costly to handle this automatically, would it be possible to pass the index name manually to the function ?
Thanks a lot.
The text was updated successfully, but these errors were encountered:
dbCollection.explain({targetType: "52", targetId: "52", "test": "45"});// -> no index used
dbCollection.explain({"test": "45", targetId: "52", targetType: "52"});// -> no index used
dbCollection.explain({targetId: "52", targetType: "52", "test": "45"});// -> index used
Hi,
I'm not sure if this is a bug or the expected behavior but I currently have some trouble using secondary indexes.
If the query's parameter is not exactly the same as the index, the index is never used.
The issue is that I can't always control the query fields order as it's an object.
Sometime I could even have some other fields before the indexed once.
Do you think it's possible to make indexes work in any order? If it's too complicated or to costly to handle this automatically, would it be possible to pass the index name manually to the function ?
Thanks a lot.
The text was updated successfully, but these errors were encountered: