[DOCS-5440] Call out compound key case in sparse unique indexes Created: 15/May/15  Updated: 30/Oct/23  Resolved: 01/Nov/22

Status: Closed
Project: Documentation
Component/s: manual, Server
Affects Version/s: mongodb-2.6, mongodb-3.0
Fix Version/s: Server_Docs_20231030

Type: Task Priority: Minor - P4
Reporter: Steffan Mejia Assignee: Kay Kim (Inactive)
Resolution: Won't Fix Votes: 0
Labels: indexes, sparse, unique
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Participants:
Days since reply: 1 year, 14 weeks, 1 day ago
Epic Link: DOCSP-1769

 Description   

The docs state:

sparse and unique Properties

An index that is both sparse and unique prevents collection from having documents with duplicate values for a field but allows multiple documents that omit the key.

The idea of the [entire] key being absent has some nuance that is not immediately apparent; in the case of a compound key, all elements of the key must be absent in order for this to apply.

A suggested alternative would be:

allows multiple documents that omit all fields in the key



 Comments   
Comment by Education Bot [ 01/Nov/22 ]

Hello! This ticket has been closed due to inactivity. If you believe this ticket is still important, please reopen it and leave a comment to explain why. Thank you!

Generated at Thu Feb 08 07:50:19 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.