[SERVER-22194] partialFilterExpression error - Index with pattern {...} already exists with different options Created: 15/Jan/16 Updated: 15/Jan/16 Resolved: 15/Jan/16 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Index Maintenance |
| Affects Version/s: | 3.2.0 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Artyom Fanasov | Assignee: | Kelsey Schubert |
| Resolution: | Duplicate | Votes: | 2 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Operating System: | ALL | ||||||||
| Participants: | |||||||||
| Description |
|
Developer can't create two same indexes with different partialExpressions, for example: and partialFilterExpression: {type:2} |
| Comments |
| Comment by Kelsey Schubert [ 15/Jan/16 ] | ||||||||||||||||||||
|
Hi FanAs, As per Max's comment, I am closing this as a duplicate of SERVER-17853. Please feel vote and watch it and Kind regards, | ||||||||||||||||||||
| Comment by Max Hirschhorn [ 15/Jan/16 ] | ||||||||||||||||||||
|
It is invalid to create two indexes with the same key pattern that only differ in their options. Partial indexes, which are specified by using the partialFilterExpression index option, have the same restriction.
I think this ticket is a feature request to be able to use $or in the partialFilterExpression object. If that is the case, then it should be closed as a duplicate of SERVER-17853. For example, being able to create the following partial index.
Additional notes:
| ||||||||||||||||||||
| Comment by Ramon Fernandez Marina [ 15/Jan/16 ] | ||||||||||||||||||||
|
FanAs, can you please provide the commands being run to create these partial indexes and the exact errors you're getting? That would help us understand more about this issue. Thanks, |