[DOCS-1999] Comment on: "core/index-compound.txt" Created: 26/Sep/13 Updated: 11/Jan/17 Resolved: 26/Sep/13 |
|
| Status: | Closed |
| Project: | Documentation |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 01112017-cleanup |
| Type: | Improvement | Priority: | Minor - P4 |
| Reporter: | Balthazar Rouberol | Assignee: | Kay Kim (Inactive) |
| Resolution: | Done | Votes: | 0 |
| Labels: | index, sorting, typo | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Participants: | |
| Days since reply: | 10 years, 20 weeks, 6 days ago |
| Description |
|
I think the second example query of the http://docs.mongodb.org/manual/core/index-compound/#sort-order paragraoph is mis-typed. The query is supposed to "return results sorted first by descending username values and then by ascending date values", which should be db.events.find().sort( { username: -1, date: 1 } ) db.events.find().sort( { username: 1, date: -1 } ) |
| Comments |
| Comment by auto [ 26/Sep/13 ] |
|
Author: {u'username': u'kay-kim', u'name': u'kay', u'email': u'kay.kim@10gen.com'}Message: |