[SERVER-4134] compound indexing and sort Created: 24/Oct/11  Updated: 29/Feb/12  Resolved: 25/Oct/11

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Question Priority: Major - P3
Reporter: Wei Kong Assignee: Unassigned
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Participants:

 Description   

I have three fields in a collection

parent_id, name and types

I will always lookup the collection by parent_id + name and/or types

HOw should I create the compound index?



 Comments   
Comment by Eliot Horowitz (Inactive) [ 25/Oct/11 ]

These kinds of questions are better suited for the mailing list

http://groups.google.com/group/mongodb-user/

In this case you might just want an index on both ( parent_id , name ) and ( parent_id , types )

Generated at Thu Feb 08 03:05:03 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.